From 34626a739582380c8930df7365939f24d57883bf Mon Sep 17 00:00:00 2001 From: Klay Date: Wed, 13 Oct 2021 08:39:45 -0700 Subject: [PATCH 01/25] add ssl support for graph daemon (#364) --- client/pom.xml | 6 + .../facebook/thrift/transport/TSocket.java | 31 +++ .../nebula/client/graph/NebulaPoolConfig.java | 24 ++ .../client/graph/data/CASignedSSLParam.java | 32 +++ .../nebula/client/graph/data/SSLParam.java | 25 ++ .../client/graph/data/SelfSignedSSLParam.java | 32 +++ .../client/graph/net/ConnObjectPool.java | 12 +- .../nebula/client/graph/net/Connection.java | 4 + .../nebula/client/graph/net/NebulaPool.java | 4 +- .../graph/net/RoundRobinLoadBalancer.java | 15 +- .../client/graph/net/SyncConnection.java | 50 +++- .../java/com/vesoft/nebula/util/SslUtil.java | 213 ++++++++++++++++++ .../client/graph/data/TestDataFromServer.java | 80 +++++++ .../resources/docker-compose-casigned.yaml | 135 +++++++++++ .../resources/docker-compose-selfsigned.yaml | 135 +++++++++++ client/src/test/resources/ssl/casigned.crt | 16 ++ client/src/test/resources/ssl/casigned.key | 27 +++ client/src/test/resources/ssl/casigned.pem | 24 ++ client/src/test/resources/ssl/selfsigned.key | 30 +++ .../test/resources/ssl/selfsigned.password | 1 + client/src/test/resources/ssl/selfsigned.pem | 24 ++ client/src/test/resources/ssl/test.ca.key | 30 +++ .../src/test/resources/ssl/test.ca.password | 1 + client/src/test/resources/ssl/test.ca.pem | 24 ++ client/src/test/resources/ssl/test.ca.srl | 1 + client/src/test/resources/ssl/test.derive.crt | 23 ++ client/src/test/resources/ssl/test.derive.csr | 19 ++ client/src/test/resources/ssl/test.derive.key | 27 +++ .../nebula/examples/GraphClientExample.java | 63 +++++- examples/src/main/resources/ssl/casigned.crt | 16 ++ examples/src/main/resources/ssl/casigned.key | 27 +++ examples/src/main/resources/ssl/casigned.pem | 24 ++ .../src/main/resources/ssl/selfsigned.key | 30 +++ .../main/resources/ssl/selfsigned.password | 1 + .../src/main/resources/ssl/selfsigned.pem | 24 ++ 35 files changed, 1214 insertions(+), 16 deletions(-) create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java create mode 100644 client/src/main/java/com/vesoft/nebula/util/SslUtil.java create mode 100644 client/src/test/resources/docker-compose-casigned.yaml create mode 100644 client/src/test/resources/docker-compose-selfsigned.yaml create mode 100644 client/src/test/resources/ssl/casigned.crt create mode 100644 client/src/test/resources/ssl/casigned.key create mode 100644 client/src/test/resources/ssl/casigned.pem create mode 100644 client/src/test/resources/ssl/selfsigned.key create mode 100644 client/src/test/resources/ssl/selfsigned.password create mode 100644 client/src/test/resources/ssl/selfsigned.pem create mode 100644 client/src/test/resources/ssl/test.ca.key create mode 100644 client/src/test/resources/ssl/test.ca.password create mode 100644 client/src/test/resources/ssl/test.ca.pem create mode 100644 client/src/test/resources/ssl/test.ca.srl create mode 100644 client/src/test/resources/ssl/test.derive.crt create mode 100644 client/src/test/resources/ssl/test.derive.csr create mode 100644 client/src/test/resources/ssl/test.derive.key create mode 100644 examples/src/main/resources/ssl/casigned.crt create mode 100644 examples/src/main/resources/ssl/casigned.key create mode 100644 examples/src/main/resources/ssl/casigned.pem create mode 100644 examples/src/main/resources/ssl/selfsigned.key create mode 100644 examples/src/main/resources/ssl/selfsigned.password create mode 100644 examples/src/main/resources/ssl/selfsigned.pem diff --git a/client/pom.xml b/client/pom.xml index 8e056ac68..a17bc85f7 100644 --- a/client/pom.xml +++ b/client/pom.xml @@ -22,6 +22,7 @@ 2.2 3.0.1 1.2.78 + 1.69 @@ -239,5 +240,10 @@ fastjson ${fastjson.version} + + org.bouncycastle + bcpkix-jdk15on + ${bouncycastle.version} + diff --git a/client/src/main/fbthrift/com/facebook/thrift/transport/TSocket.java b/client/src/main/fbthrift/com/facebook/thrift/transport/TSocket.java index 47160f930..e95168876 100644 --- a/client/src/main/fbthrift/com/facebook/thrift/transport/TSocket.java +++ b/client/src/main/fbthrift/com/facebook/thrift/transport/TSocket.java @@ -70,6 +70,37 @@ public TSocket(Socket socket) throws TTransportException { } } + /** + * Constructor that takes an already created socket that comes alone with timeout + * and connectionTimeout. + * + * @param socket Already created socket object + * @param timeout Socket timeout + * @param connectionTimeout Socket connection timeout + * @throws TTransportException if there is an error setting up the streams + */ + public TSocket(Socket socket, int timeout, int connectionTimeout) throws TTransportException { + socket_ = socket; + try { + socket_.setSoLinger(false, 0); + socket_.setTcpNoDelay(true); + socket_.setSoTimeout(timeout); + connectionTimeout_ = connectionTimeout; + } catch (SocketException sx) { + LOGGER.warn("Could not configure socket.", sx); + } + + if (isOpen()) { + try { + inputStream_ = new BufferedInputStream(socket_.getInputStream()); + outputStream_ = new BufferedOutputStream(socket_.getOutputStream()); + } catch (IOException iox) { + close(); + throw new TTransportException(TTransportException.NOT_OPEN, iox); + } + } + } + /** * Creates a new unconnected socket that will connect to the given host on the given port. * diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java b/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java index 3e1f70110..60bba75ea 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java @@ -6,6 +6,8 @@ package com.vesoft.nebula.client.graph; +import com.vesoft.nebula.client.graph.data.SSLParam; + public class NebulaPoolConfig { // The min connections in pool for all addresses private int minConnsSize = 0; @@ -27,6 +29,28 @@ public class NebulaPoolConfig { // the wait time to get idle connection, unit ms private int waitTime = 0; + // set to true to turn on ssl encrypted traffic + private boolean enableSsl = false; + + // ssl param is required if ssl is turned on + private SSLParam sslParam = null; + + public boolean isEnableSsl() { + return enableSsl; + } + + public void setEnableSsl(boolean enableSsl) { + this.enableSsl = enableSsl; + } + + public SSLParam getSslParam() { + return sslParam; + } + + public void setSslParam(SSLParam sslParam) { + this.sslParam = sslParam; + } + public int getMinConnSize() { return minConnsSize; } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java new file mode 100644 index 000000000..9667c70f9 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java @@ -0,0 +1,32 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +public class CASignedSSLParam extends SSLParam { + private String caCrtFilePath; + private String crtFilePath; + private String keyFilePath; + + public CASignedSSLParam(String caCrtFilePath, String crtFilePath, String keyFilePath) { + super(SignMode.CA_SIGNED); + this.caCrtFilePath = caCrtFilePath; + this.crtFilePath = crtFilePath; + this.keyFilePath = keyFilePath; + } + + public String getCaCrtFilePath() { + return caCrtFilePath; + } + + public String getCrtFilePath() { + return crtFilePath; + } + + public String getKeyFilePath() { + return keyFilePath; + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java new file mode 100644 index 000000000..1a19ec48d --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java @@ -0,0 +1,25 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +public abstract class SSLParam { + public enum SignMode { + NONE, + SELF_SIGNED, + CA_SIGNED + } + + private SignMode signMode; + + public SSLParam(SignMode signMode) { + this.signMode = signMode; + } + + public SignMode getSignMode() { + return signMode; + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java new file mode 100644 index 000000000..d10046a6d --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java @@ -0,0 +1,32 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +public class SelfSignedSSLParam extends SSLParam { + private String crtFilePath; + private String keyFilePath; + private String password; + + public SelfSignedSSLParam(String crtFilePath, String keyFilePath, String password) { + super(SignMode.SELF_SIGNED); + this.crtFilePath = crtFilePath; + this.keyFilePath = keyFilePath; + this.password = password; + } + + public String getCrtFilePath() { + return crtFilePath; + } + + public String getKeyFilePath() { + return keyFilePath; + } + + public String getPassword() { + return password; + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java index ac043fa2d..9e2ebd4ab 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java @@ -9,7 +9,7 @@ public class ConnObjectPool extends BasePooledObjectFactory { private final NebulaPoolConfig config; - private LoadBalancer loadBalancer; + private final LoadBalancer loadBalancer; private static final int retryTime = 3; public ConnObjectPool(LoadBalancer loadBalancer, NebulaPoolConfig config) { @@ -28,7 +28,15 @@ public SyncConnection create() throws IOErrorException { SyncConnection conn = new SyncConnection(); while (retry-- > 0) { try { - conn.open(address, config.getTimeout()); + if (config.isEnableSsl()) { + if (config.getSslParam() == null) { + throw new IllegalArgumentException("SSL Param is required when enableSsl " + + "is set to true"); + } + conn.open(address, config.getTimeout(), config.getSslParam()); + } else { + conn.open(address, config.getTimeout()); + } return conn; } catch (IOErrorException e) { if (retry == 0) { diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java index 1cbd1ba3e..5f94f1c84 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java @@ -1,6 +1,7 @@ package com.vesoft.nebula.client.graph.net; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; import com.vesoft.nebula.client.graph.exception.IOErrorException; public abstract class Connection { @@ -10,6 +11,9 @@ public HostAddress getServerAddress() { return this.serverAddr; } + public abstract void open(HostAddress address, int timeout, SSLParam sslParam) + throws IOErrorException; + public abstract void open(HostAddress address, int timeout) throws IOErrorException; public abstract void reopen() throws IOErrorException; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java index b5c6cd567..6fe80a2ba 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java @@ -85,7 +85,9 @@ public boolean init(List addresses, NebulaPoolConfig config) checkConfig(config); this.waitTime = config.getWaitTime(); List newAddrs = hostToIp(addresses); - this.loadBalancer = new RoundRobinLoadBalancer(newAddrs, config.getTimeout()); + this.loadBalancer = config.isEnableSsl() + ? new RoundRobinLoadBalancer(newAddrs, config.getTimeout(), config.getSslParam()) + : new RoundRobinLoadBalancer(newAddrs, config.getTimeout()); ConnObjectPool objectPool = new ConnObjectPool(this.loadBalancer, config); this.objectPool = new GenericObjectPool<>(objectPool); GenericObjectPoolConfig objConfig = new GenericObjectPoolConfig(); diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java index 661dcaa80..9e7c9402a 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java @@ -1,6 +1,7 @@ package com.vesoft.nebula.client.graph.net; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; import com.vesoft.nebula.client.graph.exception.IOErrorException; import java.util.ArrayList; import java.util.HashMap; @@ -21,6 +22,8 @@ public class RoundRobinLoadBalancer implements LoadBalancer { private final AtomicInteger pos = new AtomicInteger(0); private final int delayTime = 60; // unit seconds private final ScheduledExecutorService schedule = Executors.newScheduledThreadPool(1); + private SSLParam sslParam; + private boolean enabledSsl; public RoundRobinLoadBalancer(List addresses, int timeout) { this.timeout = timeout; @@ -31,6 +34,12 @@ public RoundRobinLoadBalancer(List addresses, int timeout) { schedule.scheduleAtFixedRate(this::scheduleTask, 0, delayTime, TimeUnit.SECONDS); } + public RoundRobinLoadBalancer(List addresses, int timeout, SSLParam sslParam) { + this(addresses,timeout); + this.sslParam = sslParam; + this.enabledSsl = true; + } + public void close() { schedule.shutdownNow(); } @@ -63,7 +72,11 @@ public void updateServersStatus() { public boolean ping(HostAddress addr) { try { Connection connection = new SyncConnection(); - connection.open(addr, this.timeout); + if (enabledSsl) { + connection.open(addr, this.timeout, sslParam); + } else { + connection.open(addr, this.timeout); + } connection.close(); return true; } catch (IOErrorException e) { diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java index 08a5e0a3b..4e6a77161 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java @@ -15,23 +15,64 @@ import com.facebook.thrift.transport.TTransportException; import com.facebook.thrift.utils.StandardCharsets; import com.vesoft.nebula.ErrorCode; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.AuthFailedException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.graph.AuthResponse; import com.vesoft.nebula.graph.ExecutionResponse; import com.vesoft.nebula.graph.GraphService; +import com.vesoft.nebula.util.SslUtil; +import java.io.IOException; +import javax.net.ssl.SSLSocketFactory; public class SyncConnection extends Connection { protected TTransport transport = null; protected TProtocol protocol = null; private GraphService.Client client = null; private int timeout = 0; + private SSLParam sslParam = null; + private boolean enabledSsl = false; + + @Override + public void open(HostAddress address, int timeout, SSLParam sslParam) throws IOErrorException { + try { + SSLSocketFactory sslSocketFactory; + + this.serverAddr = address; + this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; + this.enabledSsl = true; + this.sslParam = sslParam; + if (sslParam.getSignMode() == SSLParam.SignMode.CA_SIGNED) { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithCA((CASignedSSLParam) sslParam); + } else { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithoutCA((SelfSignedSSLParam) sslParam); + } + if (sslSocketFactory == null) { + throw new IOErrorException(IOErrorException.E_UNKNOWN, + "SSL Socket Factory Creation failed"); + } + this.transport = new TSocket( + sslSocketFactory.createSocket(address.getHost(), + address.getPort()), this.timeout, this.timeout); + this.protocol = new TCompactProtocol(transport); + client = new GraphService.Client(protocol); + } catch (TException e) { + throw new IOErrorException(IOErrorException.E_UNKNOWN, e.getMessage()); + } catch (IOException e) { + e.printStackTrace(); + } + } @Override public void open(HostAddress address, int timeout) throws IOErrorException { - this.serverAddr = address; try { + this.enabledSsl = false; + this.serverAddr = address; this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; this.transport = new TSocket( address.getHost(), address.getPort(), this.timeout, this.timeout); @@ -56,7 +97,11 @@ public void open(HostAddress address, int timeout) throws IOErrorException { @Override public void reopen() throws IOErrorException { close(); - open(serverAddr, timeout); + if (enabledSsl) { + open(serverAddr, timeout, sslParam); + } else { + open(serverAddr, timeout); + } } public AuthResult authenticate(String user, String password) @@ -143,6 +188,7 @@ public boolean ping() { execute(0, "YIELD 1;"); return true; } catch (IOErrorException e) { + e.printStackTrace(); return false; } } diff --git a/client/src/main/java/com/vesoft/nebula/util/SslUtil.java b/client/src/main/java/com/vesoft/nebula/util/SslUtil.java new file mode 100644 index 000000000..e75087e10 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/util/SslUtil.java @@ -0,0 +1,213 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.util; + +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; +import java.io.FileReader; +import java.security.KeyPair; +import java.security.KeyStore; +import java.security.Security; +import java.security.cert.Certificate; +import java.security.cert.X509Certificate; +import javax.net.ssl.KeyManagerFactory; +import javax.net.ssl.SSLContext; +import javax.net.ssl.SSLSocketFactory; +import javax.net.ssl.TrustManagerFactory; +import org.bouncycastle.cert.X509CertificateHolder; +import org.bouncycastle.cert.jcajce.JcaX509CertificateConverter; +import org.bouncycastle.jce.provider.BouncyCastleProvider; +import org.bouncycastle.openssl.PEMDecryptorProvider; +import org.bouncycastle.openssl.PEMEncryptedKeyPair; +import org.bouncycastle.openssl.PEMKeyPair; +import org.bouncycastle.openssl.PEMParser; +import org.bouncycastle.openssl.jcajce.JcaPEMKeyConverter; +import org.bouncycastle.openssl.jcajce.JcePEMDecryptorProviderBuilder; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class SslUtil { + private static final Logger LOGGER = LoggerFactory.getLogger(SslUtil.class); + + public static SSLSocketFactory getSSLSocketFactoryWithCA(CASignedSSLParam param) { + final String caCrtFile = param.getCaCrtFilePath(); + final String crtFile = param.getCrtFilePath(); + final String keyFile = param.getKeyFilePath(); + final String password = ""; + try { + //Add BouncyCastle as a Security Provider + Security.addProvider(new BouncyCastleProvider()); + + // Load client private key + PEMParser reader = null; + Object keyObject; + try { + reader = new PEMParser(new FileReader(keyFile)); + keyObject = reader.readObject(); + } finally { + if (reader != null) { + reader.close(); + } + } + + PEMDecryptorProvider provider = + new JcePEMDecryptorProviderBuilder().build(password.toCharArray()); + JcaPEMKeyConverter keyConverter = new JcaPEMKeyConverter().setProvider("BC"); + + KeyPair key; + + if (keyObject instanceof PEMEncryptedKeyPair) { + key = keyConverter.getKeyPair(((PEMEncryptedKeyPair) keyObject) + .decryptKeyPair(provider)); + } else { + key = keyConverter.getKeyPair((PEMKeyPair) keyObject); + } + + // Load Certificate Authority (CA) certificate + X509CertificateHolder caCertHolder; + try { + reader = new PEMParser(new FileReader(caCrtFile)); + caCertHolder = (X509CertificateHolder) reader.readObject(); + } finally { + if (reader != null) { + reader.close(); + } + } + + // CA certificate is used to authenticate server + JcaX509CertificateConverter certificateConverter = + new JcaX509CertificateConverter().setProvider("BC"); + KeyStore caKeyStore = KeyStore.getInstance(KeyStore.getDefaultType()); + X509Certificate caCert = certificateConverter.getCertificate(caCertHolder); + caKeyStore.load(null, null); + caKeyStore.setCertificateEntry("ca-certificate", caCert); + + TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance( + TrustManagerFactory.getDefaultAlgorithm()); + trustManagerFactory.init(caKeyStore); + + // Load client certificate + X509CertificateHolder certHolder; + try { + reader = new PEMParser(new FileReader(crtFile)); + certHolder = (X509CertificateHolder) reader.readObject(); + } finally { + if (reader != null) { + reader.close(); + } + } + + // Client key and certificates are sent to server so it can authenticate the client + KeyStore clientKeyStore = KeyStore.getInstance(KeyStore.getDefaultType()); + X509Certificate cert = certificateConverter.getCertificate(certHolder); + clientKeyStore.load(null, null); + clientKeyStore.setCertificateEntry("certificate", cert); + clientKeyStore.setKeyEntry("private-key", key.getPrivate(), password.toCharArray(), + new Certificate[]{cert}); + + KeyManagerFactory keyManagerFactory = KeyManagerFactory.getInstance( + KeyManagerFactory.getDefaultAlgorithm()); + keyManagerFactory.init(clientKeyStore, password.toCharArray()); + + // Create SSL socket factory + SSLContext context = SSLContext.getInstance("TLSv1.3"); + context.init(keyManagerFactory.getKeyManagers(), + trustManagerFactory.getTrustManagers(), null); + + // Return the newly created socket factory object + return context.getSocketFactory(); + + } catch (Exception e) { + LOGGER.error(e.getMessage()); + } + + return null; + } + + public static SSLSocketFactory getSSLSocketFactoryWithoutCA(SelfSignedSSLParam param) { + final String crtFile = param.getCrtFilePath(); + final String keyFile = param.getKeyFilePath(); + final String password = param.getPassword(); + try { + // Add BouncyCastle as a Security Provider + Security.addProvider(new BouncyCastleProvider()); + + // Load client private key + PEMParser reader = null; + Object keyObject; + try { + reader = new PEMParser(new FileReader(keyFile)); + keyObject = reader.readObject(); + } finally { + if (reader != null) { + reader.close(); + } + } + + PEMDecryptorProvider provider = + new JcePEMDecryptorProviderBuilder().build(password.toCharArray()); + JcaPEMKeyConverter keyConverter = new JcaPEMKeyConverter().setProvider("BC"); + + KeyPair key; + + if (keyObject instanceof PEMEncryptedKeyPair) { + key = keyConverter.getKeyPair(((PEMEncryptedKeyPair) keyObject) + .decryptKeyPair(provider)); + } else { + key = keyConverter.getKeyPair((PEMKeyPair) keyObject); + } + + // certificate is used to authenticate server + JcaX509CertificateConverter certificateConverter = + new JcaX509CertificateConverter().setProvider("BC"); + + // Load client certificate + X509CertificateHolder certHolder; + try { + reader = new PEMParser(new FileReader(crtFile)); + certHolder = (X509CertificateHolder) reader.readObject(); + } finally { + if (reader != null) { + reader.close(); + } + } + + X509Certificate cert = certificateConverter.getCertificate(certHolder); + // certificate is used to authenticate server + KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); + keyStore.load(null, null); + keyStore.setCertificateEntry("certificate", cert); + + TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance( + TrustManagerFactory.getDefaultAlgorithm()); + trustManagerFactory.init(keyStore); + + // Client key and certificates are sent to server so it can authenticate the client + KeyStore clientKeyStore = KeyStore.getInstance(KeyStore.getDefaultType()); + clientKeyStore.load(null, null); + clientKeyStore.setCertificateEntry("certificate", cert); + clientKeyStore.setKeyEntry("private-key", key.getPrivate(), password.toCharArray(), + new Certificate[]{cert}); + + KeyManagerFactory keyManagerFactory = KeyManagerFactory.getInstance( + KeyManagerFactory.getDefaultAlgorithm()); + keyManagerFactory.init(clientKeyStore, password.toCharArray()); + + // Create SSL socket factory + SSLContext context = SSLContext.getInstance("TLSv1.3"); + context.init(keyManagerFactory.getKeyManagers(), + trustManagerFactory.getTrustManagers(), null); + + // Return the newly created socket factory object + return context.getSocketFactory(); + } catch (Exception e) { + LOGGER.error(e.getMessage()); + } + + return null; + } +} diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index aebb7ef88..d71442857 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -451,4 +451,84 @@ public void testErrorForJson() { assert false; } } + + @Test + public void testSelfSignedSsl() { + Session sslSession = null; + NebulaPool sslPool = new NebulaPool(); + try { + Runtime runtime = Runtime.getRuntime(); + runtime.exec("docker-compose -f src/test/resources/docker-compose" + + "-selfsigned.yaml up -d").waitFor(20,TimeUnit.SECONDS); + + NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); + nebulaSslPoolConfig.setMaxConnSize(100); + nebulaSslPoolConfig.setEnableSsl(true); + nebulaSslPoolConfig.setSslParam(new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft")); + Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), + nebulaSslPoolConfig)); + sslSession = sslPool.getSession("root", "nebula", true); + + String ngql = "YIELD 1"; + JSONObject resp = JSON.parseObject(sslSession.executeJson(ngql)); + String rowData = resp.getJSONArray("results").getJSONObject(0).getJSONArray("data") + .getJSONObject(0).getJSONArray("row").toJSONString(); + String exp = "[1]"; + Assert.assertEquals(rowData, exp); + + runtime.exec("docker-compose -f src/test/resources/docker-compose" + + "-selfsigned.yaml down").waitFor(60,TimeUnit.SECONDS); + } catch (Exception e) { + e.printStackTrace(); + assert false; + } finally { + if (sslSession != null) { + sslSession.release(); + } + sslPool.close(); + } + } + + @Test + public void testCASignedSsl() { + Session sslSession = null; + NebulaPool sslPool = new NebulaPool(); + try { + Runtime runtime = Runtime.getRuntime(); + runtime.exec("docker-compose -f src/test/resources/docker-compose" + + "-casigned.yaml up -d").waitFor(20,TimeUnit.SECONDS); + + NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); + nebulaSslPoolConfig.setMaxConnSize(100); + nebulaSslPoolConfig.setEnableSsl(true); + nebulaSslPoolConfig.setSslParam(new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key")); + Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), + nebulaSslPoolConfig)); + sslSession = sslPool.getSession("root", "nebula", true); + + String ngql = "YIELD 1"; + JSONObject resp = JSON.parseObject(sslSession.executeJson(ngql)); + String rowData = resp.getJSONArray("results").getJSONObject(0).getJSONArray("data") + .getJSONObject(0).getJSONArray("row").toJSONString(); + String exp = "[1]"; + Assert.assertEquals(rowData, exp); + + runtime.exec("docker-compose -f src/test/resources/docker-compose" + + "-casigned.yaml down").waitFor(60,TimeUnit.SECONDS); + } catch (Exception e) { + e.printStackTrace(); + assert false; + } finally { + if (sslSession != null) { + sslSession.release(); + } + sslPool.close(); + } + } } diff --git a/client/src/test/resources/docker-compose-casigned.yaml b/client/src/test/resources/docker-compose-casigned.yaml new file mode 100644 index 000000000..bfdd1b96d --- /dev/null +++ b/client/src/test/resources/docker-compose-casigned.yaml @@ -0,0 +1,135 @@ +version: '3.4' +services: + metad-casigned: + image: vesoft/nebula-metad:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --local_ip=172.29.1.1 + - --ws_ip=172.29.1.1 + - --port=8559 + - --data_path=/data/meta + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --expired_time_factor=2 + - --ws_h2_port=11000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.1.1:11000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8559:8559" + - 11000 + - 11002 + volumes: + - ./data/meta:/data/meta:Z + - ./logs/meta:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-casigned: + ipv4_address: 172.29.1.1 + restart: on-failure + cap_add: + - SYS_PTRACE + + storaged-casigned: + image: vesoft/nebula-storaged:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --local_ip=172.29.2.1 + - --ws_ip=172.29.2.1 + - --port=8779 + - --data_path=/data/storage + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --timezone_name=+08:00:00 + - --ws_h2_port=12000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + depends_on: + - metad-casigned + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.2.1:12000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8779:8779" + - 12000 + - 12002 + volumes: + - ./data/storage:/data/storage:Z + - ./logs/storage:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-casigned: + ipv4_address: 172.29.2.1 + restart: on-failure + cap_add: + - SYS_PTRACE + + graphd-casigned: + image: vesoft/nebula-graphd:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --port=8669 + - --ws_ip=172.29.3.1 + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --timezone_name=+08:00:00 + - --ws_h2_port=13000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + depends_on: + - metad-casigned + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.3.1:13000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8669:8669" + - 13000 + - 13002 + volumes: + - ./logs/graph:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-casigned: + ipv4_address: 172.29.3.1 + restart: on-failure + cap_add: + - SYS_PTRACE + +networks: + nebula-net-casigned: + ipam: + driver: default + config: + - subnet: 172.29.0.0/16 diff --git a/client/src/test/resources/docker-compose-selfsigned.yaml b/client/src/test/resources/docker-compose-selfsigned.yaml new file mode 100644 index 000000000..aeac1a60a --- /dev/null +++ b/client/src/test/resources/docker-compose-selfsigned.yaml @@ -0,0 +1,135 @@ +version: '3.4' +services: + metad-selfsigned: + image: vesoft/nebula-metad:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --local_ip=172.29.1.1 + - --ws_ip=172.29.1.1 + - --port=8559 + - --data_path=/data/meta + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --expired_time_factor=2 + - --ws_h2_port=11000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.1.1:11000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8559:8559" + - 11000 + - 11002 + volumes: + - ./data/meta:/data/meta:Z + - ./logs/meta:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-selfsigned: + ipv4_address: 172.29.1.1 + restart: on-failure + cap_add: + - SYS_PTRACE + + storaged-selfsigned: + image: vesoft/nebula-storaged:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --local_ip=172.29.2.1 + - --ws_ip=172.29.2.1 + - --port=8779 + - --data_path=/data/storage + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --timezone_name=+08:00:00 + - --ws_h2_port=12000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + depends_on: + - metad-selfsigned + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.2.1:12000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8779:8779" + - 12000 + - 12002 + volumes: + - ./data/storage:/data/storage:Z + - ./logs/storage:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-selfsigned: + ipv4_address: 172.29.2.1 + restart: on-failure + cap_add: + - SYS_PTRACE + + graphd-selfsigned: + image: vesoft/nebula-graphd:nightly + environment: + USER: root + TZ: "${TZ}" + command: + - --meta_server_addrs=172.29.1.1:8559 + - --port=8669 + - --ws_ip=172.29.3.1 + - --log_dir=/logs + - --v=0 + - --minloglevel=0 + - --heartbeat_interval_secs=2 + - --timezone_name=+08:00:00 + - --ws_h2_port=13000 + - --cert_path=/share/resources/test.derive.crt + - --key_path=/share/resources/test.derive.key + - --password_path=/share/resources/test.ca.password + - --enable_ssl=true + depends_on: + - metad-selfsigned + healthcheck: + test: ["CMD", "curl", "-f", "http://172.29.3.1:13000/status"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 20s + ports: + - "8669:8669" + - 13000 + - 13002 + volumes: + - ./logs/graph:/logs:Z + - ./ssl:/share/resources:Z + networks: + nebula-net-selfsigned: + ipv4_address: 172.29.3.1 + restart: on-failure + cap_add: + - SYS_PTRACE + +networks: + nebula-net-selfsigned: + ipam: + driver: default + config: + - subnet: 172.29.0.0/16 diff --git a/client/src/test/resources/ssl/casigned.crt b/client/src/test/resources/ssl/casigned.crt new file mode 100644 index 000000000..fe1add667 --- /dev/null +++ b/client/src/test/resources/ssl/casigned.crt @@ -0,0 +1,16 @@ +-----BEGIN CERTIFICATE----- +MIICljCCAX4CCQC9uuUY+ah8qzANBgkqhkiG9w0BAQsFADANMQswCQYDVQQGEwJD +TjAeFw0yMTA5MjkwNzM4MDRaFw0yNDAxMDIwNzM4MDRaMA0xCzAJBgNVBAYTAkNO +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuo7hKpcs+VQKbGRq0fUL ++GcSfPfJ8mARtIeI8WfU0j1vI5KNujI//G2olOGEueDCw4OO0UbdjnsFpgj2awAo +rj4ga2W6adQHK8qHY6q/Rdqv0oDCrcePMtQ8IwbFjNWOXC4bn7GcV7mzOkigdcj8 +UPkSeaqI9XxBRm3OoDX+T8h6cDLrm+ncKB8KKe/QApKH4frV3HYDqGtN49zuRs6F +iurFbXDGVAZEdFEJl38IQJdmE2ASOzEHZbxWKzO/DZr/Z2+L1CuycZIwuITcnddx +b2Byx/opwX4HlyODeUBbyDp+hd+GkasmIcpOlIDw9OXIvrcajKvzLEbqGt2ThsxX +QwIDAQABMA0GCSqGSIb3DQEBCwUAA4IBAQAxzxtbYBQ2WgBGrpzOX4TxsuSaigqo +YJ5zbVEHtwbsbBTZ7UJvRc9IyhrOL5Ui4PJI85chh1GpGqOmMoYSaWdddaIroilQ +56bn5haB8ezAMnLXbPuf97UENO0RIkyzt63XPIUkDnwlzOukIq50qgsYEDuiioM/ +wpCqSbMJ4iK/SlSSUWw3cKuAHvFfLv7hkC6AhvT7yfaCNDs29xEQUCD12XlIdFGH +FjMgVMcvcIePQq5ZcmSfVMge9jPjPx/Nj9SVauF5z5pil9qHG4jyXPGThiiJ3CE4 +GU5d/Qfe7OeiYI3LaoVufZ5pZnR9nMnpzqU46w9gY7vgi6bAhNwsCDr3 +-----END CERTIFICATE----- diff --git a/client/src/test/resources/ssl/casigned.key b/client/src/test/resources/ssl/casigned.key new file mode 100644 index 000000000..3561e7ab8 --- /dev/null +++ b/client/src/test/resources/ssl/casigned.key @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEpAIBAAKCAQEAuo7hKpcs+VQKbGRq0fUL+GcSfPfJ8mARtIeI8WfU0j1vI5KN +ujI//G2olOGEueDCw4OO0UbdjnsFpgj2awAorj4ga2W6adQHK8qHY6q/Rdqv0oDC +rcePMtQ8IwbFjNWOXC4bn7GcV7mzOkigdcj8UPkSeaqI9XxBRm3OoDX+T8h6cDLr +m+ncKB8KKe/QApKH4frV3HYDqGtN49zuRs6FiurFbXDGVAZEdFEJl38IQJdmE2AS +OzEHZbxWKzO/DZr/Z2+L1CuycZIwuITcnddxb2Byx/opwX4HlyODeUBbyDp+hd+G +kasmIcpOlIDw9OXIvrcajKvzLEbqGt2ThsxXQwIDAQABAoIBAH4SEBe4EaxsHp8h +PQ6linFTNis9SDuCsHRPIzv/7tIksfZYE27Ahn0Pndz+ibMTMIrvXJQQT6j5ede6 +NswYT2Vwlnf9Rvw9TJtLQjMYMCoEnsyiNu047oxq4DjLWrTRnGKuxfwlCoI9++Bn +NAhkyh3uM44EsIk0bugpTHj4A+PlbUPe7xdEI/6XpaZrRN9oiejJ4VxZAPgFGiTm +uNF5qg16+0900Pfj5Y/M4vXmn+gq39PO/y0FlTpaoEuYZiZZS3xHGmSVhlt8LIgI +8MdMRaKTfNeNITaqgOWh9pAW4xmK48/KfLgNPQgtDHjMJpgM0BbcBOayOY8Eio0x +Z66G2AECgYEA9vj/8Fm3CKn/ogNOO81y9kIs0iPcbjasMnQ3UXeOdD0z0+7TM86F +Xj3GK/z2ecvY7skWtO5ZUbbxp4aB7omW8Ke9+q8XPzMEmUuAOTzxQkAOxdr++HXP +TILy0hNX2cmiLQT1U60KoZHzPZ5o5hNIQPMt7hN12ERWcIfR/MUZa5UCgYEAwWCP +6Y7Zso1QxQR/qfjuILET3/xU+ZmqSRDvzJPEiGI3oeWNG4L6cKR+XTe0FWZBAmVk +Qq/1qXmdBnf5S7azffoJe2+H/m3kHJSprIiAAWlBN2e+kFlNfBhtkgia5NvsrjRw +al6mf/+weRD1FiPoZY3e1wBKoqro7aI8fE5gwXcCgYEAnEI05OROeyvb8qy2vf2i +JA8AfsBzwkPTNWT0bxX+yqrCdO/hLyEWnubk0IYPiEYibgpK1JUNbDcctErVQJBL +MN5gxBAt3C2yVi8/5HcbijgvYJ3LvnYDf7xGWAYnCkOZ2XQOqC+Oz2UhijYE1rUS +fQ2fXMdxQzERo8c7Y/tstvUCgYBuixy5jwezokUB20h/ieXWmmOaL00EQmutyRjM +AczfigXzbp3zlDRGIEJ8V1OCyClxjTR7SstMTlENWZgRSCfjZAP3pBJBx+AW1oUI +NB+4rsqxOYUeT26T+gLo8DJbkb0C+Mcqh2D22tuu2ZrBRVWceDVjAq+nvbvZ3Fxn +UwbMkQKBgQCxL3aA6ART6laIxT/ZqMhV0ZcaoDJogjF+4I4bhlO4ivWGWJ4RpEDn +ziFb6+M/4pe4vCou9yuAof6WTKM8JG4rok0yxhN3V6QGP49TjtrfkkrEPCtB2LSI +N1+YRSTrS5VDcl8h8JH7fpghRnXHONEyIqasYVqsbxKzNyLV/z2rkw== +-----END RSA PRIVATE KEY----- diff --git a/client/src/test/resources/ssl/casigned.pem b/client/src/test/resources/ssl/casigned.pem new file mode 100644 index 000000000..412ba3161 --- /dev/null +++ b/client/src/test/resources/ssl/casigned.pem @@ -0,0 +1,24 @@ +-----BEGIN CERTIFICATE----- +MIIEGzCCAwOgAwIBAgIUDcmZFpL4PcdCXfLRBK8bR2vb39cwDQYJKoZIhvcNAQEL +BQAwgZwxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwI +SGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9u +MRYwFAYDVQQDDA1zaHlsb2NrIGh1YW5nMScwJQYJKoZIhvcNAQkBFhhzaHlsb2Nr +Lmh1YW5nQHZlc29mdC5jb20wHhcNMjEwODE5MDkyNDQ3WhcNMjUwODE4MDkyNDQ3 +WjCBnDELMAkGA1UEBhMCQ04xETAPBgNVBAgMCFpoZWppYW5nMREwDwYDVQQHDAhI +YW5nemhvdTEUMBIGA1UECgwLVmVzb2Z0IEluYy4xEDAOBgNVBAsMB3NlY3Rpb24x +FjAUBgNVBAMMDXNoeWxvY2sgaHVhbmcxJzAlBgkqhkiG9w0BCQEWGHNoeWxvY2su +aHVhbmdAdmVzb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AMEAgpamCQHl+8JnUHI6/VmJHjDLYJLTliN/CwpFrhMqIVjJ8wG57WYLpXpn91Lz +eHu52LkVzcikybIJ2a+LOTvnhNFdbmTbqDtrb+s6wM/sO+nF6tU2Av4e5zhyKoeR +LL+rHMk3nymohbdN4djySFmOOU5A1O/4b0bZz4Ylu995kUawdiaEo13BzxxOC7Ik +Gge5RyDcm0uLXZqTAPy5Sjv/zpOyj0AqL1CJUH7XBN9OMRhVU0ZX9nHWl1vgLRld +J6XT17Y9QbbHhCNEdAmFE5kEFgCvZc+MungUYABlkvoj86TLmC/FMV6fWdxQssyd +hS+ssfJFLaTDaEFz5a/Tr48CAwEAAaNTMFEwHQYDVR0OBBYEFK0GVrQx+wX1GCHy +e+6fl4X+prmYMB8GA1UdIwQYMBaAFK0GVrQx+wX1GCHye+6fl4X+prmYMA8GA1Ud +EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAHqP8P+ZUHmngviHLSSN1ln5 +Mx4BCkVeFRUaFx0yFXytV/iLXcG2HpFg3A9rAFoYgCDwi1xpsERnBZ/ShTv/eFOc +IxBY5yggx3/lGi8tAgvUdarhd7mQO67UJ0V4YU3hAkbnZ8grHHXj+4hfgUpY4ok6 +yaed6HXwknBb9W8N1jZI8ginhkhjaeRCHdMiF+fBvNCtmeR1bCml1Uz7ailrpcaT +Mf84+5VYuFEnaRZYWFNsWNCOBlJ/6/b3V10vMXzMmYHqz3xgAq0M3fVTFTzopnAX +DLSzorL/dYVdqEDCQi5XI9YAlgWN4VeGzJI+glkLOCNzHxRNP6Qev+YI+7Uxz6I= +-----END CERTIFICATE----- diff --git a/client/src/test/resources/ssl/selfsigned.key b/client/src/test/resources/ssl/selfsigned.key new file mode 100644 index 000000000..6006d0f27 --- /dev/null +++ b/client/src/test/resources/ssl/selfsigned.key @@ -0,0 +1,30 @@ +-----BEGIN RSA PRIVATE KEY----- +Proc-Type: 4,ENCRYPTED +DEK-Info: DES-EDE3-CBC,6D12ED8559E80FA3 + +tv9epnwlt4dP6Q5ee0dACOyFA5BTwYTdoMykQRJrKGwfaNeXUXn+sQ/U/oFHp1Wx +O8VZE+z2aHpiFSTw+Eh6MPt86X5yVG3tpeVO6dErvr8Kd+NpuI8zn7rNoOFRh8wD +33EFcQMLQPneDl10O18hooIoi0qwp1pd63hYZPwEhB3eOrM5Mnv9OVJs65bzYfyf +Wku33YWYxeqlDvMCsou8PZnv/M2wYsr7+QoTcNmGKP45igMthMDBzwgF+q0p9ZZU +N11c6ojAs01kfuqFf3vKfHNYe6zsBiNhnUuEy8enXSxD5E7tR/OI8aEzPLdk7fmN +/UsMK2LE0Yd5iS3O1x/1ZjSBxJ+M/UzzCO692GTAiD6Hc13iJOavq/vt1mEPjfCD +neF38Bhb5DfFi+UAHrz6EHMreamGCzP82us2maIs7mSTq7nXDZfbBc7mBDLAUUnT +J6tlrTyc+DQXzkJa6jmbxJhcsWm6XvjIBEzSXVHxEDPLnZICQk3VXODjCXTD75Rg +0WaS78Ven7DW8wn07q3VzWAFDKaet3VI+TVTv7EfIavlfiA6LSshaENdFLeHahNE +s/V/j5K3Pg6+WQcZRgOsfqIwUCSQxY13R6TTdaaCkLay5BggF5iiAO3pkqsJiadf +w843Ak4USBptymJxoZgJyFtQHpQyNiFfsAbs9BaYbg2evvE7/VQhLk0gQ7HgQMeJ +wgxEQqZQKDCCSugSzY1YEGXKnrZYCKyipzyyH936mE15zNwhYp/Pi2020+gmtP3h +CDfcPs1yeLI2/1JuimafbuKsv9xchWa6ASU8p8Q7wTLtUj9ylLKyA4A/75pK0DXG +Hv/q0O+UfhAMD438SoPBle7RSvIsDU1VjUqstlNybBglBZxGIME7/18+Ms7U32wh +4xFkZwxT2nqFgyk37tXMdMz9UBh12/AXR9NU4XY37C3Ao2TDT7/0DvU6KdJhsDpv +rGcaC2zzhko+0CPrLlk52KbqP003JXiWvOSI+FylyPPDB/YGitmndJUuQblf3u/E +l+tGi9MeSBQeWKV6D3AVnO05AZjfTUzSK0vw4DgNh5YPNJvLy31B7kDAS88vyGI1 +t6MBwjW4/tz/nS/p1Go3mSzBhPkIsCrZE+ar7lH8p8JqkLl4fXIMaVKIfyfJdzyS +lkh3K7bOGDPegxxxaWdb+EnC7k+1R3EOU7uJFW61HyrGI3q6Y7kOl5aYSJ5Ge1Uv +PycFWHWVTHq/R7HRE6HIJzGe/PnLIbStXLDFeivjfcYq1YaSaF8Vl+xg+0u3ULOl +P6IuPTph6dlcgttRZVl3ETcF0T+2wfbUwgjf0ZiguCJfR2jLGhPl1KBg0Kd9cTSY +zI3YMMd2G8hApt/QFlm4Ry8CqaJUmDcjDNIJT3M+RldUgfz37NsX05cA5e9+I1AL +2406F/v5U9gWsYx7HuwJtQrDzYYDbl1GD4H+qHFJE5JYhPP4AyWYxJ1NR5dqyvrt ++3r5+xlwZrS76c10RsBWL7th8ZEzRxOZxbtLwbf4bG/tIGfQP2sTnWwA+qym6b2S +sRduqOTP+xwnhOq/ZKn8lfsDfhT8CPnKHBsd09kM9y/UWuxFe0upLydRLE/Wsb9s +-----END RSA PRIVATE KEY----- diff --git a/client/src/test/resources/ssl/selfsigned.password b/client/src/test/resources/ssl/selfsigned.password new file mode 100644 index 000000000..143be9ab9 --- /dev/null +++ b/client/src/test/resources/ssl/selfsigned.password @@ -0,0 +1 @@ +vesoft diff --git a/client/src/test/resources/ssl/selfsigned.pem b/client/src/test/resources/ssl/selfsigned.pem new file mode 100644 index 000000000..412ba3161 --- /dev/null +++ b/client/src/test/resources/ssl/selfsigned.pem @@ -0,0 +1,24 @@ +-----BEGIN CERTIFICATE----- +MIIEGzCCAwOgAwIBAgIUDcmZFpL4PcdCXfLRBK8bR2vb39cwDQYJKoZIhvcNAQEL +BQAwgZwxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwI +SGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9u +MRYwFAYDVQQDDA1zaHlsb2NrIGh1YW5nMScwJQYJKoZIhvcNAQkBFhhzaHlsb2Nr +Lmh1YW5nQHZlc29mdC5jb20wHhcNMjEwODE5MDkyNDQ3WhcNMjUwODE4MDkyNDQ3 +WjCBnDELMAkGA1UEBhMCQ04xETAPBgNVBAgMCFpoZWppYW5nMREwDwYDVQQHDAhI +YW5nemhvdTEUMBIGA1UECgwLVmVzb2Z0IEluYy4xEDAOBgNVBAsMB3NlY3Rpb24x +FjAUBgNVBAMMDXNoeWxvY2sgaHVhbmcxJzAlBgkqhkiG9w0BCQEWGHNoeWxvY2su +aHVhbmdAdmVzb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AMEAgpamCQHl+8JnUHI6/VmJHjDLYJLTliN/CwpFrhMqIVjJ8wG57WYLpXpn91Lz +eHu52LkVzcikybIJ2a+LOTvnhNFdbmTbqDtrb+s6wM/sO+nF6tU2Av4e5zhyKoeR +LL+rHMk3nymohbdN4djySFmOOU5A1O/4b0bZz4Ylu995kUawdiaEo13BzxxOC7Ik +Gge5RyDcm0uLXZqTAPy5Sjv/zpOyj0AqL1CJUH7XBN9OMRhVU0ZX9nHWl1vgLRld +J6XT17Y9QbbHhCNEdAmFE5kEFgCvZc+MungUYABlkvoj86TLmC/FMV6fWdxQssyd +hS+ssfJFLaTDaEFz5a/Tr48CAwEAAaNTMFEwHQYDVR0OBBYEFK0GVrQx+wX1GCHy +e+6fl4X+prmYMB8GA1UdIwQYMBaAFK0GVrQx+wX1GCHye+6fl4X+prmYMA8GA1Ud +EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAHqP8P+ZUHmngviHLSSN1ln5 +Mx4BCkVeFRUaFx0yFXytV/iLXcG2HpFg3A9rAFoYgCDwi1xpsERnBZ/ShTv/eFOc +IxBY5yggx3/lGi8tAgvUdarhd7mQO67UJ0V4YU3hAkbnZ8grHHXj+4hfgUpY4ok6 +yaed6HXwknBb9W8N1jZI8ginhkhjaeRCHdMiF+fBvNCtmeR1bCml1Uz7ailrpcaT +Mf84+5VYuFEnaRZYWFNsWNCOBlJ/6/b3V10vMXzMmYHqz3xgAq0M3fVTFTzopnAX +DLSzorL/dYVdqEDCQi5XI9YAlgWN4VeGzJI+glkLOCNzHxRNP6Qev+YI+7Uxz6I= +-----END CERTIFICATE----- diff --git a/client/src/test/resources/ssl/test.ca.key b/client/src/test/resources/ssl/test.ca.key new file mode 100644 index 000000000..6006d0f27 --- /dev/null +++ b/client/src/test/resources/ssl/test.ca.key @@ -0,0 +1,30 @@ +-----BEGIN RSA PRIVATE KEY----- +Proc-Type: 4,ENCRYPTED +DEK-Info: DES-EDE3-CBC,6D12ED8559E80FA3 + +tv9epnwlt4dP6Q5ee0dACOyFA5BTwYTdoMykQRJrKGwfaNeXUXn+sQ/U/oFHp1Wx +O8VZE+z2aHpiFSTw+Eh6MPt86X5yVG3tpeVO6dErvr8Kd+NpuI8zn7rNoOFRh8wD +33EFcQMLQPneDl10O18hooIoi0qwp1pd63hYZPwEhB3eOrM5Mnv9OVJs65bzYfyf +Wku33YWYxeqlDvMCsou8PZnv/M2wYsr7+QoTcNmGKP45igMthMDBzwgF+q0p9ZZU +N11c6ojAs01kfuqFf3vKfHNYe6zsBiNhnUuEy8enXSxD5E7tR/OI8aEzPLdk7fmN +/UsMK2LE0Yd5iS3O1x/1ZjSBxJ+M/UzzCO692GTAiD6Hc13iJOavq/vt1mEPjfCD +neF38Bhb5DfFi+UAHrz6EHMreamGCzP82us2maIs7mSTq7nXDZfbBc7mBDLAUUnT +J6tlrTyc+DQXzkJa6jmbxJhcsWm6XvjIBEzSXVHxEDPLnZICQk3VXODjCXTD75Rg +0WaS78Ven7DW8wn07q3VzWAFDKaet3VI+TVTv7EfIavlfiA6LSshaENdFLeHahNE +s/V/j5K3Pg6+WQcZRgOsfqIwUCSQxY13R6TTdaaCkLay5BggF5iiAO3pkqsJiadf +w843Ak4USBptymJxoZgJyFtQHpQyNiFfsAbs9BaYbg2evvE7/VQhLk0gQ7HgQMeJ +wgxEQqZQKDCCSugSzY1YEGXKnrZYCKyipzyyH936mE15zNwhYp/Pi2020+gmtP3h +CDfcPs1yeLI2/1JuimafbuKsv9xchWa6ASU8p8Q7wTLtUj9ylLKyA4A/75pK0DXG +Hv/q0O+UfhAMD438SoPBle7RSvIsDU1VjUqstlNybBglBZxGIME7/18+Ms7U32wh +4xFkZwxT2nqFgyk37tXMdMz9UBh12/AXR9NU4XY37C3Ao2TDT7/0DvU6KdJhsDpv +rGcaC2zzhko+0CPrLlk52KbqP003JXiWvOSI+FylyPPDB/YGitmndJUuQblf3u/E +l+tGi9MeSBQeWKV6D3AVnO05AZjfTUzSK0vw4DgNh5YPNJvLy31B7kDAS88vyGI1 +t6MBwjW4/tz/nS/p1Go3mSzBhPkIsCrZE+ar7lH8p8JqkLl4fXIMaVKIfyfJdzyS +lkh3K7bOGDPegxxxaWdb+EnC7k+1R3EOU7uJFW61HyrGI3q6Y7kOl5aYSJ5Ge1Uv +PycFWHWVTHq/R7HRE6HIJzGe/PnLIbStXLDFeivjfcYq1YaSaF8Vl+xg+0u3ULOl +P6IuPTph6dlcgttRZVl3ETcF0T+2wfbUwgjf0ZiguCJfR2jLGhPl1KBg0Kd9cTSY +zI3YMMd2G8hApt/QFlm4Ry8CqaJUmDcjDNIJT3M+RldUgfz37NsX05cA5e9+I1AL +2406F/v5U9gWsYx7HuwJtQrDzYYDbl1GD4H+qHFJE5JYhPP4AyWYxJ1NR5dqyvrt ++3r5+xlwZrS76c10RsBWL7th8ZEzRxOZxbtLwbf4bG/tIGfQP2sTnWwA+qym6b2S +sRduqOTP+xwnhOq/ZKn8lfsDfhT8CPnKHBsd09kM9y/UWuxFe0upLydRLE/Wsb9s +-----END RSA PRIVATE KEY----- diff --git a/client/src/test/resources/ssl/test.ca.password b/client/src/test/resources/ssl/test.ca.password new file mode 100644 index 000000000..143be9ab9 --- /dev/null +++ b/client/src/test/resources/ssl/test.ca.password @@ -0,0 +1 @@ +vesoft diff --git a/client/src/test/resources/ssl/test.ca.pem b/client/src/test/resources/ssl/test.ca.pem new file mode 100644 index 000000000..412ba3161 --- /dev/null +++ b/client/src/test/resources/ssl/test.ca.pem @@ -0,0 +1,24 @@ +-----BEGIN CERTIFICATE----- +MIIEGzCCAwOgAwIBAgIUDcmZFpL4PcdCXfLRBK8bR2vb39cwDQYJKoZIhvcNAQEL +BQAwgZwxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwI +SGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9u +MRYwFAYDVQQDDA1zaHlsb2NrIGh1YW5nMScwJQYJKoZIhvcNAQkBFhhzaHlsb2Nr +Lmh1YW5nQHZlc29mdC5jb20wHhcNMjEwODE5MDkyNDQ3WhcNMjUwODE4MDkyNDQ3 +WjCBnDELMAkGA1UEBhMCQ04xETAPBgNVBAgMCFpoZWppYW5nMREwDwYDVQQHDAhI +YW5nemhvdTEUMBIGA1UECgwLVmVzb2Z0IEluYy4xEDAOBgNVBAsMB3NlY3Rpb24x +FjAUBgNVBAMMDXNoeWxvY2sgaHVhbmcxJzAlBgkqhkiG9w0BCQEWGHNoeWxvY2su +aHVhbmdAdmVzb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AMEAgpamCQHl+8JnUHI6/VmJHjDLYJLTliN/CwpFrhMqIVjJ8wG57WYLpXpn91Lz +eHu52LkVzcikybIJ2a+LOTvnhNFdbmTbqDtrb+s6wM/sO+nF6tU2Av4e5zhyKoeR +LL+rHMk3nymohbdN4djySFmOOU5A1O/4b0bZz4Ylu995kUawdiaEo13BzxxOC7Ik +Gge5RyDcm0uLXZqTAPy5Sjv/zpOyj0AqL1CJUH7XBN9OMRhVU0ZX9nHWl1vgLRld +J6XT17Y9QbbHhCNEdAmFE5kEFgCvZc+MungUYABlkvoj86TLmC/FMV6fWdxQssyd +hS+ssfJFLaTDaEFz5a/Tr48CAwEAAaNTMFEwHQYDVR0OBBYEFK0GVrQx+wX1GCHy +e+6fl4X+prmYMB8GA1UdIwQYMBaAFK0GVrQx+wX1GCHye+6fl4X+prmYMA8GA1Ud +EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAHqP8P+ZUHmngviHLSSN1ln5 +Mx4BCkVeFRUaFx0yFXytV/iLXcG2HpFg3A9rAFoYgCDwi1xpsERnBZ/ShTv/eFOc +IxBY5yggx3/lGi8tAgvUdarhd7mQO67UJ0V4YU3hAkbnZ8grHHXj+4hfgUpY4ok6 +yaed6HXwknBb9W8N1jZI8ginhkhjaeRCHdMiF+fBvNCtmeR1bCml1Uz7ailrpcaT +Mf84+5VYuFEnaRZYWFNsWNCOBlJ/6/b3V10vMXzMmYHqz3xgAq0M3fVTFTzopnAX +DLSzorL/dYVdqEDCQi5XI9YAlgWN4VeGzJI+glkLOCNzHxRNP6Qev+YI+7Uxz6I= +-----END CERTIFICATE----- diff --git a/client/src/test/resources/ssl/test.ca.srl b/client/src/test/resources/ssl/test.ca.srl new file mode 100644 index 000000000..877d296b7 --- /dev/null +++ b/client/src/test/resources/ssl/test.ca.srl @@ -0,0 +1 @@ +4AF2EBB941EA7EE8358ECC7E51C2F1A38EE18873 diff --git a/client/src/test/resources/ssl/test.derive.crt b/client/src/test/resources/ssl/test.derive.crt new file mode 100644 index 000000000..8f03073e2 --- /dev/null +++ b/client/src/test/resources/ssl/test.derive.crt @@ -0,0 +1,23 @@ +-----BEGIN CERTIFICATE----- +MIIDvjCCAqYCFEry67lB6n7oNY7MflHC8aOO4YhzMA0GCSqGSIb3DQEBCwUAMIGc +MQswCQYDVQQGEwJDTjERMA8GA1UECAwIWmhlamlhbmcxETAPBgNVBAcMCEhhbmd6 +aG91MRQwEgYDVQQKDAtWZXNvZnQgSW5jLjEQMA4GA1UECwwHc2VjdGlvbjEWMBQG +A1UEAwwNc2h5bG9jayBodWFuZzEnMCUGCSqGSIb3DQEJARYYc2h5bG9jay5odWFu +Z0B2ZXNvZnQuY29tMB4XDTIxMDgyNDEwNTExMloXDTIzMTEyNzEwNTExMlowgZkx +CzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwISGFuZ3po +b3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9uMRMwEQYD +VQQDDApTaHlsb2NrIEhnMScwJQYJKoZIhvcNAQkBFhhzaHlsb2NrLmh1YW5nQHZl +c29mdC5jb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDHk1PQtaCG +S31nvxKuT6pzVQuOsA2hEIDzBZuoBK3blezBB16fjUWG2wHG/r9Oss5YzOly4viL +1oFLsNdYg27EFH7pcGfdSUmZa6LHILegJTmLa1aB4lRG9EsvPIxNuo637CW2z6EW +ElVKXn2N1G1vW3fpKGxJ+d1ovaFfBliO0sK+myW+vYdKrNg70WqKKCoCIlIjEWw3 +vQdrmvhuhIBbG1bXkXbJwIepBdb4wGSx8qsgs93I6/je/K/iJaPJIqdH8loo6fSo +DBUiNA87ZsQdtbBeuk7QuF71SxD5+E8wCMtFMwRGmL0vYMPwkaurKxwEs49e8eTz +RvIrNtyYgVo7AgMBAAEwDQYJKoZIhvcNAQELBQADggEBAGBpm5OLXn02kWr1ENU5 +FOOVryD41SCmPy8hLwQ2MCXd446UfTXc5TTlllksaePn373ZANLUe78vUCoVPjOh +dU5GxyOKtubXovI+yuvMS11u00KtgiAd5qa+IhX3c/P60bh4+fdKZ9ViyLsG+IpQ ++XDYT2uekLyjXXJU6h1raW7M1VY9FcDC63moXz0WgWJ/9tJgB0ZQkVcL+2UpveoZ +Whf9P0xAzCmNSrR7CMhdeRN2vBQQaHXk/64wkHncdkz/NglVl00rh4MtBKZ6Cqze +uZvgrxOJNzB4aXBMHO7sWzw1VSfS79CZm4H39hBWGiVEkr3yZYQbboDRY6F5dQyc +BZc= +-----END CERTIFICATE----- diff --git a/client/src/test/resources/ssl/test.derive.csr b/client/src/test/resources/ssl/test.derive.csr new file mode 100644 index 000000000..89b26237e --- /dev/null +++ b/client/src/test/resources/ssl/test.derive.csr @@ -0,0 +1,19 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIDEjCCAfoCAQAwgZkxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzER +MA8GA1UEBwwISGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQL +DAdzZWN0aW9uMRMwEQYDVQQDDApTaHlsb2NrIEhnMScwJQYJKoZIhvcNAQkBFhhz +aHlsb2NrLmh1YW5nQHZlc29mdC5jb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw +ggEKAoIBAQDHk1PQtaCGS31nvxKuT6pzVQuOsA2hEIDzBZuoBK3blezBB16fjUWG +2wHG/r9Oss5YzOly4viL1oFLsNdYg27EFH7pcGfdSUmZa6LHILegJTmLa1aB4lRG +9EsvPIxNuo637CW2z6EWElVKXn2N1G1vW3fpKGxJ+d1ovaFfBliO0sK+myW+vYdK +rNg70WqKKCoCIlIjEWw3vQdrmvhuhIBbG1bXkXbJwIepBdb4wGSx8qsgs93I6/je +/K/iJaPJIqdH8loo6fSoDBUiNA87ZsQdtbBeuk7QuF71SxD5+E8wCMtFMwRGmL0v +YMPwkaurKxwEs49e8eTzRvIrNtyYgVo7AgMBAAGgMzAVBgkqhkiG9w0BCQcxCAwG +dmVzb2Z0MBoGCSqGSIb3DQEJAjENDAtWZXNvZnQgSW5jLjANBgkqhkiG9w0BAQsF +AAOCAQEAjmyCyxziJMR8NILRAwmfYcBB90CbTFMMEyWy402KxoXcyVZBGO2eukIq +gaF2ywuh6yuTPtGsdVMVTWDQ4RLYpoQoR5Blu+M8Or8rhZSfMYXi79Ne3abSF28E +eWjBmh2Ys0GtaThlufJBWE+vWPH2iEGrSRTg1fvBLBzAW6nXU2svoTrKfDcEoY5z +xB0CKhBoewoIZ2FPBmBAnIWHfXR/vQ76QIoNdfQ4nT8iXuLRoNjRlvVU4AUDwKtu +keRDrnmJ7A5eqTlleCMzra2MAp9Na9gojXlGQP9q9V8nFtSvbjYAoH0ezWpdWj4+ +Rtu9EK4JkDymmmZcneFapExZrRLt0A== +-----END CERTIFICATE REQUEST----- diff --git a/client/src/test/resources/ssl/test.derive.key b/client/src/test/resources/ssl/test.derive.key new file mode 100644 index 000000000..a011917b3 --- /dev/null +++ b/client/src/test/resources/ssl/test.derive.key @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEowIBAAKCAQEAx5NT0LWghkt9Z78Srk+qc1ULjrANoRCA8wWbqASt25XswQde +n41FhtsBxv6/TrLOWMzpcuL4i9aBS7DXWINuxBR+6XBn3UlJmWuixyC3oCU5i2tW +geJURvRLLzyMTbqOt+wlts+hFhJVSl59jdRtb1t36ShsSfndaL2hXwZYjtLCvpsl +vr2HSqzYO9FqiigqAiJSIxFsN70Ha5r4boSAWxtW15F2ycCHqQXW+MBksfKrILPd +yOv43vyv4iWjySKnR/JaKOn0qAwVIjQPO2bEHbWwXrpO0Lhe9UsQ+fhPMAjLRTME +Rpi9L2DD8JGrqyscBLOPXvHk80byKzbcmIFaOwIDAQABAoIBAEZ50URHjzs9VziW +sdsaSN/XbXBi3T0+Xbr0BQatOFPtuqBjoNeJBL9dgWArP5Vj8RhMrDekzQ5cnmYD +OdiI+UmGz1ZSGmt7YOErsFzPQejsnEiOjArryMURqacxo34jXhi27I6E/aaUrMfJ +XF8EX+zOCSct3ie1c6l0JZMv43/zbzP2vMFEdfnVfZA2Kxo5l3I4rjuxHUEWHzrb +EgM4a2+y7LQrut75zP9zWEZAqim/VEIEj24Gqj+Vocb6cHlc31KzKaEz7Ra5ha2J +kN2CQRKCzoMupVL5E6dWMiDVjUyUXdUgjSCIW2H+E1ONgvxA78jJx7+Dzj+/bWxH +h/vr3dkCgYEA9Aev7PGoGF0eapZY3crehvtCn1v4YLheh0dk4EpbpbEx0rQaG3h7 +YYCf7euxMvoTsKPETHAUG/s/RZV1DNOjxs8GKgEIVaRYEf1VZeDXudtnyKBwCMAL +5CKHRBvfmNG9n+PpQQlrIAZGej7HU+/IzEVsrD2A5DeH9IVpMNvrX10CgYEA0V1r +aydbBP+Ma/fiG5UDa8l4GdLzvAoW2cY6ZhQX4NiLTK91MwA/QOQcVMvJAN2KpPHC +kGDRT7IhMs66cMxl0ImIJ2QSnv8HRNmBBSdUtJx1S6nV2u0VfgP61oNT/YbLR/Jk +CAIl1qe7Q8IsrMbPxCbt8g+D8Wr9C3pdYYqFvncCgYEAicGdKmDwx3Apr3nYCLxx +CjnkzhkZCWCK3EsNQyA2xD5XJd7NrhxBajU2ExUuHtzVKK4KLixG7dTTTvCj9u2y +UpSjoiqbDd2MaftcrfpTTXPyDmujUw02qT5kpaomexpLtWrvTeuHMbjZKEEwPM3r +yISYaFL/49UFRp/ZVd+P63ECgYAX1B0ctf77A6bUxwK6Buy7wNNlhQful+tf39rX +sWPCWIMKOFILevS4Cv5afFMlQRG9kjKFwi8wdeKnaLX5jpnr8StI6G/iHr6SDHtN +vds7Ly9+bBcF8sPmcseC0LGngkbyqljOPIhX9QEwRhJVm88b0R511WQ7/uRMASJN +rrloIwKBgCxYlu1xvvEuQNoIux/yKAEJ1h4Ta2zc5upjw0uDKMi0UNIbNhgdFOvj +LuVbxTRU8WktrLNk3T0rsopKsTbEZVg6Yuv8ZLkEiNYTzhUbn2Y5yM3bnoVwyOns +pTtqmBtvDZxaRCYdIQG3b09IvrewDk26AOtNHdeKw883G2muP/vA +-----END RSA PRIVATE KEY----- diff --git a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java index 6b78cbb80..f9e0c1ce7 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java @@ -8,9 +8,12 @@ import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; +import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.client.graph.NebulaPoolConfig; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.data.ValueWrapper; import com.vesoft.nebula.client.graph.net.NebulaPool; import com.vesoft.nebula.client.graph.net.Session; @@ -79,7 +82,7 @@ private static void printResult(ResultSet resultSet) throws UnsupportedEncodingE public static void main(String[] args) { NebulaPool pool = new NebulaPool(); - Session session = null; + Session session; try { NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); nebulaPoolConfig.setMaxConnSize(100); @@ -146,22 +149,62 @@ public static void main(String[] args) { { String queryForJson = "YIELD 1"; String resp = session.executeJson(queryForJson); - JSONObject errors = JSON.parseObject(resp).getJSONArray("result").getJSONObject(0) - .getJSONObject("errors"); - if (!errors.getString("errorCode").equals("0")) { + JSONObject errors = JSON.parseObject(resp).getJSONArray("errors").getJSONObject(0); + if (errors.getInteger("code") != 0) { log.error(String.format("Execute: `%s', failed: %s", - queryForJson, errors.getString("errorMsg"))); + queryForJson, errors.getString("message"))); + System.exit(1); + } + System.out.println(resp); + } + + { + NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); + nebulaSslPoolConfig.setMaxConnSize(100); + nebulaSslPoolConfig.setEnableSsl(true); + nebulaSslPoolConfig.setSslParam(new CASignedSSLParam( + "examples/src/main/resources/ssl/casigned.pem", + "examples/src/main/resources/ssl/casigned.crt", + "examples/src/main/resources/ssl/casigned.key")); + NebulaPool sslPool = new NebulaPool(); + sslPool.init(Arrays.asList(new HostAddress("192.168.8.123", 9669)), + nebulaSslPoolConfig); + String queryForJson = "YIELD 1"; + Session sslSession = sslPool.getSession("root", "nebula", false); + String resp = sslSession.executeJson(queryForJson); + JSONObject errors = JSON.parseObject(resp).getJSONArray("errors").getJSONObject(0); + if (errors.getInteger("code") != ErrorCode.SUCCEEDED.getValue()) { + log.error(String.format("Execute: `%s', failed: %s", + queryForJson, errors.getString("message"))); + System.exit(1); + } + System.out.println(resp); + } + + { + NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); + nebulaSslPoolConfig.setMaxConnSize(100); + nebulaSslPoolConfig.setEnableSsl(true); + nebulaSslPoolConfig.setSslParam(new SelfSignedSSLParam( + "examples/src/main/resources/ssl/selfsigned.pem", + "examples/src/main/resources/ssl/selfsigned.key", + "vesoft")); + NebulaPool sslPool = new NebulaPool(); + sslPool.init(Arrays.asList(new HostAddress("192.168.8.123", 9669)), + nebulaSslPoolConfig); + String queryForJson = "YIELD 1"; + Session sslSession = sslPool.getSession("root", "nebula", false); + String resp = sslSession.executeJson(queryForJson); + JSONObject errors = JSON.parseObject(resp).getJSONArray("errors").getJSONObject(0); + if (errors.getInteger("code") != ErrorCode.SUCCEEDED.getValue()) { + log.error(String.format("Execute: `%s', failed: %s", + queryForJson, errors.getString("message"))); System.exit(1); } System.out.println(resp); } } catch (Exception e) { e.printStackTrace(); - } finally { - if (session != null) { - session.release(); - } - pool.close(); } } } diff --git a/examples/src/main/resources/ssl/casigned.crt b/examples/src/main/resources/ssl/casigned.crt new file mode 100644 index 000000000..fe1add667 --- /dev/null +++ b/examples/src/main/resources/ssl/casigned.crt @@ -0,0 +1,16 @@ +-----BEGIN CERTIFICATE----- +MIICljCCAX4CCQC9uuUY+ah8qzANBgkqhkiG9w0BAQsFADANMQswCQYDVQQGEwJD +TjAeFw0yMTA5MjkwNzM4MDRaFw0yNDAxMDIwNzM4MDRaMA0xCzAJBgNVBAYTAkNO +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuo7hKpcs+VQKbGRq0fUL ++GcSfPfJ8mARtIeI8WfU0j1vI5KNujI//G2olOGEueDCw4OO0UbdjnsFpgj2awAo +rj4ga2W6adQHK8qHY6q/Rdqv0oDCrcePMtQ8IwbFjNWOXC4bn7GcV7mzOkigdcj8 +UPkSeaqI9XxBRm3OoDX+T8h6cDLrm+ncKB8KKe/QApKH4frV3HYDqGtN49zuRs6F +iurFbXDGVAZEdFEJl38IQJdmE2ASOzEHZbxWKzO/DZr/Z2+L1CuycZIwuITcnddx +b2Byx/opwX4HlyODeUBbyDp+hd+GkasmIcpOlIDw9OXIvrcajKvzLEbqGt2ThsxX +QwIDAQABMA0GCSqGSIb3DQEBCwUAA4IBAQAxzxtbYBQ2WgBGrpzOX4TxsuSaigqo +YJ5zbVEHtwbsbBTZ7UJvRc9IyhrOL5Ui4PJI85chh1GpGqOmMoYSaWdddaIroilQ +56bn5haB8ezAMnLXbPuf97UENO0RIkyzt63XPIUkDnwlzOukIq50qgsYEDuiioM/ +wpCqSbMJ4iK/SlSSUWw3cKuAHvFfLv7hkC6AhvT7yfaCNDs29xEQUCD12XlIdFGH +FjMgVMcvcIePQq5ZcmSfVMge9jPjPx/Nj9SVauF5z5pil9qHG4jyXPGThiiJ3CE4 +GU5d/Qfe7OeiYI3LaoVufZ5pZnR9nMnpzqU46w9gY7vgi6bAhNwsCDr3 +-----END CERTIFICATE----- diff --git a/examples/src/main/resources/ssl/casigned.key b/examples/src/main/resources/ssl/casigned.key new file mode 100644 index 000000000..3561e7ab8 --- /dev/null +++ b/examples/src/main/resources/ssl/casigned.key @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEpAIBAAKCAQEAuo7hKpcs+VQKbGRq0fUL+GcSfPfJ8mARtIeI8WfU0j1vI5KN +ujI//G2olOGEueDCw4OO0UbdjnsFpgj2awAorj4ga2W6adQHK8qHY6q/Rdqv0oDC +rcePMtQ8IwbFjNWOXC4bn7GcV7mzOkigdcj8UPkSeaqI9XxBRm3OoDX+T8h6cDLr +m+ncKB8KKe/QApKH4frV3HYDqGtN49zuRs6FiurFbXDGVAZEdFEJl38IQJdmE2AS +OzEHZbxWKzO/DZr/Z2+L1CuycZIwuITcnddxb2Byx/opwX4HlyODeUBbyDp+hd+G +kasmIcpOlIDw9OXIvrcajKvzLEbqGt2ThsxXQwIDAQABAoIBAH4SEBe4EaxsHp8h +PQ6linFTNis9SDuCsHRPIzv/7tIksfZYE27Ahn0Pndz+ibMTMIrvXJQQT6j5ede6 +NswYT2Vwlnf9Rvw9TJtLQjMYMCoEnsyiNu047oxq4DjLWrTRnGKuxfwlCoI9++Bn +NAhkyh3uM44EsIk0bugpTHj4A+PlbUPe7xdEI/6XpaZrRN9oiejJ4VxZAPgFGiTm +uNF5qg16+0900Pfj5Y/M4vXmn+gq39PO/y0FlTpaoEuYZiZZS3xHGmSVhlt8LIgI +8MdMRaKTfNeNITaqgOWh9pAW4xmK48/KfLgNPQgtDHjMJpgM0BbcBOayOY8Eio0x +Z66G2AECgYEA9vj/8Fm3CKn/ogNOO81y9kIs0iPcbjasMnQ3UXeOdD0z0+7TM86F +Xj3GK/z2ecvY7skWtO5ZUbbxp4aB7omW8Ke9+q8XPzMEmUuAOTzxQkAOxdr++HXP +TILy0hNX2cmiLQT1U60KoZHzPZ5o5hNIQPMt7hN12ERWcIfR/MUZa5UCgYEAwWCP +6Y7Zso1QxQR/qfjuILET3/xU+ZmqSRDvzJPEiGI3oeWNG4L6cKR+XTe0FWZBAmVk +Qq/1qXmdBnf5S7azffoJe2+H/m3kHJSprIiAAWlBN2e+kFlNfBhtkgia5NvsrjRw +al6mf/+weRD1FiPoZY3e1wBKoqro7aI8fE5gwXcCgYEAnEI05OROeyvb8qy2vf2i +JA8AfsBzwkPTNWT0bxX+yqrCdO/hLyEWnubk0IYPiEYibgpK1JUNbDcctErVQJBL +MN5gxBAt3C2yVi8/5HcbijgvYJ3LvnYDf7xGWAYnCkOZ2XQOqC+Oz2UhijYE1rUS +fQ2fXMdxQzERo8c7Y/tstvUCgYBuixy5jwezokUB20h/ieXWmmOaL00EQmutyRjM +AczfigXzbp3zlDRGIEJ8V1OCyClxjTR7SstMTlENWZgRSCfjZAP3pBJBx+AW1oUI +NB+4rsqxOYUeT26T+gLo8DJbkb0C+Mcqh2D22tuu2ZrBRVWceDVjAq+nvbvZ3Fxn +UwbMkQKBgQCxL3aA6ART6laIxT/ZqMhV0ZcaoDJogjF+4I4bhlO4ivWGWJ4RpEDn +ziFb6+M/4pe4vCou9yuAof6WTKM8JG4rok0yxhN3V6QGP49TjtrfkkrEPCtB2LSI +N1+YRSTrS5VDcl8h8JH7fpghRnXHONEyIqasYVqsbxKzNyLV/z2rkw== +-----END RSA PRIVATE KEY----- diff --git a/examples/src/main/resources/ssl/casigned.pem b/examples/src/main/resources/ssl/casigned.pem new file mode 100644 index 000000000..412ba3161 --- /dev/null +++ b/examples/src/main/resources/ssl/casigned.pem @@ -0,0 +1,24 @@ +-----BEGIN CERTIFICATE----- +MIIEGzCCAwOgAwIBAgIUDcmZFpL4PcdCXfLRBK8bR2vb39cwDQYJKoZIhvcNAQEL +BQAwgZwxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwI +SGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9u +MRYwFAYDVQQDDA1zaHlsb2NrIGh1YW5nMScwJQYJKoZIhvcNAQkBFhhzaHlsb2Nr +Lmh1YW5nQHZlc29mdC5jb20wHhcNMjEwODE5MDkyNDQ3WhcNMjUwODE4MDkyNDQ3 +WjCBnDELMAkGA1UEBhMCQ04xETAPBgNVBAgMCFpoZWppYW5nMREwDwYDVQQHDAhI +YW5nemhvdTEUMBIGA1UECgwLVmVzb2Z0IEluYy4xEDAOBgNVBAsMB3NlY3Rpb24x +FjAUBgNVBAMMDXNoeWxvY2sgaHVhbmcxJzAlBgkqhkiG9w0BCQEWGHNoeWxvY2su +aHVhbmdAdmVzb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AMEAgpamCQHl+8JnUHI6/VmJHjDLYJLTliN/CwpFrhMqIVjJ8wG57WYLpXpn91Lz +eHu52LkVzcikybIJ2a+LOTvnhNFdbmTbqDtrb+s6wM/sO+nF6tU2Av4e5zhyKoeR +LL+rHMk3nymohbdN4djySFmOOU5A1O/4b0bZz4Ylu995kUawdiaEo13BzxxOC7Ik +Gge5RyDcm0uLXZqTAPy5Sjv/zpOyj0AqL1CJUH7XBN9OMRhVU0ZX9nHWl1vgLRld +J6XT17Y9QbbHhCNEdAmFE5kEFgCvZc+MungUYABlkvoj86TLmC/FMV6fWdxQssyd +hS+ssfJFLaTDaEFz5a/Tr48CAwEAAaNTMFEwHQYDVR0OBBYEFK0GVrQx+wX1GCHy +e+6fl4X+prmYMB8GA1UdIwQYMBaAFK0GVrQx+wX1GCHye+6fl4X+prmYMA8GA1Ud +EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAHqP8P+ZUHmngviHLSSN1ln5 +Mx4BCkVeFRUaFx0yFXytV/iLXcG2HpFg3A9rAFoYgCDwi1xpsERnBZ/ShTv/eFOc +IxBY5yggx3/lGi8tAgvUdarhd7mQO67UJ0V4YU3hAkbnZ8grHHXj+4hfgUpY4ok6 +yaed6HXwknBb9W8N1jZI8ginhkhjaeRCHdMiF+fBvNCtmeR1bCml1Uz7ailrpcaT +Mf84+5VYuFEnaRZYWFNsWNCOBlJ/6/b3V10vMXzMmYHqz3xgAq0M3fVTFTzopnAX +DLSzorL/dYVdqEDCQi5XI9YAlgWN4VeGzJI+glkLOCNzHxRNP6Qev+YI+7Uxz6I= +-----END CERTIFICATE----- diff --git a/examples/src/main/resources/ssl/selfsigned.key b/examples/src/main/resources/ssl/selfsigned.key new file mode 100644 index 000000000..6006d0f27 --- /dev/null +++ b/examples/src/main/resources/ssl/selfsigned.key @@ -0,0 +1,30 @@ +-----BEGIN RSA PRIVATE KEY----- +Proc-Type: 4,ENCRYPTED +DEK-Info: DES-EDE3-CBC,6D12ED8559E80FA3 + +tv9epnwlt4dP6Q5ee0dACOyFA5BTwYTdoMykQRJrKGwfaNeXUXn+sQ/U/oFHp1Wx +O8VZE+z2aHpiFSTw+Eh6MPt86X5yVG3tpeVO6dErvr8Kd+NpuI8zn7rNoOFRh8wD +33EFcQMLQPneDl10O18hooIoi0qwp1pd63hYZPwEhB3eOrM5Mnv9OVJs65bzYfyf +Wku33YWYxeqlDvMCsou8PZnv/M2wYsr7+QoTcNmGKP45igMthMDBzwgF+q0p9ZZU +N11c6ojAs01kfuqFf3vKfHNYe6zsBiNhnUuEy8enXSxD5E7tR/OI8aEzPLdk7fmN +/UsMK2LE0Yd5iS3O1x/1ZjSBxJ+M/UzzCO692GTAiD6Hc13iJOavq/vt1mEPjfCD +neF38Bhb5DfFi+UAHrz6EHMreamGCzP82us2maIs7mSTq7nXDZfbBc7mBDLAUUnT +J6tlrTyc+DQXzkJa6jmbxJhcsWm6XvjIBEzSXVHxEDPLnZICQk3VXODjCXTD75Rg +0WaS78Ven7DW8wn07q3VzWAFDKaet3VI+TVTv7EfIavlfiA6LSshaENdFLeHahNE +s/V/j5K3Pg6+WQcZRgOsfqIwUCSQxY13R6TTdaaCkLay5BggF5iiAO3pkqsJiadf +w843Ak4USBptymJxoZgJyFtQHpQyNiFfsAbs9BaYbg2evvE7/VQhLk0gQ7HgQMeJ +wgxEQqZQKDCCSugSzY1YEGXKnrZYCKyipzyyH936mE15zNwhYp/Pi2020+gmtP3h +CDfcPs1yeLI2/1JuimafbuKsv9xchWa6ASU8p8Q7wTLtUj9ylLKyA4A/75pK0DXG +Hv/q0O+UfhAMD438SoPBle7RSvIsDU1VjUqstlNybBglBZxGIME7/18+Ms7U32wh +4xFkZwxT2nqFgyk37tXMdMz9UBh12/AXR9NU4XY37C3Ao2TDT7/0DvU6KdJhsDpv +rGcaC2zzhko+0CPrLlk52KbqP003JXiWvOSI+FylyPPDB/YGitmndJUuQblf3u/E +l+tGi9MeSBQeWKV6D3AVnO05AZjfTUzSK0vw4DgNh5YPNJvLy31B7kDAS88vyGI1 +t6MBwjW4/tz/nS/p1Go3mSzBhPkIsCrZE+ar7lH8p8JqkLl4fXIMaVKIfyfJdzyS +lkh3K7bOGDPegxxxaWdb+EnC7k+1R3EOU7uJFW61HyrGI3q6Y7kOl5aYSJ5Ge1Uv +PycFWHWVTHq/R7HRE6HIJzGe/PnLIbStXLDFeivjfcYq1YaSaF8Vl+xg+0u3ULOl +P6IuPTph6dlcgttRZVl3ETcF0T+2wfbUwgjf0ZiguCJfR2jLGhPl1KBg0Kd9cTSY +zI3YMMd2G8hApt/QFlm4Ry8CqaJUmDcjDNIJT3M+RldUgfz37NsX05cA5e9+I1AL +2406F/v5U9gWsYx7HuwJtQrDzYYDbl1GD4H+qHFJE5JYhPP4AyWYxJ1NR5dqyvrt ++3r5+xlwZrS76c10RsBWL7th8ZEzRxOZxbtLwbf4bG/tIGfQP2sTnWwA+qym6b2S +sRduqOTP+xwnhOq/ZKn8lfsDfhT8CPnKHBsd09kM9y/UWuxFe0upLydRLE/Wsb9s +-----END RSA PRIVATE KEY----- diff --git a/examples/src/main/resources/ssl/selfsigned.password b/examples/src/main/resources/ssl/selfsigned.password new file mode 100644 index 000000000..143be9ab9 --- /dev/null +++ b/examples/src/main/resources/ssl/selfsigned.password @@ -0,0 +1 @@ +vesoft diff --git a/examples/src/main/resources/ssl/selfsigned.pem b/examples/src/main/resources/ssl/selfsigned.pem new file mode 100644 index 000000000..412ba3161 --- /dev/null +++ b/examples/src/main/resources/ssl/selfsigned.pem @@ -0,0 +1,24 @@ +-----BEGIN CERTIFICATE----- +MIIEGzCCAwOgAwIBAgIUDcmZFpL4PcdCXfLRBK8bR2vb39cwDQYJKoZIhvcNAQEL +BQAwgZwxCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhaaGVqaWFuZzERMA8GA1UEBwwI +SGFuZ3pob3UxFDASBgNVBAoMC1Zlc29mdCBJbmMuMRAwDgYDVQQLDAdzZWN0aW9u +MRYwFAYDVQQDDA1zaHlsb2NrIGh1YW5nMScwJQYJKoZIhvcNAQkBFhhzaHlsb2Nr +Lmh1YW5nQHZlc29mdC5jb20wHhcNMjEwODE5MDkyNDQ3WhcNMjUwODE4MDkyNDQ3 +WjCBnDELMAkGA1UEBhMCQ04xETAPBgNVBAgMCFpoZWppYW5nMREwDwYDVQQHDAhI +YW5nemhvdTEUMBIGA1UECgwLVmVzb2Z0IEluYy4xEDAOBgNVBAsMB3NlY3Rpb24x +FjAUBgNVBAMMDXNoeWxvY2sgaHVhbmcxJzAlBgkqhkiG9w0BCQEWGHNoeWxvY2su +aHVhbmdAdmVzb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AMEAgpamCQHl+8JnUHI6/VmJHjDLYJLTliN/CwpFrhMqIVjJ8wG57WYLpXpn91Lz +eHu52LkVzcikybIJ2a+LOTvnhNFdbmTbqDtrb+s6wM/sO+nF6tU2Av4e5zhyKoeR +LL+rHMk3nymohbdN4djySFmOOU5A1O/4b0bZz4Ylu995kUawdiaEo13BzxxOC7Ik +Gge5RyDcm0uLXZqTAPy5Sjv/zpOyj0AqL1CJUH7XBN9OMRhVU0ZX9nHWl1vgLRld +J6XT17Y9QbbHhCNEdAmFE5kEFgCvZc+MungUYABlkvoj86TLmC/FMV6fWdxQssyd +hS+ssfJFLaTDaEFz5a/Tr48CAwEAAaNTMFEwHQYDVR0OBBYEFK0GVrQx+wX1GCHy +e+6fl4X+prmYMB8GA1UdIwQYMBaAFK0GVrQx+wX1GCHye+6fl4X+prmYMA8GA1Ud +EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAHqP8P+ZUHmngviHLSSN1ln5 +Mx4BCkVeFRUaFx0yFXytV/iLXcG2HpFg3A9rAFoYgCDwi1xpsERnBZ/ShTv/eFOc +IxBY5yggx3/lGi8tAgvUdarhd7mQO67UJ0V4YU3hAkbnZ8grHHXj+4hfgUpY4ok6 +yaed6HXwknBb9W8N1jZI8ginhkhjaeRCHdMiF+fBvNCtmeR1bCml1Uz7ailrpcaT +Mf84+5VYuFEnaRZYWFNsWNCOBlJ/6/b3V10vMXzMmYHqz3xgAq0M3fVTFTzopnAX +DLSzorL/dYVdqEDCQi5XI9YAlgWN4VeGzJI+glkLOCNzHxRNP6Qev+YI+7Uxz6I= +-----END CERTIFICATE----- From fc643c79aa9511e42902ea84a42b7a928225e874 Mon Sep 17 00:00:00 2001 From: "Harris.Chu" <1726587+HarrisChu@users.noreply.github.com> Date: Thu, 14 Oct 2021 16:35:22 +0800 Subject: [PATCH 02/25] update codecov uploader (#369) --- .github/workflows/maven.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 9a28d7b4f..91f3ee1b1 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -47,4 +47,4 @@ jobs: - name: Build with Maven run: | mvn -B package - bash <(curl -s https://codecov.io/bash) + - uses: codecov/codecov-action@v2 From 8f1c23379004f185c818fdc2f17b65f261416b87 Mon Sep 17 00:00:00 2001 From: Klay Date: Mon, 18 Oct 2021 22:57:05 -0700 Subject: [PATCH 03/25] add version verification (#370) * update thrift code * add version verification * add meta client version check * fix typo * optimize sslSocketFactory creation in SyncConnection --- .../com/vesoft/nebula/Constants.java | 23 + .../com/vesoft/nebula/Coordinate.java | 349 +++++ .../generated/com/vesoft/nebula/DirInfo.java | 20 +- .../generated/com/vesoft/nebula/Edge.java | 28 +- .../com/vesoft/nebula/ErrorCode.java | 5 + .../com/vesoft/nebula/Geography.java | 281 ++++ .../com/vesoft/nebula/LineString.java | 286 ++++ .../vesoft/nebula/PartitionBackupInfo.java | 28 +- .../generated/com/vesoft/nebula/Path.java | 22 +- .../generated/com/vesoft/nebula/Point.java | 266 ++++ .../generated/com/vesoft/nebula/Polygon.java | 305 ++++ .../generated/com/vesoft/nebula/Step.java | 28 +- .../main/generated/com/vesoft/nebula/Tag.java | 28 +- .../generated/com/vesoft/nebula/Value.java | 42 + .../generated/com/vesoft/nebula/Vertex.java | 22 +- .../com/vesoft/nebula/graph/GraphService.java | 570 +++++++- .../nebula/graph/VerifyClientVersionReq.java | 275 ++++ .../nebula/graph/VerifyClientVersionResp.java | 389 +++++ .../com/vesoft/nebula/meta/ColumnTypeDef.java | 114 +- .../com/vesoft/nebula/meta/GeoShape.java | 52 + .../com/vesoft/nebula/meta/MetaService.java | 1250 ++++++++++++----- .../com/vesoft/nebula/meta/PropertyType.java | 5 +- .../nebula/meta/VerifyClientVersionReq.java | 275 ++++ .../nebula/meta/VerifyClientVersionResp.java | 474 +++++++ .../nebula/storage/ChainAddEdgesRequest.java | 705 ++++++++++ .../storage/ChainUpdateEdgeRequest.java | 595 ++++++++ .../nebula/storage/GeneralStorageService.java | 24 +- .../nebula/storage/GetValueRequest.java | 439 ------ .../nebula/storage/GetValueResponse.java | 365 ----- .../nebula/storage/GraphStorageService.java | 724 ++++++++-- .../storage/InternalStorageService.java | 363 ++--- .../nebula/storage/InternalTxnRequest.java | 545 +++---- .../vesoft/nebula/storage/RequestCommon.java | 95 +- .../nebula/storage/StorageAdminService.java | 128 +- .../ClientServerIncompatibleException.java | 18 + .../client/graph/net/ConnObjectPool.java | 3 +- .../nebula/client/graph/net/Connection.java | 8 +- .../nebula/client/graph/net/LoadBalancer.java | 1 + .../nebula/client/graph/net/NebulaPool.java | 4 +- .../graph/net/RoundRobinLoadBalancer.java | 10 +- .../nebula/client/graph/net/Session.java | 6 +- .../client/graph/net/SessionWrapper.java | 3 +- .../client/graph/net/SessionsManager.java | 4 +- .../client/graph/net/SyncConnection.java | 73 +- .../vesoft/nebula/client/meta/MetaClient.java | 32 +- .../nebula/client/meta/MetaManager.java | 4 +- .../client/graph/data/TestDataFromServer.java | 7 +- .../client/graph/net/TestConnectionPool.java | 2 +- .../nebula/client/graph/net/TestSession.java | 6 +- .../client/graph/net/TestSessionsManager.java | 6 +- .../nebula/client/meta/MockNebulaGraph.java | 3 +- .../nebula/client/meta/TestMetaClient.java | 5 +- .../nebula/client/meta/TestMetaManager.java | 3 +- .../client/storage/MockStorageData.java | 3 +- .../nebula/encoder/MetaCacheImplTest.java | 4 +- 55 files changed, 7321 insertions(+), 2004 deletions(-) create mode 100644 client/src/main/generated/com/vesoft/nebula/Constants.java create mode 100644 client/src/main/generated/com/vesoft/nebula/Coordinate.java create mode 100644 client/src/main/generated/com/vesoft/nebula/Geography.java create mode 100644 client/src/main/generated/com/vesoft/nebula/LineString.java create mode 100644 client/src/main/generated/com/vesoft/nebula/Point.java create mode 100644 client/src/main/generated/com/vesoft/nebula/Polygon.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionResp.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GeoShape.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionResp.java create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java diff --git a/client/src/main/generated/com/vesoft/nebula/Constants.java b/client/src/main/generated/com/vesoft/nebula/Constants.java new file mode 100644 index 000000000..b83205264 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Constants.java @@ -0,0 +1,23 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +@SuppressWarnings({ "unused" }) +public class Constants { + + public static final byte[] version = "2.6.0".getBytes(); + +} diff --git a/client/src/main/generated/com/vesoft/nebula/Coordinate.java b/client/src/main/generated/com/vesoft/nebula/Coordinate.java new file mode 100644 index 000000000..8d026e1d1 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Coordinate.java @@ -0,0 +1,349 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class Coordinate implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("Coordinate"); + private static final TField X_FIELD_DESC = new TField("x", TType.DOUBLE, (short)1); + private static final TField Y_FIELD_DESC = new TField("y", TType.DOUBLE, (short)2); + + public double x; + public double y; + public static final int X = 1; + public static final int Y = 2; + + // isset id assignments + private static final int __X_ISSET_ID = 0; + private static final int __Y_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(X, new FieldMetaData("x", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.DOUBLE))); + tmpMetaDataMap.put(Y, new FieldMetaData("y", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.DOUBLE))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(Coordinate.class, metaDataMap); + } + + public Coordinate() { + } + + public Coordinate( + double x, + double y) { + this(); + this.x = x; + setXIsSet(true); + this.y = y; + setYIsSet(true); + } + + public static class Builder { + private double x; + private double y; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setX(final double x) { + this.x = x; + __optional_isset.set(__X_ISSET_ID, true); + return this; + } + + public Builder setY(final double y) { + this.y = y; + __optional_isset.set(__Y_ISSET_ID, true); + return this; + } + + public Coordinate build() { + Coordinate result = new Coordinate(); + if (__optional_isset.get(__X_ISSET_ID)) { + result.setX(this.x); + } + if (__optional_isset.get(__Y_ISSET_ID)) { + result.setY(this.y); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public Coordinate(Coordinate other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.x = TBaseHelper.deepCopy(other.x); + this.y = TBaseHelper.deepCopy(other.y); + } + + public Coordinate deepCopy() { + return new Coordinate(this); + } + + public double getX() { + return this.x; + } + + public Coordinate setX(double x) { + this.x = x; + setXIsSet(true); + return this; + } + + public void unsetX() { + __isset_bit_vector.clear(__X_ISSET_ID); + } + + // Returns true if field x is set (has been assigned a value) and false otherwise + public boolean isSetX() { + return __isset_bit_vector.get(__X_ISSET_ID); + } + + public void setXIsSet(boolean __value) { + __isset_bit_vector.set(__X_ISSET_ID, __value); + } + + public double getY() { + return this.y; + } + + public Coordinate setY(double y) { + this.y = y; + setYIsSet(true); + return this; + } + + public void unsetY() { + __isset_bit_vector.clear(__Y_ISSET_ID); + } + + // Returns true if field y is set (has been assigned a value) and false otherwise + public boolean isSetY() { + return __isset_bit_vector.get(__Y_ISSET_ID); + } + + public void setYIsSet(boolean __value) { + __isset_bit_vector.set(__Y_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case X: + if (__value == null) { + unsetX(); + } else { + setX((Double)__value); + } + break; + + case Y: + if (__value == null) { + unsetY(); + } else { + setY((Double)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case X: + return new Double(getX()); + + case Y: + return new Double(getY()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof Coordinate)) + return false; + Coordinate that = (Coordinate)_that; + + if (!TBaseHelper.equalsNobinary(this.x, that.x)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.y, that.y)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {x, y}); + } + + @Override + public int compareTo(Coordinate other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetX()).compareTo(other.isSetX()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(x, other.x); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetY()).compareTo(other.isSetY()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(y, other.y); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case X: + if (__field.type == TType.DOUBLE) { + this.x = iprot.readDouble(); + setXIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case Y: + if (__field.type == TType.DOUBLE) { + this.y = iprot.readDouble(); + setYIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(X_FIELD_DESC); + oprot.writeDouble(this.x); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(Y_FIELD_DESC); + oprot.writeDouble(this.y); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("Coordinate"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("x"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getX(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("y"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getY(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/DirInfo.java b/client/src/main/generated/com/vesoft/nebula/DirInfo.java index baf43efcb..d61d0c209 100644 --- a/client/src/main/generated/com/vesoft/nebula/DirInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/DirInfo.java @@ -267,15 +267,15 @@ public void read(TProtocol iprot) throws TException { case DATA: if (__field.type == TType.LIST) { { - TList _list48 = iprot.readListBegin(); - this.data = new ArrayList(Math.max(0, _list48.size)); - for (int _i49 = 0; - (_list48.size < 0) ? iprot.peekList() : (_i49 < _list48.size); - ++_i49) + TList _list60 = iprot.readListBegin(); + this.data = new ArrayList(Math.max(0, _list60.size)); + for (int _i61 = 0; + (_list60.size < 0) ? iprot.peekList() : (_i61 < _list60.size); + ++_i61) { - byte[] _elem50; - _elem50 = iprot.readBinary(); - this.data.add(_elem50); + byte[] _elem62; + _elem62 = iprot.readBinary(); + this.data.add(_elem62); } iprot.readListEnd(); } @@ -309,8 +309,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(DATA_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.data.size())); - for (byte[] _iter51 : this.data) { - oprot.writeBinary(_iter51); + for (byte[] _iter63 : this.data) { + oprot.writeBinary(_iter63); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/Edge.java b/client/src/main/generated/com/vesoft/nebula/Edge.java index 7518c45e0..19fc60326 100644 --- a/client/src/main/generated/com/vesoft/nebula/Edge.java +++ b/client/src/main/generated/com/vesoft/nebula/Edge.java @@ -494,18 +494,18 @@ public void read(TProtocol iprot) throws TException { case PROPS: if (__field.type == TType.MAP) { { - TMap _map34 = iprot.readMapBegin(); - this.props = new HashMap(Math.max(0, 2*_map34.size)); - for (int _i35 = 0; - (_map34.size < 0) ? iprot.peekMap() : (_i35 < _map34.size); - ++_i35) + TMap _map46 = iprot.readMapBegin(); + this.props = new HashMap(Math.max(0, 2*_map46.size)); + for (int _i47 = 0; + (_map46.size < 0) ? iprot.peekMap() : (_i47 < _map46.size); + ++_i47) { - byte[] _key36; - Value _val37; - _key36 = iprot.readBinary(); - _val37 = new Value(); - _val37.read(iprot); - this.props.put(_key36, _val37); + byte[] _key48; + Value _val49; + _key48 = iprot.readBinary(); + _val49 = new Value(); + _val49.read(iprot); + this.props.put(_key48, _val49); } iprot.readMapEnd(); } @@ -555,9 +555,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROPS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.props.size())); - for (Map.Entry _iter38 : this.props.entrySet()) { - oprot.writeBinary(_iter38.getKey()); - _iter38.getValue().write(oprot); + for (Map.Entry _iter50 : this.props.entrySet()) { + oprot.writeBinary(_iter50.getKey()); + _iter50.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java index b8ccc0b8f..c31b591bd 100644 --- a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java +++ b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java @@ -128,6 +128,11 @@ public enum ErrorCode implements com.facebook.thrift.TEnum { E_USER_CANCEL(-3052), E_TASK_EXECUTION_FAILED(-3053), E_PLAN_IS_KILLED(-3060), + E_NO_TERM(-3070), + E_OUTDATED_TERM(-3071), + E_OUTDATED_EDGE(-3072), + E_WRITE_WRITE_CONFLICT(-3073), + E_CLIENT_SERVER_INCOMPATIBLE(-3061), E_UNKNOWN(-8000); private static final Map INDEXED_VALUES = new HashMap(); diff --git a/client/src/main/generated/com/vesoft/nebula/Geography.java b/client/src/main/generated/com/vesoft/nebula/Geography.java new file mode 100644 index 000000000..d1a9c550f --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Geography.java @@ -0,0 +1,281 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial", "unchecked" }) +public class Geography extends TUnion implements Comparable { + private static final TStruct STRUCT_DESC = new TStruct("Geography"); + private static final TField PT_VAL_FIELD_DESC = new TField("ptVal", TType.STRUCT, (short)1); + private static final TField LS_VAL_FIELD_DESC = new TField("lsVal", TType.STRUCT, (short)2); + private static final TField PG_VAL_FIELD_DESC = new TField("pgVal", TType.STRUCT, (short)3); + + public static final int PTVAL = 1; + public static final int LSVAL = 2; + public static final int PGVAL = 3; + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(PTVAL, new FieldMetaData("ptVal", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, Point.class))); + tmpMetaDataMap.put(LSVAL, new FieldMetaData("lsVal", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, LineString.class))); + tmpMetaDataMap.put(PGVAL, new FieldMetaData("pgVal", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, Polygon.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + public Geography() { + super(); + } + + public Geography(int setField, Object __value) { + super(setField, __value); + } + + public Geography(Geography other) { + super(other); + } + + public Geography deepCopy() { + return new Geography(this); + } + + public static Geography ptVal(Point __value) { + Geography x = new Geography(); + x.setPtVal(__value); + return x; + } + + public static Geography lsVal(LineString __value) { + Geography x = new Geography(); + x.setLsVal(__value); + return x; + } + + public static Geography pgVal(Polygon __value) { + Geography x = new Geography(); + x.setPgVal(__value); + return x; + } + + + @Override + protected void checkType(short setField, Object __value) throws ClassCastException { + switch (setField) { + case PTVAL: + if (__value instanceof Point) { + break; + } + throw new ClassCastException("Was expecting value of type Point for field 'ptVal', but got " + __value.getClass().getSimpleName()); + case LSVAL: + if (__value instanceof LineString) { + break; + } + throw new ClassCastException("Was expecting value of type LineString for field 'lsVal', but got " + __value.getClass().getSimpleName()); + case PGVAL: + if (__value instanceof Polygon) { + break; + } + throw new ClassCastException("Was expecting value of type Polygon for field 'pgVal', but got " + __value.getClass().getSimpleName()); + default: + throw new IllegalArgumentException("Unknown field id " + setField); + } + } + + @Override + public void read(TProtocol iprot) throws TException { + setField_ = 0; + value_ = null; + iprot.readStructBegin(metaDataMap); + TField __field = iprot.readFieldBegin(); + if (__field.type != TType.STOP) + { + value_ = readValue(iprot, __field); + if (value_ != null) + { + switch (__field.id) { + case PTVAL: + if (__field.type == PT_VAL_FIELD_DESC.type) { + setField_ = __field.id; + } + break; + case LSVAL: + if (__field.type == LS_VAL_FIELD_DESC.type) { + setField_ = __field.id; + } + break; + case PGVAL: + if (__field.type == PG_VAL_FIELD_DESC.type) { + setField_ = __field.id; + } + break; + } + } + iprot.readFieldEnd(); + TField __stopField = iprot.readFieldBegin(); + if (__stopField.type != TType.STOP) { + throw new TProtocolException(TProtocolException.INVALID_DATA, "Union 'Geography' is missing a STOP byte"); + } + } + iprot.readStructEnd(); + } + + @Override + protected Object readValue(TProtocol iprot, TField __field) throws TException { + switch (__field.id) { + case PTVAL: + if (__field.type == PT_VAL_FIELD_DESC.type) { + Point ptVal; + ptVal = new Point(); + ptVal.read(iprot); + return ptVal; + } + break; + case LSVAL: + if (__field.type == LS_VAL_FIELD_DESC.type) { + LineString lsVal; + lsVal = new LineString(); + lsVal.read(iprot); + return lsVal; + } + break; + case PGVAL: + if (__field.type == PG_VAL_FIELD_DESC.type) { + Polygon pgVal; + pgVal = new Polygon(); + pgVal.read(iprot); + return pgVal; + } + break; + } + TProtocolUtil.skip(iprot, __field.type); + return null; + } + + @Override + protected void writeValue(TProtocol oprot, short setField, Object __value) throws TException { + switch (setField) { + case PTVAL: + Point ptVal = (Point)getFieldValue(); + ptVal.write(oprot); + return; + case LSVAL: + LineString lsVal = (LineString)getFieldValue(); + lsVal.write(oprot); + return; + case PGVAL: + Polygon pgVal = (Polygon)getFieldValue(); + pgVal.write(oprot); + return; + default: + throw new IllegalStateException("Cannot write union with unknown field " + setField); + } + } + + @Override + protected TField getFieldDesc(int setField) { + switch (setField) { + case PTVAL: + return PT_VAL_FIELD_DESC; + case LSVAL: + return LS_VAL_FIELD_DESC; + case PGVAL: + return PG_VAL_FIELD_DESC; + default: + throw new IllegalArgumentException("Unknown field id " + setField); + } + } + + @Override + protected TStruct getStructDesc() { + return STRUCT_DESC; + } + + @Override + protected Map getMetaDataMap() { return metaDataMap; } + + private Object __getValue(int expectedFieldId) { + if (getSetField() == expectedFieldId) { + return getFieldValue(); + } else { + throw new RuntimeException("Cannot get field '" + getFieldDesc(expectedFieldId).name + "' because union is currently set to " + getFieldDesc(getSetField()).name); + } + } + + private void __setValue(int fieldId, Object __value) { + if (__value == null) throw new NullPointerException(); + setField_ = fieldId; + value_ = __value; + } + + public Point getPtVal() { + return (Point) __getValue(PTVAL); + } + + public void setPtVal(Point __value) { + __setValue(PTVAL, __value); + } + + public LineString getLsVal() { + return (LineString) __getValue(LSVAL); + } + + public void setLsVal(LineString __value) { + __setValue(LSVAL, __value); + } + + public Polygon getPgVal() { + return (Polygon) __getValue(PGVAL); + } + + public void setPgVal(Polygon __value) { + __setValue(PGVAL, __value); + } + + public boolean equals(Object other) { + if (other instanceof Geography) { + return equals((Geography)other); + } else { + return false; + } + } + + public boolean equals(Geography other) { + return equalsNobinaryImpl(other); + } + + @Override + public int compareTo(Geography other) { + return compareToImpl(other); + } + + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {getSetField(), getFieldValue()}); + } + +} diff --git a/client/src/main/generated/com/vesoft/nebula/LineString.java b/client/src/main/generated/com/vesoft/nebula/LineString.java new file mode 100644 index 000000000..91c7599bf --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/LineString.java @@ -0,0 +1,286 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class LineString implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("LineString"); + private static final TField COORD_LIST_FIELD_DESC = new TField("coordList", TType.LIST, (short)1); + + public List coordList; + public static final int COORDLIST = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(COORDLIST, new FieldMetaData("coordList", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Coordinate.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(LineString.class, metaDataMap); + } + + public LineString() { + } + + public LineString( + List coordList) { + this(); + this.coordList = coordList; + } + + public static class Builder { + private List coordList; + + public Builder() { + } + + public Builder setCoordList(final List coordList) { + this.coordList = coordList; + return this; + } + + public LineString build() { + LineString result = new LineString(); + result.setCoordList(this.coordList); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public LineString(LineString other) { + if (other.isSetCoordList()) { + this.coordList = TBaseHelper.deepCopy(other.coordList); + } + } + + public LineString deepCopy() { + return new LineString(this); + } + + public List getCoordList() { + return this.coordList; + } + + public LineString setCoordList(List coordList) { + this.coordList = coordList; + return this; + } + + public void unsetCoordList() { + this.coordList = null; + } + + // Returns true if field coordList is set (has been assigned a value) and false otherwise + public boolean isSetCoordList() { + return this.coordList != null; + } + + public void setCoordListIsSet(boolean __value) { + if (!__value) { + this.coordList = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case COORDLIST: + if (__value == null) { + unsetCoordList(); + } else { + setCoordList((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case COORDLIST: + return getCoordList(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof LineString)) + return false; + LineString that = (LineString)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCoordList(), that.isSetCoordList(), this.coordList, that.coordList)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {coordList}); + } + + @Override + public int compareTo(LineString other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCoordList()).compareTo(other.isSetCoordList()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(coordList, other.coordList); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case COORDLIST: + if (__field.type == TType.LIST) { + { + TList _list25 = iprot.readListBegin(); + this.coordList = new ArrayList(Math.max(0, _list25.size)); + for (int _i26 = 0; + (_list25.size < 0) ? iprot.peekList() : (_i26 < _list25.size); + ++_i26) + { + Coordinate _elem27; + _elem27 = new Coordinate(); + _elem27.read(iprot); + this.coordList.add(_elem27); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.coordList != null) { + oprot.writeFieldBegin(COORD_LIST_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.coordList.size())); + for (Coordinate _iter28 : this.coordList) { + _iter28.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("LineString"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("coordList"); + sb.append(space); + sb.append(":").append(space); + if (this.getCoordList() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCoordList(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java b/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java index 1d7c08a37..917e3d168 100644 --- a/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java @@ -199,18 +199,18 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.MAP) { { - TMap _map52 = iprot.readMapBegin(); - this.info = new HashMap(Math.max(0, 2*_map52.size)); - for (int _i53 = 0; - (_map52.size < 0) ? iprot.peekMap() : (_i53 < _map52.size); - ++_i53) + TMap _map64 = iprot.readMapBegin(); + this.info = new HashMap(Math.max(0, 2*_map64.size)); + for (int _i65 = 0; + (_map64.size < 0) ? iprot.peekMap() : (_i65 < _map64.size); + ++_i65) { - int _key54; - LogInfo _val55; - _key54 = iprot.readI32(); - _val55 = new LogInfo(); - _val55.read(iprot); - this.info.put(_key54, _val55); + int _key66; + LogInfo _val67; + _key66 = iprot.readI32(); + _val67 = new LogInfo(); + _val67.read(iprot); + this.info.put(_key66, _val67); } iprot.readMapEnd(); } @@ -239,9 +239,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.info.size())); - for (Map.Entry _iter56 : this.info.entrySet()) { - oprot.writeI32(_iter56.getKey()); - _iter56.getValue().write(oprot); + for (Map.Entry _iter68 : this.info.entrySet()) { + oprot.writeI32(_iter68.getKey()); + _iter68.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/Path.java b/client/src/main/generated/com/vesoft/nebula/Path.java index f3b404d41..d03234536 100644 --- a/client/src/main/generated/com/vesoft/nebula/Path.java +++ b/client/src/main/generated/com/vesoft/nebula/Path.java @@ -237,16 +237,16 @@ public void read(TProtocol iprot) throws TException { case STEPS: if (__field.type == TType.LIST) { { - TList _list44 = iprot.readListBegin(); - this.steps = new ArrayList(Math.max(0, _list44.size)); - for (int _i45 = 0; - (_list44.size < 0) ? iprot.peekList() : (_i45 < _list44.size); - ++_i45) + TList _list56 = iprot.readListBegin(); + this.steps = new ArrayList(Math.max(0, _list56.size)); + for (int _i57 = 0; + (_list56.size < 0) ? iprot.peekList() : (_i57 < _list56.size); + ++_i57) { - Step _elem46; - _elem46 = new Step(); - _elem46.read(iprot); - this.steps.add(_elem46); + Step _elem58; + _elem58 = new Step(); + _elem58.read(iprot); + this.steps.add(_elem58); } iprot.readListEnd(); } @@ -280,8 +280,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STEPS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.steps.size())); - for (Step _iter47 : this.steps) { - _iter47.write(oprot); + for (Step _iter59 : this.steps) { + _iter59.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/Point.java b/client/src/main/generated/com/vesoft/nebula/Point.java new file mode 100644 index 000000000..943352d07 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Point.java @@ -0,0 +1,266 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class Point implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("Point"); + private static final TField COORD_FIELD_DESC = new TField("coord", TType.STRUCT, (short)1); + + public Coordinate coord; + public static final int COORD = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(COORD, new FieldMetaData("coord", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, Coordinate.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(Point.class, metaDataMap); + } + + public Point() { + } + + public Point( + Coordinate coord) { + this(); + this.coord = coord; + } + + public static class Builder { + private Coordinate coord; + + public Builder() { + } + + public Builder setCoord(final Coordinate coord) { + this.coord = coord; + return this; + } + + public Point build() { + Point result = new Point(); + result.setCoord(this.coord); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public Point(Point other) { + if (other.isSetCoord()) { + this.coord = TBaseHelper.deepCopy(other.coord); + } + } + + public Point deepCopy() { + return new Point(this); + } + + public Coordinate getCoord() { + return this.coord; + } + + public Point setCoord(Coordinate coord) { + this.coord = coord; + return this; + } + + public void unsetCoord() { + this.coord = null; + } + + // Returns true if field coord is set (has been assigned a value) and false otherwise + public boolean isSetCoord() { + return this.coord != null; + } + + public void setCoordIsSet(boolean __value) { + if (!__value) { + this.coord = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case COORD: + if (__value == null) { + unsetCoord(); + } else { + setCoord((Coordinate)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case COORD: + return getCoord(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof Point)) + return false; + Point that = (Point)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCoord(), that.isSetCoord(), this.coord, that.coord)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {coord}); + } + + @Override + public int compareTo(Point other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCoord()).compareTo(other.isSetCoord()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(coord, other.coord); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case COORD: + if (__field.type == TType.STRUCT) { + this.coord = new Coordinate(); + this.coord.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.coord != null) { + oprot.writeFieldBegin(COORD_FIELD_DESC); + this.coord.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("Point"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("coord"); + sb.append(space); + sb.append(":").append(space); + if (this.getCoord() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCoord(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/Polygon.java b/client/src/main/generated/com/vesoft/nebula/Polygon.java new file mode 100644 index 000000000..9894aab00 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Polygon.java @@ -0,0 +1,305 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class Polygon implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("Polygon"); + private static final TField COORD_LIST_LIST_FIELD_DESC = new TField("coordListList", TType.LIST, (short)1); + + public List> coordListList; + public static final int COORDLISTLIST = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(COORDLISTLIST, new FieldMetaData("coordListList", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Coordinate.class))))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(Polygon.class, metaDataMap); + } + + public Polygon() { + } + + public Polygon( + List> coordListList) { + this(); + this.coordListList = coordListList; + } + + public static class Builder { + private List> coordListList; + + public Builder() { + } + + public Builder setCoordListList(final List> coordListList) { + this.coordListList = coordListList; + return this; + } + + public Polygon build() { + Polygon result = new Polygon(); + result.setCoordListList(this.coordListList); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public Polygon(Polygon other) { + if (other.isSetCoordListList()) { + this.coordListList = TBaseHelper.deepCopy(other.coordListList); + } + } + + public Polygon deepCopy() { + return new Polygon(this); + } + + public List> getCoordListList() { + return this.coordListList; + } + + public Polygon setCoordListList(List> coordListList) { + this.coordListList = coordListList; + return this; + } + + public void unsetCoordListList() { + this.coordListList = null; + } + + // Returns true if field coordListList is set (has been assigned a value) and false otherwise + public boolean isSetCoordListList() { + return this.coordListList != null; + } + + public void setCoordListListIsSet(boolean __value) { + if (!__value) { + this.coordListList = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case COORDLISTLIST: + if (__value == null) { + unsetCoordListList(); + } else { + setCoordListList((List>)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case COORDLISTLIST: + return getCoordListList(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof Polygon)) + return false; + Polygon that = (Polygon)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCoordListList(), that.isSetCoordListList(), this.coordListList, that.coordListList)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {coordListList}); + } + + @Override + public int compareTo(Polygon other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCoordListList()).compareTo(other.isSetCoordListList()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(coordListList, other.coordListList); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case COORDLISTLIST: + if (__field.type == TType.LIST) { + { + TList _list29 = iprot.readListBegin(); + this.coordListList = new ArrayList>(Math.max(0, _list29.size)); + for (int _i30 = 0; + (_list29.size < 0) ? iprot.peekList() : (_i30 < _list29.size); + ++_i30) + { + List _elem31; + { + TList _list32 = iprot.readListBegin(); + _elem31 = new ArrayList(Math.max(0, _list32.size)); + for (int _i33 = 0; + (_list32.size < 0) ? iprot.peekList() : (_i33 < _list32.size); + ++_i33) + { + Coordinate _elem34; + _elem34 = new Coordinate(); + _elem34.read(iprot); + _elem31.add(_elem34); + } + iprot.readListEnd(); + } + this.coordListList.add(_elem31); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.coordListList != null) { + oprot.writeFieldBegin(COORD_LIST_LIST_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.LIST, this.coordListList.size())); + for (List _iter35 : this.coordListList) { + { + oprot.writeListBegin(new TList(TType.STRUCT, _iter35.size())); + for (Coordinate _iter36 : _iter35) { + _iter36.write(oprot); + } + oprot.writeListEnd(); + } + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("Polygon"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("coordListList"); + sb.append(space); + sb.append(":").append(space); + if (this.getCoordListList() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCoordListList(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/Step.java b/client/src/main/generated/com/vesoft/nebula/Step.java index f657a49a1..b2c1c0588 100644 --- a/client/src/main/generated/com/vesoft/nebula/Step.java +++ b/client/src/main/generated/com/vesoft/nebula/Step.java @@ -432,18 +432,18 @@ public void read(TProtocol iprot) throws TException { case PROPS: if (__field.type == TType.MAP) { { - TMap _map39 = iprot.readMapBegin(); - this.props = new HashMap(Math.max(0, 2*_map39.size)); - for (int _i40 = 0; - (_map39.size < 0) ? iprot.peekMap() : (_i40 < _map39.size); - ++_i40) + TMap _map51 = iprot.readMapBegin(); + this.props = new HashMap(Math.max(0, 2*_map51.size)); + for (int _i52 = 0; + (_map51.size < 0) ? iprot.peekMap() : (_i52 < _map51.size); + ++_i52) { - byte[] _key41; - Value _val42; - _key41 = iprot.readBinary(); - _val42 = new Value(); - _val42.read(iprot); - this.props.put(_key41, _val42); + byte[] _key53; + Value _val54; + _key53 = iprot.readBinary(); + _val54 = new Value(); + _val54.read(iprot); + this.props.put(_key53, _val54); } iprot.readMapEnd(); } @@ -488,9 +488,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROPS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.props.size())); - for (Map.Entry _iter43 : this.props.entrySet()) { - oprot.writeBinary(_iter43.getKey()); - _iter43.getValue().write(oprot); + for (Map.Entry _iter55 : this.props.entrySet()) { + oprot.writeBinary(_iter55.getKey()); + _iter55.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/Tag.java b/client/src/main/generated/com/vesoft/nebula/Tag.java index 11164e1fa..6b548622a 100644 --- a/client/src/main/generated/com/vesoft/nebula/Tag.java +++ b/client/src/main/generated/com/vesoft/nebula/Tag.java @@ -237,18 +237,18 @@ public void read(TProtocol iprot) throws TException { case PROPS: if (__field.type == TType.MAP) { { - TMap _map25 = iprot.readMapBegin(); - this.props = new HashMap(Math.max(0, 2*_map25.size)); - for (int _i26 = 0; - (_map25.size < 0) ? iprot.peekMap() : (_i26 < _map25.size); - ++_i26) + TMap _map37 = iprot.readMapBegin(); + this.props = new HashMap(Math.max(0, 2*_map37.size)); + for (int _i38 = 0; + (_map37.size < 0) ? iprot.peekMap() : (_i38 < _map37.size); + ++_i38) { - byte[] _key27; - Value _val28; - _key27 = iprot.readBinary(); - _val28 = new Value(); - _val28.read(iprot); - this.props.put(_key27, _val28); + byte[] _key39; + Value _val40; + _key39 = iprot.readBinary(); + _val40 = new Value(); + _val40.read(iprot); + this.props.put(_key39, _val40); } iprot.readMapEnd(); } @@ -282,9 +282,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROPS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.props.size())); - for (Map.Entry _iter29 : this.props.entrySet()) { - oprot.writeBinary(_iter29.getKey()); - _iter29.getValue().write(oprot); + for (Map.Entry _iter41 : this.props.entrySet()) { + oprot.writeBinary(_iter41.getKey()); + _iter41.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/Value.java b/client/src/main/generated/com/vesoft/nebula/Value.java index 36d4ea691..628946385 100644 --- a/client/src/main/generated/com/vesoft/nebula/Value.java +++ b/client/src/main/generated/com/vesoft/nebula/Value.java @@ -41,6 +41,7 @@ public class Value extends TUnion { private static final TField M_VAL_FIELD_DESC = new TField("mVal", TType.STRUCT, (short)13); private static final TField U_VAL_FIELD_DESC = new TField("uVal", TType.STRUCT, (short)14); private static final TField G_VAL_FIELD_DESC = new TField("gVal", TType.STRUCT, (short)15); + private static final TField GG_VAL_FIELD_DESC = new TField("ggVal", TType.STRUCT, (short)16); public static final int NVAL = 1; public static final int BVAL = 2; @@ -57,6 +58,7 @@ public class Value extends TUnion { public static final int MVAL = 13; public static final int UVAL = 14; public static final int GVAL = 15; + public static final int GGVAL = 16; public static final Map metaDataMap; @@ -92,6 +94,8 @@ public class Value extends TUnion { new StructMetaData(TType.STRUCT, NSet.class))); tmpMetaDataMap.put(GVAL, new FieldMetaData("gVal", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, DataSet.class))); + tmpMetaDataMap.put(GGVAL, new FieldMetaData("ggVal", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, Geography.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -201,6 +205,12 @@ public static Value gVal(DataSet __value) { return x; } + public static Value ggVal(Geography __value) { + Value x = new Value(); + x.setGgVal(__value); + return x; + } + @Override protected void checkType(short setField, Object __value) throws ClassCastException { @@ -280,6 +290,11 @@ protected void checkType(short setField, Object __value) throws ClassCastExcepti break; } throw new ClassCastException("Was expecting value of type DataSet for field 'gVal', but got " + __value.getClass().getSimpleName()); + case GGVAL: + if (__value instanceof Geography) { + break; + } + throw new ClassCastException("Was expecting value of type Geography for field 'ggVal', but got " + __value.getClass().getSimpleName()); default: throw new IllegalArgumentException("Unknown field id " + setField); } @@ -372,6 +387,11 @@ public void read(TProtocol iprot) throws TException { setField_ = __field.id; } break; + case GGVAL: + if (__field.type == GG_VAL_FIELD_DESC.type) { + setField_ = __field.id; + } + break; } } iprot.readFieldEnd(); @@ -501,6 +521,14 @@ protected Object readValue(TProtocol iprot, TField __field) throws TException { return gVal; } break; + case GGVAL: + if (__field.type == GG_VAL_FIELD_DESC.type) { + Geography ggVal; + ggVal = new Geography(); + ggVal.read(iprot); + return ggVal; + } + break; } TProtocolUtil.skip(iprot, __field.type); return null; @@ -569,6 +597,10 @@ protected void writeValue(TProtocol oprot, short setField, Object __value) throw DataSet gVal = (DataSet)getFieldValue(); gVal.write(oprot); return; + case GGVAL: + Geography ggVal = (Geography)getFieldValue(); + ggVal.write(oprot); + return; default: throw new IllegalStateException("Cannot write union with unknown field " + setField); } @@ -607,6 +639,8 @@ protected TField getFieldDesc(int setField) { return U_VAL_FIELD_DESC; case GVAL: return G_VAL_FIELD_DESC; + case GGVAL: + return GG_VAL_FIELD_DESC; default: throw new IllegalArgumentException("Unknown field id " + setField); } @@ -765,6 +799,14 @@ public void setGVal(DataSet __value) { __setValue(GVAL, __value); } + public Geography getGgVal() { + return (Geography) __getValue(GGVAL); + } + + public void setGgVal(Geography __value) { + __setValue(GGVAL, __value); + } + public boolean equals(Object other) { if (other instanceof Value) { return equals((Value)other); diff --git a/client/src/main/generated/com/vesoft/nebula/Vertex.java b/client/src/main/generated/com/vesoft/nebula/Vertex.java index 1dfffe876..ed3d7c581 100644 --- a/client/src/main/generated/com/vesoft/nebula/Vertex.java +++ b/client/src/main/generated/com/vesoft/nebula/Vertex.java @@ -237,16 +237,16 @@ public void read(TProtocol iprot) throws TException { case TAGS: if (__field.type == TType.LIST) { { - TList _list30 = iprot.readListBegin(); - this.tags = new ArrayList(Math.max(0, _list30.size)); - for (int _i31 = 0; - (_list30.size < 0) ? iprot.peekList() : (_i31 < _list30.size); - ++_i31) + TList _list42 = iprot.readListBegin(); + this.tags = new ArrayList(Math.max(0, _list42.size)); + for (int _i43 = 0; + (_list42.size < 0) ? iprot.peekList() : (_i43 < _list42.size); + ++_i43) { - Tag _elem32; - _elem32 = new Tag(); - _elem32.read(iprot); - this.tags.add(_elem32); + Tag _elem44; + _elem44 = new Tag(); + _elem44.read(iprot); + this.tags.add(_elem44); } iprot.readListEnd(); } @@ -280,8 +280,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TAGS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.tags.size())); - for (Tag _iter33 : this.tags) { - _iter33.write(oprot); + for (Tag _iter45 : this.tags) { + _iter45.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java b/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java index 9db127bf8..4083c3390 100644 --- a/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java +++ b/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java @@ -39,6 +39,8 @@ public interface Iface { public byte[] executeJson(long sessionId, byte[] stmt) throws TException; + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException; + } public interface AsyncIface { @@ -51,6 +53,8 @@ public interface AsyncIface { public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler) throws TException; + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler) throws TException; + } public static class Client extends EventHandlerBase implements Iface, TClientIf { @@ -241,6 +245,51 @@ public byte[] recv_executeJson() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "executeJson failed: unknown result"); } + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException + { + ContextStack ctx = getContextStack("GraphService.verifyClientVersion", null); + this.setContextStack(ctx); + send_verifyClientVersion(req); + return recv_verifyClientVersion(); + } + + public void send_verifyClientVersion(VerifyClientVersionReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphService.verifyClientVersion", null); + oprot_.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.CALL, seqid_)); + verifyClientVersion_args args = new verifyClientVersion_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphService.verifyClientVersion", args); + return; + } + + public VerifyClientVersionResp recv_verifyClientVersion() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphService.verifyClientVersion"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + verifyClientVersion_result result = new verifyClientVersion_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphService.verifyClientVersion", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "verifyClientVersion failed: unknown result"); + } + } public static class AsyncClient extends TAsyncClient implements AsyncIface { public static class Factory implements TAsyncClientFactory { @@ -259,9 +308,9 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void authenticate(byte[] username, byte[] password, AsyncMethodCallback resultHandler33) throws TException { + public void authenticate(byte[] username, byte[] password, AsyncMethodCallback resultHandler34) throws TException { checkReady(); - authenticate_call method_call = new authenticate_call(username, password, resultHandler33, this, ___protocolFactory, ___transport); + authenticate_call method_call = new authenticate_call(username, password, resultHandler34, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -269,8 +318,8 @@ public void authenticate(byte[] username, byte[] password, AsyncMethodCallback r public static class authenticate_call extends TAsyncMethodCall { private byte[] username; private byte[] password; - public authenticate_call(byte[] username, byte[] password, AsyncMethodCallback resultHandler34, TAsyncClient client30, TProtocolFactory protocolFactory31, TNonblockingTransport transport32) throws TException { - super(client30, protocolFactory31, transport32, resultHandler34, false); + public authenticate_call(byte[] username, byte[] password, AsyncMethodCallback resultHandler35, TAsyncClient client31, TProtocolFactory protocolFactory32, TNonblockingTransport transport33) throws TException { + super(client31, protocolFactory32, transport33, resultHandler35, false); this.username = username; this.password = password; } @@ -294,17 +343,17 @@ public AuthResponse getResult() throws TException { } } - public void signout(long sessionId, AsyncMethodCallback resultHandler38) throws TException { + public void signout(long sessionId, AsyncMethodCallback resultHandler39) throws TException { checkReady(); - signout_call method_call = new signout_call(sessionId, resultHandler38, this, ___protocolFactory, ___transport); + signout_call method_call = new signout_call(sessionId, resultHandler39, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signout_call extends TAsyncMethodCall { private long sessionId; - public signout_call(long sessionId, AsyncMethodCallback resultHandler39, TAsyncClient client35, TProtocolFactory protocolFactory36, TNonblockingTransport transport37) throws TException { - super(client35, protocolFactory36, transport37, resultHandler39, true); + public signout_call(long sessionId, AsyncMethodCallback resultHandler40, TAsyncClient client36, TProtocolFactory protocolFactory37, TNonblockingTransport transport38) throws TException { + super(client36, protocolFactory37, transport38, resultHandler40, true); this.sessionId = sessionId; } @@ -325,9 +374,9 @@ public void getResult() throws TException { } } - public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler43) throws TException { + public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler44) throws TException { checkReady(); - execute_call method_call = new execute_call(sessionId, stmt, resultHandler43, this, ___protocolFactory, ___transport); + execute_call method_call = new execute_call(sessionId, stmt, resultHandler44, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -335,8 +384,8 @@ public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandl public static class execute_call extends TAsyncMethodCall { private long sessionId; private byte[] stmt; - public execute_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler44, TAsyncClient client40, TProtocolFactory protocolFactory41, TNonblockingTransport transport42) throws TException { - super(client40, protocolFactory41, transport42, resultHandler44, false); + public execute_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler45, TAsyncClient client41, TProtocolFactory protocolFactory42, TNonblockingTransport transport43) throws TException { + super(client41, protocolFactory42, transport43, resultHandler45, false); this.sessionId = sessionId; this.stmt = stmt; } @@ -360,9 +409,9 @@ public ExecutionResponse getResult() throws TException { } } - public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler48) throws TException { + public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler49) throws TException { checkReady(); - executeJson_call method_call = new executeJson_call(sessionId, stmt, resultHandler48, this, ___protocolFactory, ___transport); + executeJson_call method_call = new executeJson_call(sessionId, stmt, resultHandler49, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -370,8 +419,8 @@ public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultH public static class executeJson_call extends TAsyncMethodCall { private long sessionId; private byte[] stmt; - public executeJson_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler49, TAsyncClient client45, TProtocolFactory protocolFactory46, TNonblockingTransport transport47) throws TException { - super(client45, protocolFactory46, transport47, resultHandler49, false); + public executeJson_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler50, TAsyncClient client46, TProtocolFactory protocolFactory47, TNonblockingTransport transport48) throws TException { + super(client46, protocolFactory47, transport48, resultHandler50, false); this.sessionId = sessionId; this.stmt = stmt; } @@ -395,6 +444,38 @@ public byte[] getResult() throws TException { } } + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler54) throws TException { + checkReady(); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler54, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class verifyClientVersion_call extends TAsyncMethodCall { + private VerifyClientVersionReq req; + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler55, TAsyncClient client51, TProtocolFactory protocolFactory52, TNonblockingTransport transport53) throws TException { + super(client51, protocolFactory52, transport53, resultHandler55, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.CALL, 0)); + verifyClientVersion_args args = new verifyClientVersion_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public VerifyClientVersionResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_verifyClientVersion(); + } + } + } public static class Processor implements TProcessor { @@ -407,6 +488,7 @@ public Processor(Iface iface) processMap_.put("signout", new signout()); processMap_.put("execute", new execute()); processMap_.put("executeJson", new executeJson()); + processMap_.put("verifyClientVersion", new verifyClientVersion()); } protected static interface ProcessFunction { @@ -516,6 +598,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class verifyClientVersion implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphService.verifyClientVersion", server_ctx); + verifyClientVersion_args args = new verifyClientVersion_args(); + event_handler_.preRead(handler_ctx, "GraphService.verifyClientVersion"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphService.verifyClientVersion", args); + verifyClientVersion_result result = new verifyClientVersion_result(); + result.success = iface_.verifyClientVersion(args.req); + event_handler_.preWrite(handler_ctx, "GraphService.verifyClientVersion", result); + oprot.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphService.verifyClientVersion", result); + } + + } + } public static class authenticate_args implements TBase, java.io.Serializable, Cloneable, Comparable { @@ -2263,4 +2366,439 @@ public void validate() throws TException { } + public static class verifyClientVersion_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("verifyClientVersion_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public VerifyClientVersionReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, VerifyClientVersionReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(verifyClientVersion_args.class, metaDataMap); + } + + public verifyClientVersion_args() { + } + + public verifyClientVersion_args( + VerifyClientVersionReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public verifyClientVersion_args(verifyClientVersion_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public verifyClientVersion_args deepCopy() { + return new verifyClientVersion_args(this); + } + + public VerifyClientVersionReq getReq() { + return this.req; + } + + public verifyClientVersion_args setReq(VerifyClientVersionReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((VerifyClientVersionReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof verifyClientVersion_args)) + return false; + verifyClientVersion_args that = (verifyClientVersion_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(verifyClientVersion_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new VerifyClientVersionReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("verifyClientVersion_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class verifyClientVersion_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("verifyClientVersion_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public VerifyClientVersionResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, VerifyClientVersionResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(verifyClientVersion_result.class, metaDataMap); + } + + public verifyClientVersion_result() { + } + + public verifyClientVersion_result( + VerifyClientVersionResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public verifyClientVersion_result(verifyClientVersion_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public verifyClientVersion_result deepCopy() { + return new verifyClientVersion_result(this); + } + + public VerifyClientVersionResp getSuccess() { + return this.success; + } + + public verifyClientVersion_result setSuccess(VerifyClientVersionResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((VerifyClientVersionResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof verifyClientVersion_result)) + return false; + verifyClientVersion_result that = (verifyClientVersion_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(verifyClientVersion_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new VerifyClientVersionResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("verifyClientVersion_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + } diff --git a/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionReq.java b/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionReq.java new file mode 100644 index 000000000..077897126 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionReq.java @@ -0,0 +1,275 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class VerifyClientVersionReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionReq"); + private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)1); + + public byte[] version; + public static final int VERSION = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.REQUIRED, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(VerifyClientVersionReq.class, metaDataMap); + } + + public VerifyClientVersionReq() { + this.version = "2.6.0".getBytes(); + + } + + public VerifyClientVersionReq( + byte[] version) { + this(); + this.version = version; + } + + public static class Builder { + private byte[] version; + + public Builder() { + } + + public Builder setVersion(final byte[] version) { + this.version = version; + return this; + } + + public VerifyClientVersionReq build() { + VerifyClientVersionReq result = new VerifyClientVersionReq(); + result.setVersion(this.version); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public VerifyClientVersionReq(VerifyClientVersionReq other) { + if (other.isSetVersion()) { + this.version = TBaseHelper.deepCopy(other.version); + } + } + + public VerifyClientVersionReq deepCopy() { + return new VerifyClientVersionReq(this); + } + + public byte[] getVersion() { + return this.version; + } + + public VerifyClientVersionReq setVersion(byte[] version) { + this.version = version; + return this; + } + + public void unsetVersion() { + this.version = null; + } + + // Returns true if field version is set (has been assigned a value) and false otherwise + public boolean isSetVersion() { + return this.version != null; + } + + public void setVersionIsSet(boolean __value) { + if (!__value) { + this.version = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case VERSION: + if (__value == null) { + unsetVersion(); + } else { + setVersion((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case VERSION: + return getVersion(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof VerifyClientVersionReq)) + return false; + VerifyClientVersionReq that = (VerifyClientVersionReq)_that; + + if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {version}); + } + + @Override + public int compareTo(VerifyClientVersionReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(version, other.version); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case VERSION: + if (__field.type == TType.STRING) { + this.version = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.version != null) { + oprot.writeFieldBegin(VERSION_FIELD_DESC); + oprot.writeBinary(this.version); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("VerifyClientVersionReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("version"); + sb.append(space); + sb.append(":").append(space); + if (this.getVersion() == null) { + sb.append("null"); + } else { + int __version_size = Math.min(this.getVersion().length, 128); + for (int i = 0; i < __version_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); + } + if (this.getVersion().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (version == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'version' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionResp.java b/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionResp.java new file mode 100644 index 000000000..ae4c21a62 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/VerifyClientVersionResp.java @@ -0,0 +1,389 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class VerifyClientVersionResp implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionResp"); + private static final TField ERROR_CODE_FIELD_DESC = new TField("error_code", TType.I32, (short)1); + private static final TField ERROR_MSG_FIELD_DESC = new TField("error_msg", TType.STRING, (short)2); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode error_code; + public byte[] error_msg; + public static final int ERROR_CODE = 1; + public static final int ERROR_MSG = 2; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(ERROR_CODE, new FieldMetaData("error_code", TFieldRequirementType.REQUIRED, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(ERROR_MSG, new FieldMetaData("error_msg", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(VerifyClientVersionResp.class, metaDataMap); + } + + public VerifyClientVersionResp() { + } + + public VerifyClientVersionResp( + com.vesoft.nebula.ErrorCode error_code) { + this(); + this.error_code = error_code; + } + + public VerifyClientVersionResp( + com.vesoft.nebula.ErrorCode error_code, + byte[] error_msg) { + this(); + this.error_code = error_code; + this.error_msg = error_msg; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode error_code; + private byte[] error_msg; + + public Builder() { + } + + public Builder setError_code(final com.vesoft.nebula.ErrorCode error_code) { + this.error_code = error_code; + return this; + } + + public Builder setError_msg(final byte[] error_msg) { + this.error_msg = error_msg; + return this; + } + + public VerifyClientVersionResp build() { + VerifyClientVersionResp result = new VerifyClientVersionResp(); + result.setError_code(this.error_code); + result.setError_msg(this.error_msg); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public VerifyClientVersionResp(VerifyClientVersionResp other) { + if (other.isSetError_code()) { + this.error_code = TBaseHelper.deepCopy(other.error_code); + } + if (other.isSetError_msg()) { + this.error_msg = TBaseHelper.deepCopy(other.error_msg); + } + } + + public VerifyClientVersionResp deepCopy() { + return new VerifyClientVersionResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getError_code() { + return this.error_code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public VerifyClientVersionResp setError_code(com.vesoft.nebula.ErrorCode error_code) { + this.error_code = error_code; + return this; + } + + public void unsetError_code() { + this.error_code = null; + } + + // Returns true if field error_code is set (has been assigned a value) and false otherwise + public boolean isSetError_code() { + return this.error_code != null; + } + + public void setError_codeIsSet(boolean __value) { + if (!__value) { + this.error_code = null; + } + } + + public byte[] getError_msg() { + return this.error_msg; + } + + public VerifyClientVersionResp setError_msg(byte[] error_msg) { + this.error_msg = error_msg; + return this; + } + + public void unsetError_msg() { + this.error_msg = null; + } + + // Returns true if field error_msg is set (has been assigned a value) and false otherwise + public boolean isSetError_msg() { + return this.error_msg != null; + } + + public void setError_msgIsSet(boolean __value) { + if (!__value) { + this.error_msg = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case ERROR_CODE: + if (__value == null) { + unsetError_code(); + } else { + setError_code((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case ERROR_MSG: + if (__value == null) { + unsetError_msg(); + } else { + setError_msg((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case ERROR_CODE: + return getError_code(); + + case ERROR_MSG: + return getError_msg(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof VerifyClientVersionResp)) + return false; + VerifyClientVersionResp that = (VerifyClientVersionResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetError_code(), that.isSetError_code(), this.error_code, that.error_code)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetError_msg(), that.isSetError_msg(), this.error_msg, that.error_msg)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {error_code, error_msg}); + } + + @Override + public int compareTo(VerifyClientVersionResp other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetError_code()).compareTo(other.isSetError_code()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(error_code, other.error_code); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetError_msg()).compareTo(other.isSetError_msg()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(error_msg, other.error_msg); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case ERROR_CODE: + if (__field.type == TType.I32) { + this.error_code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ERROR_MSG: + if (__field.type == TType.STRING) { + this.error_msg = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.error_code != null) { + oprot.writeFieldBegin(ERROR_CODE_FIELD_DESC); + oprot.writeI32(this.error_code == null ? 0 : this.error_code.getValue()); + oprot.writeFieldEnd(); + } + if (this.error_msg != null) { + if (isSetError_msg()) { + oprot.writeFieldBegin(ERROR_MSG_FIELD_DESC); + oprot.writeBinary(this.error_msg); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("VerifyClientVersionResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("error_code"); + sb.append(space); + sb.append(":").append(space); + if (this.getError_code() == null) { + sb.append("null"); + } else { + String error_code_name = this.getError_code() == null ? "null" : this.getError_code().name(); + if (error_code_name != null) { + sb.append(error_code_name); + sb.append(" ("); + } + sb.append(this.getError_code()); + if (error_code_name != null) { + sb.append(")"); + } + } + first = false; + if (isSetError_msg()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("error_msg"); + sb.append(space); + sb.append(":").append(space); + if (this.getError_msg() == null) { + sb.append("null"); + } else { + int __error_msg_size = Math.min(this.getError_msg().length, 128); + for (int i = 0; i < __error_msg_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getError_msg()[i]).length() > 1 ? Integer.toHexString(this.getError_msg()[i]).substring(Integer.toHexString(this.getError_msg()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getError_msg()[i]).toUpperCase()); + } + if (this.getError_msg().length > 128) sb.append(" ..."); + } + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (error_code == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'error_code' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java b/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java index e8a990f60..48b144908 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java @@ -28,6 +28,7 @@ public class ColumnTypeDef implements TBase, java.io.Serializable, Cloneable, Co private static final TStruct STRUCT_DESC = new TStruct("ColumnTypeDef"); private static final TField TYPE_FIELD_DESC = new TField("type", TType.I32, (short)1); private static final TField TYPE_LENGTH_FIELD_DESC = new TField("type_length", TType.I16, (short)2); + private static final TField GEO_SHAPE_FIELD_DESC = new TField("geo_shape", TType.I32, (short)3); /** * @@ -35,8 +36,14 @@ public class ColumnTypeDef implements TBase, java.io.Serializable, Cloneable, Co */ public PropertyType type; public short type_length; + /** + * + * @see GeoShape + */ + public GeoShape geo_shape; public static final int TYPE = 1; public static final int TYPE_LENGTH = 2; + public static final int GEO_SHAPE = 3; // isset id assignments private static final int __TYPE_LENGTH_ISSET_ID = 0; @@ -50,6 +57,8 @@ public class ColumnTypeDef implements TBase, java.io.Serializable, Cloneable, Co new FieldValueMetaData(TType.I32))); tmpMetaDataMap.put(TYPE_LENGTH, new FieldMetaData("type_length", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.I16))); + tmpMetaDataMap.put(GEO_SHAPE, new FieldMetaData("geo_shape", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I32))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -70,16 +79,19 @@ public ColumnTypeDef( public ColumnTypeDef( PropertyType type, - short type_length) { + short type_length, + GeoShape geo_shape) { this(); this.type = type; this.type_length = type_length; setType_lengthIsSet(true); + this.geo_shape = geo_shape; } public static class Builder { private PropertyType type; private short type_length; + private GeoShape geo_shape; BitSet __optional_isset = new BitSet(1); @@ -97,12 +109,18 @@ public Builder setType_length(final short type_length) { return this; } + public Builder setGeo_shape(final GeoShape geo_shape) { + this.geo_shape = geo_shape; + return this; + } + public ColumnTypeDef build() { ColumnTypeDef result = new ColumnTypeDef(); result.setType(this.type); if (__optional_isset.get(__TYPE_LENGTH_ISSET_ID)) { result.setType_length(this.type_length); } + result.setGeo_shape(this.geo_shape); return result; } } @@ -121,6 +139,9 @@ public ColumnTypeDef(ColumnTypeDef other) { this.type = TBaseHelper.deepCopy(other.type); } this.type_length = TBaseHelper.deepCopy(other.type_length); + if (other.isSetGeo_shape()) { + this.geo_shape = TBaseHelper.deepCopy(other.geo_shape); + } } public ColumnTypeDef deepCopy() { @@ -182,6 +203,38 @@ public void setType_lengthIsSet(boolean __value) { __isset_bit_vector.set(__TYPE_LENGTH_ISSET_ID, __value); } + /** + * + * @see GeoShape + */ + public GeoShape getGeo_shape() { + return this.geo_shape; + } + + /** + * + * @see GeoShape + */ + public ColumnTypeDef setGeo_shape(GeoShape geo_shape) { + this.geo_shape = geo_shape; + return this; + } + + public void unsetGeo_shape() { + this.geo_shape = null; + } + + // Returns true if field geo_shape is set (has been assigned a value) and false otherwise + public boolean isSetGeo_shape() { + return this.geo_shape != null; + } + + public void setGeo_shapeIsSet(boolean __value) { + if (!__value) { + this.geo_shape = null; + } + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case TYPE: @@ -200,6 +253,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case GEO_SHAPE: + if (__value == null) { + unsetGeo_shape(); + } else { + setGeo_shape((GeoShape)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -213,6 +274,9 @@ public Object getFieldValue(int fieldID) { case TYPE_LENGTH: return new Short(getType_length()); + case GEO_SHAPE: + return getGeo_shape(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -232,12 +296,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetType_length(), that.isSetType_length(), this.type_length, that.type_length)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetGeo_shape(), that.isSetGeo_shape(), this.geo_shape, that.geo_shape)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {type, type_length}); + return Arrays.deepHashCode(new Object[] {type, type_length, geo_shape}); } @Override @@ -268,6 +334,14 @@ public int compareTo(ColumnTypeDef other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetGeo_shape()).compareTo(other.isSetGeo_shape()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(geo_shape, other.geo_shape); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -297,6 +371,13 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case GEO_SHAPE: + if (__field.type == TType.I32) { + this.geo_shape = GeoShape.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -324,6 +405,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeI16(this.type_length); oprot.writeFieldEnd(); } + if (this.geo_shape != null) { + if (isSetGeo_shape()) { + oprot.writeFieldBegin(GEO_SHAPE_FIELD_DESC); + oprot.writeI32(this.geo_shape == null ? 0 : this.geo_shape.getValue()); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -372,6 +460,28 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getType_length(), indent + 1, prettyPrint)); first = false; } + if (isSetGeo_shape()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("geo_shape"); + sb.append(space); + sb.append(":").append(space); + if (this.getGeo_shape() == null) { + sb.append("null"); + } else { + String geo_shape_name = this.getGeo_shape() == null ? "null" : this.getGeo_shape().name(); + if (geo_shape_name != null) { + sb.append(geo_shape_name); + sb.append(" ("); + } + sb.append(this.getGeo_shape()); + if (geo_shape_name != null) { + sb.append(")"); + } + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GeoShape.java b/client/src/main/generated/com/vesoft/nebula/meta/GeoShape.java new file mode 100644 index 000000000..6110f3ec0 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/GeoShape.java @@ -0,0 +1,52 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + + +import com.facebook.thrift.IntRangeSet; +import java.util.Map; +import java.util.HashMap; + +@SuppressWarnings({ "unused" }) +public enum GeoShape implements com.facebook.thrift.TEnum { + ANY(0), + POINT(1), + LINESTRING(2), + POLYGON(3); + + private final int value; + + private GeoShape(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static GeoShape findByValue(int value) { + switch (value) { + case 0: + return ANY; + case 1: + return POINT; + case 2: + return LINESTRING; + case 3: + return POLYGON; + default: + return null; + } + } +} diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java index 5f5fa84ac..818acaa9e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java @@ -209,6 +209,8 @@ public interface Iface { public GetMetaDirInfoResp getMetaDirInfo(GetMetaDirInfoReq req) throws TException; + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException; + } public interface AsyncIface { @@ -391,6 +393,8 @@ public interface AsyncIface { public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler) throws TException; + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler) throws TException; + } public static class Client extends EventHandlerBase implements Iface, TClientIf { @@ -4427,6 +4431,51 @@ public GetMetaDirInfoResp recv_getMetaDirInfo() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "getMetaDirInfo failed: unknown result"); } + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.verifyClientVersion", null); + this.setContextStack(ctx); + send_verifyClientVersion(req); + return recv_verifyClientVersion(); + } + + public void send_verifyClientVersion(VerifyClientVersionReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.verifyClientVersion", null); + oprot_.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.CALL, seqid_)); + verifyClientVersion_args args = new verifyClientVersion_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.verifyClientVersion", args); + return; + } + + public VerifyClientVersionResp recv_verifyClientVersion() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.verifyClientVersion"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + verifyClientVersion_result result = new verifyClientVersion_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.verifyClientVersion", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "verifyClientVersion failed: unknown result"); + } + } public static class AsyncClient extends TAsyncClient implements AsyncIface { public static class Factory implements TAsyncClientFactory { @@ -4445,17 +4494,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler425) throws TException { + public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler426) throws TException { checkReady(); - createSpace_call method_call = new createSpace_call(req, resultHandler425, this, ___protocolFactory, ___transport); + createSpace_call method_call = new createSpace_call(req, resultHandler426, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpace_call extends TAsyncMethodCall { private CreateSpaceReq req; - public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler426, TAsyncClient client422, TProtocolFactory protocolFactory423, TNonblockingTransport transport424) throws TException { - super(client422, protocolFactory423, transport424, resultHandler426, false); + public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler427, TAsyncClient client423, TProtocolFactory protocolFactory424, TNonblockingTransport transport425) throws TException { + super(client423, protocolFactory424, transport425, resultHandler427, false); this.req = req; } @@ -4477,17 +4526,17 @@ public ExecResp getResult() throws TException { } } - public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler430) throws TException { + public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler431) throws TException { checkReady(); - dropSpace_call method_call = new dropSpace_call(req, resultHandler430, this, ___protocolFactory, ___transport); + dropSpace_call method_call = new dropSpace_call(req, resultHandler431, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSpace_call extends TAsyncMethodCall { private DropSpaceReq req; - public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler431, TAsyncClient client427, TProtocolFactory protocolFactory428, TNonblockingTransport transport429) throws TException { - super(client427, protocolFactory428, transport429, resultHandler431, false); + public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler432, TAsyncClient client428, TProtocolFactory protocolFactory429, TNonblockingTransport transport430) throws TException { + super(client428, protocolFactory429, transport430, resultHandler432, false); this.req = req; } @@ -4509,17 +4558,17 @@ public ExecResp getResult() throws TException { } } - public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler435) throws TException { + public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler436) throws TException { checkReady(); - getSpace_call method_call = new getSpace_call(req, resultHandler435, this, ___protocolFactory, ___transport); + getSpace_call method_call = new getSpace_call(req, resultHandler436, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSpace_call extends TAsyncMethodCall { private GetSpaceReq req; - public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler436, TAsyncClient client432, TProtocolFactory protocolFactory433, TNonblockingTransport transport434) throws TException { - super(client432, protocolFactory433, transport434, resultHandler436, false); + public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler437, TAsyncClient client433, TProtocolFactory protocolFactory434, TNonblockingTransport transport435) throws TException { + super(client433, protocolFactory434, transport435, resultHandler437, false); this.req = req; } @@ -4541,17 +4590,17 @@ public GetSpaceResp getResult() throws TException { } } - public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler440) throws TException { + public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler441) throws TException { checkReady(); - listSpaces_call method_call = new listSpaces_call(req, resultHandler440, this, ___protocolFactory, ___transport); + listSpaces_call method_call = new listSpaces_call(req, resultHandler441, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSpaces_call extends TAsyncMethodCall { private ListSpacesReq req; - public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler441, TAsyncClient client437, TProtocolFactory protocolFactory438, TNonblockingTransport transport439) throws TException { - super(client437, protocolFactory438, transport439, resultHandler441, false); + public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler442, TAsyncClient client438, TProtocolFactory protocolFactory439, TNonblockingTransport transport440) throws TException { + super(client438, protocolFactory439, transport440, resultHandler442, false); this.req = req; } @@ -4573,17 +4622,17 @@ public ListSpacesResp getResult() throws TException { } } - public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler445) throws TException { + public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler446) throws TException { checkReady(); - createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler445, this, ___protocolFactory, ___transport); + createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler446, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpaceAs_call extends TAsyncMethodCall { private CreateSpaceAsReq req; - public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler446, TAsyncClient client442, TProtocolFactory protocolFactory443, TNonblockingTransport transport444) throws TException { - super(client442, protocolFactory443, transport444, resultHandler446, false); + public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler447, TAsyncClient client443, TProtocolFactory protocolFactory444, TNonblockingTransport transport445) throws TException { + super(client443, protocolFactory444, transport445, resultHandler447, false); this.req = req; } @@ -4605,17 +4654,17 @@ public ExecResp getResult() throws TException { } } - public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler450) throws TException { + public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler451) throws TException { checkReady(); - createTag_call method_call = new createTag_call(req, resultHandler450, this, ___protocolFactory, ___transport); + createTag_call method_call = new createTag_call(req, resultHandler451, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTag_call extends TAsyncMethodCall { private CreateTagReq req; - public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler451, TAsyncClient client447, TProtocolFactory protocolFactory448, TNonblockingTransport transport449) throws TException { - super(client447, protocolFactory448, transport449, resultHandler451, false); + public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler452, TAsyncClient client448, TProtocolFactory protocolFactory449, TNonblockingTransport transport450) throws TException { + super(client448, protocolFactory449, transport450, resultHandler452, false); this.req = req; } @@ -4637,17 +4686,17 @@ public ExecResp getResult() throws TException { } } - public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler455) throws TException { + public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler456) throws TException { checkReady(); - alterTag_call method_call = new alterTag_call(req, resultHandler455, this, ___protocolFactory, ___transport); + alterTag_call method_call = new alterTag_call(req, resultHandler456, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterTag_call extends TAsyncMethodCall { private AlterTagReq req; - public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler456, TAsyncClient client452, TProtocolFactory protocolFactory453, TNonblockingTransport transport454) throws TException { - super(client452, protocolFactory453, transport454, resultHandler456, false); + public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler457, TAsyncClient client453, TProtocolFactory protocolFactory454, TNonblockingTransport transport455) throws TException { + super(client453, protocolFactory454, transport455, resultHandler457, false); this.req = req; } @@ -4669,17 +4718,17 @@ public ExecResp getResult() throws TException { } } - public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler460) throws TException { + public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler461) throws TException { checkReady(); - dropTag_call method_call = new dropTag_call(req, resultHandler460, this, ___protocolFactory, ___transport); + dropTag_call method_call = new dropTag_call(req, resultHandler461, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTag_call extends TAsyncMethodCall { private DropTagReq req; - public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler461, TAsyncClient client457, TProtocolFactory protocolFactory458, TNonblockingTransport transport459) throws TException { - super(client457, protocolFactory458, transport459, resultHandler461, false); + public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler462, TAsyncClient client458, TProtocolFactory protocolFactory459, TNonblockingTransport transport460) throws TException { + super(client458, protocolFactory459, transport460, resultHandler462, false); this.req = req; } @@ -4701,17 +4750,17 @@ public ExecResp getResult() throws TException { } } - public void getTag(GetTagReq req, AsyncMethodCallback resultHandler465) throws TException { + public void getTag(GetTagReq req, AsyncMethodCallback resultHandler466) throws TException { checkReady(); - getTag_call method_call = new getTag_call(req, resultHandler465, this, ___protocolFactory, ___transport); + getTag_call method_call = new getTag_call(req, resultHandler466, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTag_call extends TAsyncMethodCall { private GetTagReq req; - public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler466, TAsyncClient client462, TProtocolFactory protocolFactory463, TNonblockingTransport transport464) throws TException { - super(client462, protocolFactory463, transport464, resultHandler466, false); + public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler467, TAsyncClient client463, TProtocolFactory protocolFactory464, TNonblockingTransport transport465) throws TException { + super(client463, protocolFactory464, transport465, resultHandler467, false); this.req = req; } @@ -4733,17 +4782,17 @@ public GetTagResp getResult() throws TException { } } - public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler470) throws TException { + public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler471) throws TException { checkReady(); - listTags_call method_call = new listTags_call(req, resultHandler470, this, ___protocolFactory, ___transport); + listTags_call method_call = new listTags_call(req, resultHandler471, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTags_call extends TAsyncMethodCall { private ListTagsReq req; - public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler471, TAsyncClient client467, TProtocolFactory protocolFactory468, TNonblockingTransport transport469) throws TException { - super(client467, protocolFactory468, transport469, resultHandler471, false); + public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler472, TAsyncClient client468, TProtocolFactory protocolFactory469, TNonblockingTransport transport470) throws TException { + super(client468, protocolFactory469, transport470, resultHandler472, false); this.req = req; } @@ -4765,17 +4814,17 @@ public ListTagsResp getResult() throws TException { } } - public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler475) throws TException { + public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler476) throws TException { checkReady(); - createEdge_call method_call = new createEdge_call(req, resultHandler475, this, ___protocolFactory, ___transport); + createEdge_call method_call = new createEdge_call(req, resultHandler476, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdge_call extends TAsyncMethodCall { private CreateEdgeReq req; - public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler476, TAsyncClient client472, TProtocolFactory protocolFactory473, TNonblockingTransport transport474) throws TException { - super(client472, protocolFactory473, transport474, resultHandler476, false); + public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler477, TAsyncClient client473, TProtocolFactory protocolFactory474, TNonblockingTransport transport475) throws TException { + super(client473, protocolFactory474, transport475, resultHandler477, false); this.req = req; } @@ -4797,17 +4846,17 @@ public ExecResp getResult() throws TException { } } - public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler480) throws TException { + public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler481) throws TException { checkReady(); - alterEdge_call method_call = new alterEdge_call(req, resultHandler480, this, ___protocolFactory, ___transport); + alterEdge_call method_call = new alterEdge_call(req, resultHandler481, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterEdge_call extends TAsyncMethodCall { private AlterEdgeReq req; - public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler481, TAsyncClient client477, TProtocolFactory protocolFactory478, TNonblockingTransport transport479) throws TException { - super(client477, protocolFactory478, transport479, resultHandler481, false); + public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler482, TAsyncClient client478, TProtocolFactory protocolFactory479, TNonblockingTransport transport480) throws TException { + super(client478, protocolFactory479, transport480, resultHandler482, false); this.req = req; } @@ -4829,17 +4878,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler485) throws TException { + public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler486) throws TException { checkReady(); - dropEdge_call method_call = new dropEdge_call(req, resultHandler485, this, ___protocolFactory, ___transport); + dropEdge_call method_call = new dropEdge_call(req, resultHandler486, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdge_call extends TAsyncMethodCall { private DropEdgeReq req; - public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler486, TAsyncClient client482, TProtocolFactory protocolFactory483, TNonblockingTransport transport484) throws TException { - super(client482, protocolFactory483, transport484, resultHandler486, false); + public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler487, TAsyncClient client483, TProtocolFactory protocolFactory484, TNonblockingTransport transport485) throws TException { + super(client483, protocolFactory484, transport485, resultHandler487, false); this.req = req; } @@ -4861,17 +4910,17 @@ public ExecResp getResult() throws TException { } } - public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler490) throws TException { + public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler491) throws TException { checkReady(); - getEdge_call method_call = new getEdge_call(req, resultHandler490, this, ___protocolFactory, ___transport); + getEdge_call method_call = new getEdge_call(req, resultHandler491, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdge_call extends TAsyncMethodCall { private GetEdgeReq req; - public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler491, TAsyncClient client487, TProtocolFactory protocolFactory488, TNonblockingTransport transport489) throws TException { - super(client487, protocolFactory488, transport489, resultHandler491, false); + public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler492, TAsyncClient client488, TProtocolFactory protocolFactory489, TNonblockingTransport transport490) throws TException { + super(client488, protocolFactory489, transport490, resultHandler492, false); this.req = req; } @@ -4893,17 +4942,17 @@ public GetEdgeResp getResult() throws TException { } } - public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler495) throws TException { + public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler496) throws TException { checkReady(); - listEdges_call method_call = new listEdges_call(req, resultHandler495, this, ___protocolFactory, ___transport); + listEdges_call method_call = new listEdges_call(req, resultHandler496, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdges_call extends TAsyncMethodCall { private ListEdgesReq req; - public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler496, TAsyncClient client492, TProtocolFactory protocolFactory493, TNonblockingTransport transport494) throws TException { - super(client492, protocolFactory493, transport494, resultHandler496, false); + public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler497, TAsyncClient client493, TProtocolFactory protocolFactory494, TNonblockingTransport transport495) throws TException { + super(client493, protocolFactory494, transport495, resultHandler497, false); this.req = req; } @@ -4925,17 +4974,17 @@ public ListEdgesResp getResult() throws TException { } } - public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler500) throws TException { + public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler501) throws TException { checkReady(); - listHosts_call method_call = new listHosts_call(req, resultHandler500, this, ___protocolFactory, ___transport); + listHosts_call method_call = new listHosts_call(req, resultHandler501, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listHosts_call extends TAsyncMethodCall { private ListHostsReq req; - public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler501, TAsyncClient client497, TProtocolFactory protocolFactory498, TNonblockingTransport transport499) throws TException { - super(client497, protocolFactory498, transport499, resultHandler501, false); + public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler502, TAsyncClient client498, TProtocolFactory protocolFactory499, TNonblockingTransport transport500) throws TException { + super(client498, protocolFactory499, transport500, resultHandler502, false); this.req = req; } @@ -4957,17 +5006,17 @@ public ListHostsResp getResult() throws TException { } } - public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler505) throws TException { + public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler506) throws TException { checkReady(); - getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler505, this, ___protocolFactory, ___transport); + getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler506, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getPartsAlloc_call extends TAsyncMethodCall { private GetPartsAllocReq req; - public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler506, TAsyncClient client502, TProtocolFactory protocolFactory503, TNonblockingTransport transport504) throws TException { - super(client502, protocolFactory503, transport504, resultHandler506, false); + public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler507, TAsyncClient client503, TProtocolFactory protocolFactory504, TNonblockingTransport transport505) throws TException { + super(client503, protocolFactory504, transport505, resultHandler507, false); this.req = req; } @@ -4989,17 +5038,17 @@ public GetPartsAllocResp getResult() throws TException { } } - public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler510) throws TException { + public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler511) throws TException { checkReady(); - listParts_call method_call = new listParts_call(req, resultHandler510, this, ___protocolFactory, ___transport); + listParts_call method_call = new listParts_call(req, resultHandler511, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listParts_call extends TAsyncMethodCall { private ListPartsReq req; - public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler511, TAsyncClient client507, TProtocolFactory protocolFactory508, TNonblockingTransport transport509) throws TException { - super(client507, protocolFactory508, transport509, resultHandler511, false); + public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler512, TAsyncClient client508, TProtocolFactory protocolFactory509, TNonblockingTransport transport510) throws TException { + super(client508, protocolFactory509, transport510, resultHandler512, false); this.req = req; } @@ -5021,17 +5070,17 @@ public ListPartsResp getResult() throws TException { } } - public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler515) throws TException { + public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler516) throws TException { checkReady(); - multiPut_call method_call = new multiPut_call(req, resultHandler515, this, ___protocolFactory, ___transport); + multiPut_call method_call = new multiPut_call(req, resultHandler516, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiPut_call extends TAsyncMethodCall { private MultiPutReq req; - public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler516, TAsyncClient client512, TProtocolFactory protocolFactory513, TNonblockingTransport transport514) throws TException { - super(client512, protocolFactory513, transport514, resultHandler516, false); + public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler517, TAsyncClient client513, TProtocolFactory protocolFactory514, TNonblockingTransport transport515) throws TException { + super(client513, protocolFactory514, transport515, resultHandler517, false); this.req = req; } @@ -5053,17 +5102,17 @@ public ExecResp getResult() throws TException { } } - public void get(GetReq req, AsyncMethodCallback resultHandler520) throws TException { + public void get(GetReq req, AsyncMethodCallback resultHandler521) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler520, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler521, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private GetReq req; - public get_call(GetReq req, AsyncMethodCallback resultHandler521, TAsyncClient client517, TProtocolFactory protocolFactory518, TNonblockingTransport transport519) throws TException { - super(client517, protocolFactory518, transport519, resultHandler521, false); + public get_call(GetReq req, AsyncMethodCallback resultHandler522, TAsyncClient client518, TProtocolFactory protocolFactory519, TNonblockingTransport transport520) throws TException { + super(client518, protocolFactory519, transport520, resultHandler522, false); this.req = req; } @@ -5085,17 +5134,17 @@ public GetResp getResult() throws TException { } } - public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler525) throws TException { + public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler526) throws TException { checkReady(); - multiGet_call method_call = new multiGet_call(req, resultHandler525, this, ___protocolFactory, ___transport); + multiGet_call method_call = new multiGet_call(req, resultHandler526, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiGet_call extends TAsyncMethodCall { private MultiGetReq req; - public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler526, TAsyncClient client522, TProtocolFactory protocolFactory523, TNonblockingTransport transport524) throws TException { - super(client522, protocolFactory523, transport524, resultHandler526, false); + public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler527, TAsyncClient client523, TProtocolFactory protocolFactory524, TNonblockingTransport transport525) throws TException { + super(client523, protocolFactory524, transport525, resultHandler527, false); this.req = req; } @@ -5117,17 +5166,17 @@ public MultiGetResp getResult() throws TException { } } - public void remove(RemoveReq req, AsyncMethodCallback resultHandler530) throws TException { + public void remove(RemoveReq req, AsyncMethodCallback resultHandler531) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler530, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler531, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private RemoveReq req; - public remove_call(RemoveReq req, AsyncMethodCallback resultHandler531, TAsyncClient client527, TProtocolFactory protocolFactory528, TNonblockingTransport transport529) throws TException { - super(client527, protocolFactory528, transport529, resultHandler531, false); + public remove_call(RemoveReq req, AsyncMethodCallback resultHandler532, TAsyncClient client528, TProtocolFactory protocolFactory529, TNonblockingTransport transport530) throws TException { + super(client528, protocolFactory529, transport530, resultHandler532, false); this.req = req; } @@ -5149,17 +5198,17 @@ public ExecResp getResult() throws TException { } } - public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler535) throws TException { + public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler536) throws TException { checkReady(); - removeRange_call method_call = new removeRange_call(req, resultHandler535, this, ___protocolFactory, ___transport); + removeRange_call method_call = new removeRange_call(req, resultHandler536, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeRange_call extends TAsyncMethodCall { private RemoveRangeReq req; - public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler536, TAsyncClient client532, TProtocolFactory protocolFactory533, TNonblockingTransport transport534) throws TException { - super(client532, protocolFactory533, transport534, resultHandler536, false); + public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler537, TAsyncClient client533, TProtocolFactory protocolFactory534, TNonblockingTransport transport535) throws TException { + super(client533, protocolFactory534, transport535, resultHandler537, false); this.req = req; } @@ -5181,17 +5230,17 @@ public ExecResp getResult() throws TException { } } - public void scan(ScanReq req, AsyncMethodCallback resultHandler540) throws TException { + public void scan(ScanReq req, AsyncMethodCallback resultHandler541) throws TException { checkReady(); - scan_call method_call = new scan_call(req, resultHandler540, this, ___protocolFactory, ___transport); + scan_call method_call = new scan_call(req, resultHandler541, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scan_call extends TAsyncMethodCall { private ScanReq req; - public scan_call(ScanReq req, AsyncMethodCallback resultHandler541, TAsyncClient client537, TProtocolFactory protocolFactory538, TNonblockingTransport transport539) throws TException { - super(client537, protocolFactory538, transport539, resultHandler541, false); + public scan_call(ScanReq req, AsyncMethodCallback resultHandler542, TAsyncClient client538, TProtocolFactory protocolFactory539, TNonblockingTransport transport540) throws TException { + super(client538, protocolFactory539, transport540, resultHandler542, false); this.req = req; } @@ -5213,17 +5262,17 @@ public ScanResp getResult() throws TException { } } - public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler545) throws TException { + public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler546) throws TException { checkReady(); - createTagIndex_call method_call = new createTagIndex_call(req, resultHandler545, this, ___protocolFactory, ___transport); + createTagIndex_call method_call = new createTagIndex_call(req, resultHandler546, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTagIndex_call extends TAsyncMethodCall { private CreateTagIndexReq req; - public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler546, TAsyncClient client542, TProtocolFactory protocolFactory543, TNonblockingTransport transport544) throws TException { - super(client542, protocolFactory543, transport544, resultHandler546, false); + public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler547, TAsyncClient client543, TProtocolFactory protocolFactory544, TNonblockingTransport transport545) throws TException { + super(client543, protocolFactory544, transport545, resultHandler547, false); this.req = req; } @@ -5245,17 +5294,17 @@ public ExecResp getResult() throws TException { } } - public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler550) throws TException { + public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler551) throws TException { checkReady(); - dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler550, this, ___protocolFactory, ___transport); + dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler551, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTagIndex_call extends TAsyncMethodCall { private DropTagIndexReq req; - public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler551, TAsyncClient client547, TProtocolFactory protocolFactory548, TNonblockingTransport transport549) throws TException { - super(client547, protocolFactory548, transport549, resultHandler551, false); + public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler552, TAsyncClient client548, TProtocolFactory protocolFactory549, TNonblockingTransport transport550) throws TException { + super(client548, protocolFactory549, transport550, resultHandler552, false); this.req = req; } @@ -5277,17 +5326,17 @@ public ExecResp getResult() throws TException { } } - public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler555) throws TException { + public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler556) throws TException { checkReady(); - getTagIndex_call method_call = new getTagIndex_call(req, resultHandler555, this, ___protocolFactory, ___transport); + getTagIndex_call method_call = new getTagIndex_call(req, resultHandler556, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTagIndex_call extends TAsyncMethodCall { private GetTagIndexReq req; - public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler556, TAsyncClient client552, TProtocolFactory protocolFactory553, TNonblockingTransport transport554) throws TException { - super(client552, protocolFactory553, transport554, resultHandler556, false); + public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler557, TAsyncClient client553, TProtocolFactory protocolFactory554, TNonblockingTransport transport555) throws TException { + super(client553, protocolFactory554, transport555, resultHandler557, false); this.req = req; } @@ -5309,17 +5358,17 @@ public GetTagIndexResp getResult() throws TException { } } - public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler560) throws TException { + public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler561) throws TException { checkReady(); - listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler560, this, ___protocolFactory, ___transport); + listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler561, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexes_call extends TAsyncMethodCall { private ListTagIndexesReq req; - public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler561, TAsyncClient client557, TProtocolFactory protocolFactory558, TNonblockingTransport transport559) throws TException { - super(client557, protocolFactory558, transport559, resultHandler561, false); + public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler562, TAsyncClient client558, TProtocolFactory protocolFactory559, TNonblockingTransport transport560) throws TException { + super(client558, protocolFactory559, transport560, resultHandler562, false); this.req = req; } @@ -5341,17 +5390,17 @@ public ListTagIndexesResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler565) throws TException { + public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler566) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler565, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler566, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler566, TAsyncClient client562, TProtocolFactory protocolFactory563, TNonblockingTransport transport564) throws TException { - super(client562, protocolFactory563, transport564, resultHandler566, false); + public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler567, TAsyncClient client563, TProtocolFactory protocolFactory564, TNonblockingTransport transport565) throws TException { + super(client563, protocolFactory564, transport565, resultHandler567, false); this.req = req; } @@ -5373,17 +5422,17 @@ public ExecResp getResult() throws TException { } } - public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler570) throws TException { + public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler571) throws TException { checkReady(); - listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler570, this, ___protocolFactory, ___transport); + listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler571, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler571, TAsyncClient client567, TProtocolFactory protocolFactory568, TNonblockingTransport transport569) throws TException { - super(client567, protocolFactory568, transport569, resultHandler571, false); + public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler572, TAsyncClient client568, TProtocolFactory protocolFactory569, TNonblockingTransport transport570) throws TException { + super(client568, protocolFactory569, transport570, resultHandler572, false); this.req = req; } @@ -5405,17 +5454,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler575) throws TException { + public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler576) throws TException { checkReady(); - createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler575, this, ___protocolFactory, ___transport); + createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler576, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdgeIndex_call extends TAsyncMethodCall { private CreateEdgeIndexReq req; - public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler576, TAsyncClient client572, TProtocolFactory protocolFactory573, TNonblockingTransport transport574) throws TException { - super(client572, protocolFactory573, transport574, resultHandler576, false); + public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler577, TAsyncClient client573, TProtocolFactory protocolFactory574, TNonblockingTransport transport575) throws TException { + super(client573, protocolFactory574, transport575, resultHandler577, false); this.req = req; } @@ -5437,17 +5486,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler580) throws TException { + public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler581) throws TException { checkReady(); - dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler580, this, ___protocolFactory, ___transport); + dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler581, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdgeIndex_call extends TAsyncMethodCall { private DropEdgeIndexReq req; - public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler581, TAsyncClient client577, TProtocolFactory protocolFactory578, TNonblockingTransport transport579) throws TException { - super(client577, protocolFactory578, transport579, resultHandler581, false); + public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler582, TAsyncClient client578, TProtocolFactory protocolFactory579, TNonblockingTransport transport580) throws TException { + super(client578, protocolFactory579, transport580, resultHandler582, false); this.req = req; } @@ -5469,17 +5518,17 @@ public ExecResp getResult() throws TException { } } - public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler585) throws TException { + public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler586) throws TException { checkReady(); - getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler585, this, ___protocolFactory, ___transport); + getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler586, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdgeIndex_call extends TAsyncMethodCall { private GetEdgeIndexReq req; - public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler586, TAsyncClient client582, TProtocolFactory protocolFactory583, TNonblockingTransport transport584) throws TException { - super(client582, protocolFactory583, transport584, resultHandler586, false); + public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler587, TAsyncClient client583, TProtocolFactory protocolFactory584, TNonblockingTransport transport585) throws TException { + super(client583, protocolFactory584, transport585, resultHandler587, false); this.req = req; } @@ -5501,17 +5550,17 @@ public GetEdgeIndexResp getResult() throws TException { } } - public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler590) throws TException { + public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler591) throws TException { checkReady(); - listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler590, this, ___protocolFactory, ___transport); + listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler591, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexes_call extends TAsyncMethodCall { private ListEdgeIndexesReq req; - public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler591, TAsyncClient client587, TProtocolFactory protocolFactory588, TNonblockingTransport transport589) throws TException { - super(client587, protocolFactory588, transport589, resultHandler591, false); + public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler592, TAsyncClient client588, TProtocolFactory protocolFactory589, TNonblockingTransport transport590) throws TException { + super(client588, protocolFactory589, transport590, resultHandler592, false); this.req = req; } @@ -5533,17 +5582,17 @@ public ListEdgeIndexesResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler595) throws TException { + public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler596) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler595, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler596, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler596, TAsyncClient client592, TProtocolFactory protocolFactory593, TNonblockingTransport transport594) throws TException { - super(client592, protocolFactory593, transport594, resultHandler596, false); + public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler597, TAsyncClient client593, TProtocolFactory protocolFactory594, TNonblockingTransport transport595) throws TException { + super(client593, protocolFactory594, transport595, resultHandler597, false); this.req = req; } @@ -5565,17 +5614,17 @@ public ExecResp getResult() throws TException { } } - public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler600) throws TException { + public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler601) throws TException { checkReady(); - listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler600, this, ___protocolFactory, ___transport); + listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler601, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler601, TAsyncClient client597, TProtocolFactory protocolFactory598, TNonblockingTransport transport599) throws TException { - super(client597, protocolFactory598, transport599, resultHandler601, false); + public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler602, TAsyncClient client598, TProtocolFactory protocolFactory599, TNonblockingTransport transport600) throws TException { + super(client598, protocolFactory599, transport600, resultHandler602, false); this.req = req; } @@ -5597,17 +5646,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler605) throws TException { + public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler606) throws TException { checkReady(); - createUser_call method_call = new createUser_call(req, resultHandler605, this, ___protocolFactory, ___transport); + createUser_call method_call = new createUser_call(req, resultHandler606, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createUser_call extends TAsyncMethodCall { private CreateUserReq req; - public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler606, TAsyncClient client602, TProtocolFactory protocolFactory603, TNonblockingTransport transport604) throws TException { - super(client602, protocolFactory603, transport604, resultHandler606, false); + public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler607, TAsyncClient client603, TProtocolFactory protocolFactory604, TNonblockingTransport transport605) throws TException { + super(client603, protocolFactory604, transport605, resultHandler607, false); this.req = req; } @@ -5629,17 +5678,17 @@ public ExecResp getResult() throws TException { } } - public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler610) throws TException { + public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler611) throws TException { checkReady(); - dropUser_call method_call = new dropUser_call(req, resultHandler610, this, ___protocolFactory, ___transport); + dropUser_call method_call = new dropUser_call(req, resultHandler611, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropUser_call extends TAsyncMethodCall { private DropUserReq req; - public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler611, TAsyncClient client607, TProtocolFactory protocolFactory608, TNonblockingTransport transport609) throws TException { - super(client607, protocolFactory608, transport609, resultHandler611, false); + public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler612, TAsyncClient client608, TProtocolFactory protocolFactory609, TNonblockingTransport transport610) throws TException { + super(client608, protocolFactory609, transport610, resultHandler612, false); this.req = req; } @@ -5661,17 +5710,17 @@ public ExecResp getResult() throws TException { } } - public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler615) throws TException { + public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler616) throws TException { checkReady(); - alterUser_call method_call = new alterUser_call(req, resultHandler615, this, ___protocolFactory, ___transport); + alterUser_call method_call = new alterUser_call(req, resultHandler616, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterUser_call extends TAsyncMethodCall { private AlterUserReq req; - public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler616, TAsyncClient client612, TProtocolFactory protocolFactory613, TNonblockingTransport transport614) throws TException { - super(client612, protocolFactory613, transport614, resultHandler616, false); + public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler617, TAsyncClient client613, TProtocolFactory protocolFactory614, TNonblockingTransport transport615) throws TException { + super(client613, protocolFactory614, transport615, resultHandler617, false); this.req = req; } @@ -5693,17 +5742,17 @@ public ExecResp getResult() throws TException { } } - public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler620) throws TException { + public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler621) throws TException { checkReady(); - grantRole_call method_call = new grantRole_call(req, resultHandler620, this, ___protocolFactory, ___transport); + grantRole_call method_call = new grantRole_call(req, resultHandler621, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class grantRole_call extends TAsyncMethodCall { private GrantRoleReq req; - public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler621, TAsyncClient client617, TProtocolFactory protocolFactory618, TNonblockingTransport transport619) throws TException { - super(client617, protocolFactory618, transport619, resultHandler621, false); + public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler622, TAsyncClient client618, TProtocolFactory protocolFactory619, TNonblockingTransport transport620) throws TException { + super(client618, protocolFactory619, transport620, resultHandler622, false); this.req = req; } @@ -5725,17 +5774,17 @@ public ExecResp getResult() throws TException { } } - public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler625) throws TException { + public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler626) throws TException { checkReady(); - revokeRole_call method_call = new revokeRole_call(req, resultHandler625, this, ___protocolFactory, ___transport); + revokeRole_call method_call = new revokeRole_call(req, resultHandler626, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class revokeRole_call extends TAsyncMethodCall { private RevokeRoleReq req; - public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler626, TAsyncClient client622, TProtocolFactory protocolFactory623, TNonblockingTransport transport624) throws TException { - super(client622, protocolFactory623, transport624, resultHandler626, false); + public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler627, TAsyncClient client623, TProtocolFactory protocolFactory624, TNonblockingTransport transport625) throws TException { + super(client623, protocolFactory624, transport625, resultHandler627, false); this.req = req; } @@ -5757,17 +5806,17 @@ public ExecResp getResult() throws TException { } } - public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler630) throws TException { + public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler631) throws TException { checkReady(); - listUsers_call method_call = new listUsers_call(req, resultHandler630, this, ___protocolFactory, ___transport); + listUsers_call method_call = new listUsers_call(req, resultHandler631, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listUsers_call extends TAsyncMethodCall { private ListUsersReq req; - public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler631, TAsyncClient client627, TProtocolFactory protocolFactory628, TNonblockingTransport transport629) throws TException { - super(client627, protocolFactory628, transport629, resultHandler631, false); + public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler632, TAsyncClient client628, TProtocolFactory protocolFactory629, TNonblockingTransport transport630) throws TException { + super(client628, protocolFactory629, transport630, resultHandler632, false); this.req = req; } @@ -5789,17 +5838,17 @@ public ListUsersResp getResult() throws TException { } } - public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler635) throws TException { + public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler636) throws TException { checkReady(); - listRoles_call method_call = new listRoles_call(req, resultHandler635, this, ___protocolFactory, ___transport); + listRoles_call method_call = new listRoles_call(req, resultHandler636, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listRoles_call extends TAsyncMethodCall { private ListRolesReq req; - public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler636, TAsyncClient client632, TProtocolFactory protocolFactory633, TNonblockingTransport transport634) throws TException { - super(client632, protocolFactory633, transport634, resultHandler636, false); + public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler637, TAsyncClient client633, TProtocolFactory protocolFactory634, TNonblockingTransport transport635) throws TException { + super(client633, protocolFactory634, transport635, resultHandler637, false); this.req = req; } @@ -5821,17 +5870,17 @@ public ListRolesResp getResult() throws TException { } } - public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler640) throws TException { + public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler641) throws TException { checkReady(); - getUserRoles_call method_call = new getUserRoles_call(req, resultHandler640, this, ___protocolFactory, ___transport); + getUserRoles_call method_call = new getUserRoles_call(req, resultHandler641, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUserRoles_call extends TAsyncMethodCall { private GetUserRolesReq req; - public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler641, TAsyncClient client637, TProtocolFactory protocolFactory638, TNonblockingTransport transport639) throws TException { - super(client637, protocolFactory638, transport639, resultHandler641, false); + public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler642, TAsyncClient client638, TProtocolFactory protocolFactory639, TNonblockingTransport transport640) throws TException { + super(client638, protocolFactory639, transport640, resultHandler642, false); this.req = req; } @@ -5853,17 +5902,17 @@ public ListRolesResp getResult() throws TException { } } - public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler645) throws TException { + public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler646) throws TException { checkReady(); - changePassword_call method_call = new changePassword_call(req, resultHandler645, this, ___protocolFactory, ___transport); + changePassword_call method_call = new changePassword_call(req, resultHandler646, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class changePassword_call extends TAsyncMethodCall { private ChangePasswordReq req; - public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler646, TAsyncClient client642, TProtocolFactory protocolFactory643, TNonblockingTransport transport644) throws TException { - super(client642, protocolFactory643, transport644, resultHandler646, false); + public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler647, TAsyncClient client643, TProtocolFactory protocolFactory644, TNonblockingTransport transport645) throws TException { + super(client643, protocolFactory644, transport645, resultHandler647, false); this.req = req; } @@ -5885,17 +5934,17 @@ public ExecResp getResult() throws TException { } } - public void heartBeat(HBReq req, AsyncMethodCallback resultHandler650) throws TException { + public void heartBeat(HBReq req, AsyncMethodCallback resultHandler651) throws TException { checkReady(); - heartBeat_call method_call = new heartBeat_call(req, resultHandler650, this, ___protocolFactory, ___transport); + heartBeat_call method_call = new heartBeat_call(req, resultHandler651, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class heartBeat_call extends TAsyncMethodCall { private HBReq req; - public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler651, TAsyncClient client647, TProtocolFactory protocolFactory648, TNonblockingTransport transport649) throws TException { - super(client647, protocolFactory648, transport649, resultHandler651, false); + public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler652, TAsyncClient client648, TProtocolFactory protocolFactory649, TNonblockingTransport transport650) throws TException { + super(client648, protocolFactory649, transport650, resultHandler652, false); this.req = req; } @@ -5917,17 +5966,17 @@ public HBResp getResult() throws TException { } } - public void balance(BalanceReq req, AsyncMethodCallback resultHandler655) throws TException { + public void balance(BalanceReq req, AsyncMethodCallback resultHandler656) throws TException { checkReady(); - balance_call method_call = new balance_call(req, resultHandler655, this, ___protocolFactory, ___transport); + balance_call method_call = new balance_call(req, resultHandler656, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class balance_call extends TAsyncMethodCall { private BalanceReq req; - public balance_call(BalanceReq req, AsyncMethodCallback resultHandler656, TAsyncClient client652, TProtocolFactory protocolFactory653, TNonblockingTransport transport654) throws TException { - super(client652, protocolFactory653, transport654, resultHandler656, false); + public balance_call(BalanceReq req, AsyncMethodCallback resultHandler657, TAsyncClient client653, TProtocolFactory protocolFactory654, TNonblockingTransport transport655) throws TException { + super(client653, protocolFactory654, transport655, resultHandler657, false); this.req = req; } @@ -5949,17 +5998,17 @@ public BalanceResp getResult() throws TException { } } - public void leaderBalance(LeaderBalanceReq req, AsyncMethodCallback resultHandler660) throws TException { + public void leaderBalance(LeaderBalanceReq req, AsyncMethodCallback resultHandler661) throws TException { checkReady(); - leaderBalance_call method_call = new leaderBalance_call(req, resultHandler660, this, ___protocolFactory, ___transport); + leaderBalance_call method_call = new leaderBalance_call(req, resultHandler661, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class leaderBalance_call extends TAsyncMethodCall { private LeaderBalanceReq req; - public leaderBalance_call(LeaderBalanceReq req, AsyncMethodCallback resultHandler661, TAsyncClient client657, TProtocolFactory protocolFactory658, TNonblockingTransport transport659) throws TException { - super(client657, protocolFactory658, transport659, resultHandler661, false); + public leaderBalance_call(LeaderBalanceReq req, AsyncMethodCallback resultHandler662, TAsyncClient client658, TProtocolFactory protocolFactory659, TNonblockingTransport transport660) throws TException { + super(client658, protocolFactory659, transport660, resultHandler662, false); this.req = req; } @@ -5981,17 +6030,17 @@ public ExecResp getResult() throws TException { } } - public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler665) throws TException { + public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler666) throws TException { checkReady(); - regConfig_call method_call = new regConfig_call(req, resultHandler665, this, ___protocolFactory, ___transport); + regConfig_call method_call = new regConfig_call(req, resultHandler666, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class regConfig_call extends TAsyncMethodCall { private RegConfigReq req; - public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler666, TAsyncClient client662, TProtocolFactory protocolFactory663, TNonblockingTransport transport664) throws TException { - super(client662, protocolFactory663, transport664, resultHandler666, false); + public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler667, TAsyncClient client663, TProtocolFactory protocolFactory664, TNonblockingTransport transport665) throws TException { + super(client663, protocolFactory664, transport665, resultHandler667, false); this.req = req; } @@ -6013,17 +6062,17 @@ public ExecResp getResult() throws TException { } } - public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler670) throws TException { + public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler671) throws TException { checkReady(); - getConfig_call method_call = new getConfig_call(req, resultHandler670, this, ___protocolFactory, ___transport); + getConfig_call method_call = new getConfig_call(req, resultHandler671, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getConfig_call extends TAsyncMethodCall { private GetConfigReq req; - public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler671, TAsyncClient client667, TProtocolFactory protocolFactory668, TNonblockingTransport transport669) throws TException { - super(client667, protocolFactory668, transport669, resultHandler671, false); + public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler672, TAsyncClient client668, TProtocolFactory protocolFactory669, TNonblockingTransport transport670) throws TException { + super(client668, protocolFactory669, transport670, resultHandler672, false); this.req = req; } @@ -6045,17 +6094,17 @@ public GetConfigResp getResult() throws TException { } } - public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler675) throws TException { + public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler676) throws TException { checkReady(); - setConfig_call method_call = new setConfig_call(req, resultHandler675, this, ___protocolFactory, ___transport); + setConfig_call method_call = new setConfig_call(req, resultHandler676, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class setConfig_call extends TAsyncMethodCall { private SetConfigReq req; - public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler676, TAsyncClient client672, TProtocolFactory protocolFactory673, TNonblockingTransport transport674) throws TException { - super(client672, protocolFactory673, transport674, resultHandler676, false); + public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler677, TAsyncClient client673, TProtocolFactory protocolFactory674, TNonblockingTransport transport675) throws TException { + super(client673, protocolFactory674, transport675, resultHandler677, false); this.req = req; } @@ -6077,17 +6126,17 @@ public ExecResp getResult() throws TException { } } - public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler680) throws TException { + public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler681) throws TException { checkReady(); - listConfigs_call method_call = new listConfigs_call(req, resultHandler680, this, ___protocolFactory, ___transport); + listConfigs_call method_call = new listConfigs_call(req, resultHandler681, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listConfigs_call extends TAsyncMethodCall { private ListConfigsReq req; - public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler681, TAsyncClient client677, TProtocolFactory protocolFactory678, TNonblockingTransport transport679) throws TException { - super(client677, protocolFactory678, transport679, resultHandler681, false); + public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler682, TAsyncClient client678, TProtocolFactory protocolFactory679, TNonblockingTransport transport680) throws TException { + super(client678, protocolFactory679, transport680, resultHandler682, false); this.req = req; } @@ -6109,17 +6158,17 @@ public ListConfigsResp getResult() throws TException { } } - public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler685) throws TException { + public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler686) throws TException { checkReady(); - createSnapshot_call method_call = new createSnapshot_call(req, resultHandler685, this, ___protocolFactory, ___transport); + createSnapshot_call method_call = new createSnapshot_call(req, resultHandler686, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSnapshot_call extends TAsyncMethodCall { private CreateSnapshotReq req; - public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler686, TAsyncClient client682, TProtocolFactory protocolFactory683, TNonblockingTransport transport684) throws TException { - super(client682, protocolFactory683, transport684, resultHandler686, false); + public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler687, TAsyncClient client683, TProtocolFactory protocolFactory684, TNonblockingTransport transport685) throws TException { + super(client683, protocolFactory684, transport685, resultHandler687, false); this.req = req; } @@ -6141,17 +6190,17 @@ public ExecResp getResult() throws TException { } } - public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler690) throws TException { + public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler691) throws TException { checkReady(); - dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler690, this, ___protocolFactory, ___transport); + dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler691, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSnapshot_call extends TAsyncMethodCall { private DropSnapshotReq req; - public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler691, TAsyncClient client687, TProtocolFactory protocolFactory688, TNonblockingTransport transport689) throws TException { - super(client687, protocolFactory688, transport689, resultHandler691, false); + public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler692, TAsyncClient client688, TProtocolFactory protocolFactory689, TNonblockingTransport transport690) throws TException { + super(client688, protocolFactory689, transport690, resultHandler692, false); this.req = req; } @@ -6173,17 +6222,17 @@ public ExecResp getResult() throws TException { } } - public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler695) throws TException { + public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler696) throws TException { checkReady(); - listSnapshots_call method_call = new listSnapshots_call(req, resultHandler695, this, ___protocolFactory, ___transport); + listSnapshots_call method_call = new listSnapshots_call(req, resultHandler696, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSnapshots_call extends TAsyncMethodCall { private ListSnapshotsReq req; - public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler696, TAsyncClient client692, TProtocolFactory protocolFactory693, TNonblockingTransport transport694) throws TException { - super(client692, protocolFactory693, transport694, resultHandler696, false); + public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler697, TAsyncClient client693, TProtocolFactory protocolFactory694, TNonblockingTransport transport695) throws TException { + super(client693, protocolFactory694, transport695, resultHandler697, false); this.req = req; } @@ -6205,17 +6254,17 @@ public ListSnapshotsResp getResult() throws TException { } } - public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler700) throws TException { + public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler701) throws TException { checkReady(); - runAdminJob_call method_call = new runAdminJob_call(req, resultHandler700, this, ___protocolFactory, ___transport); + runAdminJob_call method_call = new runAdminJob_call(req, resultHandler701, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class runAdminJob_call extends TAsyncMethodCall { private AdminJobReq req; - public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler701, TAsyncClient client697, TProtocolFactory protocolFactory698, TNonblockingTransport transport699) throws TException { - super(client697, protocolFactory698, transport699, resultHandler701, false); + public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler702, TAsyncClient client698, TProtocolFactory protocolFactory699, TNonblockingTransport transport700) throws TException { + super(client698, protocolFactory699, transport700, resultHandler702, false); this.req = req; } @@ -6237,17 +6286,17 @@ public AdminJobResp getResult() throws TException { } } - public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler705) throws TException { + public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler706) throws TException { checkReady(); - addZone_call method_call = new addZone_call(req, resultHandler705, this, ___protocolFactory, ___transport); + addZone_call method_call = new addZone_call(req, resultHandler706, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addZone_call extends TAsyncMethodCall { private AddZoneReq req; - public addZone_call(AddZoneReq req, AsyncMethodCallback resultHandler706, TAsyncClient client702, TProtocolFactory protocolFactory703, TNonblockingTransport transport704) throws TException { - super(client702, protocolFactory703, transport704, resultHandler706, false); + public addZone_call(AddZoneReq req, AsyncMethodCallback resultHandler707, TAsyncClient client703, TProtocolFactory protocolFactory704, TNonblockingTransport transport705) throws TException { + super(client703, protocolFactory704, transport705, resultHandler707, false); this.req = req; } @@ -6269,17 +6318,17 @@ public ExecResp getResult() throws TException { } } - public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler710) throws TException { + public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler711) throws TException { checkReady(); - dropZone_call method_call = new dropZone_call(req, resultHandler710, this, ___protocolFactory, ___transport); + dropZone_call method_call = new dropZone_call(req, resultHandler711, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropZone_call extends TAsyncMethodCall { private DropZoneReq req; - public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler711, TAsyncClient client707, TProtocolFactory protocolFactory708, TNonblockingTransport transport709) throws TException { - super(client707, protocolFactory708, transport709, resultHandler711, false); + public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler712, TAsyncClient client708, TProtocolFactory protocolFactory709, TNonblockingTransport transport710) throws TException { + super(client708, protocolFactory709, transport710, resultHandler712, false); this.req = req; } @@ -6301,17 +6350,17 @@ public ExecResp getResult() throws TException { } } - public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler715) throws TException { + public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler716) throws TException { checkReady(); - addHostIntoZone_call method_call = new addHostIntoZone_call(req, resultHandler715, this, ___protocolFactory, ___transport); + addHostIntoZone_call method_call = new addHostIntoZone_call(req, resultHandler716, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addHostIntoZone_call extends TAsyncMethodCall { private AddHostIntoZoneReq req; - public addHostIntoZone_call(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler716, TAsyncClient client712, TProtocolFactory protocolFactory713, TNonblockingTransport transport714) throws TException { - super(client712, protocolFactory713, transport714, resultHandler716, false); + public addHostIntoZone_call(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler717, TAsyncClient client713, TProtocolFactory protocolFactory714, TNonblockingTransport transport715) throws TException { + super(client713, protocolFactory714, transport715, resultHandler717, false); this.req = req; } @@ -6333,17 +6382,17 @@ public ExecResp getResult() throws TException { } } - public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler720) throws TException { + public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler721) throws TException { checkReady(); - dropHostFromZone_call method_call = new dropHostFromZone_call(req, resultHandler720, this, ___protocolFactory, ___transport); + dropHostFromZone_call method_call = new dropHostFromZone_call(req, resultHandler721, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropHostFromZone_call extends TAsyncMethodCall { private DropHostFromZoneReq req; - public dropHostFromZone_call(DropHostFromZoneReq req, AsyncMethodCallback resultHandler721, TAsyncClient client717, TProtocolFactory protocolFactory718, TNonblockingTransport transport719) throws TException { - super(client717, protocolFactory718, transport719, resultHandler721, false); + public dropHostFromZone_call(DropHostFromZoneReq req, AsyncMethodCallback resultHandler722, TAsyncClient client718, TProtocolFactory protocolFactory719, TNonblockingTransport transport720) throws TException { + super(client718, protocolFactory719, transport720, resultHandler722, false); this.req = req; } @@ -6365,17 +6414,17 @@ public ExecResp getResult() throws TException { } } - public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler725) throws TException { + public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler726) throws TException { checkReady(); - getZone_call method_call = new getZone_call(req, resultHandler725, this, ___protocolFactory, ___transport); + getZone_call method_call = new getZone_call(req, resultHandler726, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getZone_call extends TAsyncMethodCall { private GetZoneReq req; - public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler726, TAsyncClient client722, TProtocolFactory protocolFactory723, TNonblockingTransport transport724) throws TException { - super(client722, protocolFactory723, transport724, resultHandler726, false); + public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler727, TAsyncClient client723, TProtocolFactory protocolFactory724, TNonblockingTransport transport725) throws TException { + super(client723, protocolFactory724, transport725, resultHandler727, false); this.req = req; } @@ -6397,17 +6446,17 @@ public GetZoneResp getResult() throws TException { } } - public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler730) throws TException { + public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler731) throws TException { checkReady(); - listZones_call method_call = new listZones_call(req, resultHandler730, this, ___protocolFactory, ___transport); + listZones_call method_call = new listZones_call(req, resultHandler731, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listZones_call extends TAsyncMethodCall { private ListZonesReq req; - public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler731, TAsyncClient client727, TProtocolFactory protocolFactory728, TNonblockingTransport transport729) throws TException { - super(client727, protocolFactory728, transport729, resultHandler731, false); + public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler732, TAsyncClient client728, TProtocolFactory protocolFactory729, TNonblockingTransport transport730) throws TException { + super(client728, protocolFactory729, transport730, resultHandler732, false); this.req = req; } @@ -6429,17 +6478,17 @@ public ListZonesResp getResult() throws TException { } } - public void addGroup(AddGroupReq req, AsyncMethodCallback resultHandler735) throws TException { + public void addGroup(AddGroupReq req, AsyncMethodCallback resultHandler736) throws TException { checkReady(); - addGroup_call method_call = new addGroup_call(req, resultHandler735, this, ___protocolFactory, ___transport); + addGroup_call method_call = new addGroup_call(req, resultHandler736, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addGroup_call extends TAsyncMethodCall { private AddGroupReq req; - public addGroup_call(AddGroupReq req, AsyncMethodCallback resultHandler736, TAsyncClient client732, TProtocolFactory protocolFactory733, TNonblockingTransport transport734) throws TException { - super(client732, protocolFactory733, transport734, resultHandler736, false); + public addGroup_call(AddGroupReq req, AsyncMethodCallback resultHandler737, TAsyncClient client733, TProtocolFactory protocolFactory734, TNonblockingTransport transport735) throws TException { + super(client733, protocolFactory734, transport735, resultHandler737, false); this.req = req; } @@ -6461,17 +6510,17 @@ public ExecResp getResult() throws TException { } } - public void dropGroup(DropGroupReq req, AsyncMethodCallback resultHandler740) throws TException { + public void dropGroup(DropGroupReq req, AsyncMethodCallback resultHandler741) throws TException { checkReady(); - dropGroup_call method_call = new dropGroup_call(req, resultHandler740, this, ___protocolFactory, ___transport); + dropGroup_call method_call = new dropGroup_call(req, resultHandler741, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropGroup_call extends TAsyncMethodCall { private DropGroupReq req; - public dropGroup_call(DropGroupReq req, AsyncMethodCallback resultHandler741, TAsyncClient client737, TProtocolFactory protocolFactory738, TNonblockingTransport transport739) throws TException { - super(client737, protocolFactory738, transport739, resultHandler741, false); + public dropGroup_call(DropGroupReq req, AsyncMethodCallback resultHandler742, TAsyncClient client738, TProtocolFactory protocolFactory739, TNonblockingTransport transport740) throws TException { + super(client738, protocolFactory739, transport740, resultHandler742, false); this.req = req; } @@ -6493,17 +6542,17 @@ public ExecResp getResult() throws TException { } } - public void addZoneIntoGroup(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler745) throws TException { + public void addZoneIntoGroup(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler746) throws TException { checkReady(); - addZoneIntoGroup_call method_call = new addZoneIntoGroup_call(req, resultHandler745, this, ___protocolFactory, ___transport); + addZoneIntoGroup_call method_call = new addZoneIntoGroup_call(req, resultHandler746, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addZoneIntoGroup_call extends TAsyncMethodCall { private AddZoneIntoGroupReq req; - public addZoneIntoGroup_call(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler746, TAsyncClient client742, TProtocolFactory protocolFactory743, TNonblockingTransport transport744) throws TException { - super(client742, protocolFactory743, transport744, resultHandler746, false); + public addZoneIntoGroup_call(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler747, TAsyncClient client743, TProtocolFactory protocolFactory744, TNonblockingTransport transport745) throws TException { + super(client743, protocolFactory744, transport745, resultHandler747, false); this.req = req; } @@ -6525,17 +6574,17 @@ public ExecResp getResult() throws TException { } } - public void dropZoneFromGroup(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler750) throws TException { + public void dropZoneFromGroup(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler751) throws TException { checkReady(); - dropZoneFromGroup_call method_call = new dropZoneFromGroup_call(req, resultHandler750, this, ___protocolFactory, ___transport); + dropZoneFromGroup_call method_call = new dropZoneFromGroup_call(req, resultHandler751, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropZoneFromGroup_call extends TAsyncMethodCall { private DropZoneFromGroupReq req; - public dropZoneFromGroup_call(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler751, TAsyncClient client747, TProtocolFactory protocolFactory748, TNonblockingTransport transport749) throws TException { - super(client747, protocolFactory748, transport749, resultHandler751, false); + public dropZoneFromGroup_call(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler752, TAsyncClient client748, TProtocolFactory protocolFactory749, TNonblockingTransport transport750) throws TException { + super(client748, protocolFactory749, transport750, resultHandler752, false); this.req = req; } @@ -6557,17 +6606,17 @@ public ExecResp getResult() throws TException { } } - public void getGroup(GetGroupReq req, AsyncMethodCallback resultHandler755) throws TException { + public void getGroup(GetGroupReq req, AsyncMethodCallback resultHandler756) throws TException { checkReady(); - getGroup_call method_call = new getGroup_call(req, resultHandler755, this, ___protocolFactory, ___transport); + getGroup_call method_call = new getGroup_call(req, resultHandler756, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getGroup_call extends TAsyncMethodCall { private GetGroupReq req; - public getGroup_call(GetGroupReq req, AsyncMethodCallback resultHandler756, TAsyncClient client752, TProtocolFactory protocolFactory753, TNonblockingTransport transport754) throws TException { - super(client752, protocolFactory753, transport754, resultHandler756, false); + public getGroup_call(GetGroupReq req, AsyncMethodCallback resultHandler757, TAsyncClient client753, TProtocolFactory protocolFactory754, TNonblockingTransport transport755) throws TException { + super(client753, protocolFactory754, transport755, resultHandler757, false); this.req = req; } @@ -6589,17 +6638,17 @@ public GetGroupResp getResult() throws TException { } } - public void listGroups(ListGroupsReq req, AsyncMethodCallback resultHandler760) throws TException { + public void listGroups(ListGroupsReq req, AsyncMethodCallback resultHandler761) throws TException { checkReady(); - listGroups_call method_call = new listGroups_call(req, resultHandler760, this, ___protocolFactory, ___transport); + listGroups_call method_call = new listGroups_call(req, resultHandler761, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listGroups_call extends TAsyncMethodCall { private ListGroupsReq req; - public listGroups_call(ListGroupsReq req, AsyncMethodCallback resultHandler761, TAsyncClient client757, TProtocolFactory protocolFactory758, TNonblockingTransport transport759) throws TException { - super(client757, protocolFactory758, transport759, resultHandler761, false); + public listGroups_call(ListGroupsReq req, AsyncMethodCallback resultHandler762, TAsyncClient client758, TProtocolFactory protocolFactory759, TNonblockingTransport transport760) throws TException { + super(client758, protocolFactory759, transport760, resultHandler762, false); this.req = req; } @@ -6621,17 +6670,17 @@ public ListGroupsResp getResult() throws TException { } } - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler765) throws TException { + public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler766) throws TException { checkReady(); - createBackup_call method_call = new createBackup_call(req, resultHandler765, this, ___protocolFactory, ___transport); + createBackup_call method_call = new createBackup_call(req, resultHandler766, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createBackup_call extends TAsyncMethodCall { private CreateBackupReq req; - public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler766, TAsyncClient client762, TProtocolFactory protocolFactory763, TNonblockingTransport transport764) throws TException { - super(client762, protocolFactory763, transport764, resultHandler766, false); + public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler767, TAsyncClient client763, TProtocolFactory protocolFactory764, TNonblockingTransport transport765) throws TException { + super(client763, protocolFactory764, transport765, resultHandler767, false); this.req = req; } @@ -6653,17 +6702,17 @@ public CreateBackupResp getResult() throws TException { } } - public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler770) throws TException { + public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler771) throws TException { checkReady(); - restoreMeta_call method_call = new restoreMeta_call(req, resultHandler770, this, ___protocolFactory, ___transport); + restoreMeta_call method_call = new restoreMeta_call(req, resultHandler771, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class restoreMeta_call extends TAsyncMethodCall { private RestoreMetaReq req; - public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler771, TAsyncClient client767, TProtocolFactory protocolFactory768, TNonblockingTransport transport769) throws TException { - super(client767, protocolFactory768, transport769, resultHandler771, false); + public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler772, TAsyncClient client768, TProtocolFactory protocolFactory769, TNonblockingTransport transport770) throws TException { + super(client768, protocolFactory769, transport770, resultHandler772, false); this.req = req; } @@ -6685,17 +6734,17 @@ public ExecResp getResult() throws TException { } } - public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler775) throws TException { + public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler776) throws TException { checkReady(); - addListener_call method_call = new addListener_call(req, resultHandler775, this, ___protocolFactory, ___transport); + addListener_call method_call = new addListener_call(req, resultHandler776, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addListener_call extends TAsyncMethodCall { private AddListenerReq req; - public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler776, TAsyncClient client772, TProtocolFactory protocolFactory773, TNonblockingTransport transport774) throws TException { - super(client772, protocolFactory773, transport774, resultHandler776, false); + public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler777, TAsyncClient client773, TProtocolFactory protocolFactory774, TNonblockingTransport transport775) throws TException { + super(client773, protocolFactory774, transport775, resultHandler777, false); this.req = req; } @@ -6717,17 +6766,17 @@ public ExecResp getResult() throws TException { } } - public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler780) throws TException { + public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler781) throws TException { checkReady(); - removeListener_call method_call = new removeListener_call(req, resultHandler780, this, ___protocolFactory, ___transport); + removeListener_call method_call = new removeListener_call(req, resultHandler781, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeListener_call extends TAsyncMethodCall { private RemoveListenerReq req; - public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler781, TAsyncClient client777, TProtocolFactory protocolFactory778, TNonblockingTransport transport779) throws TException { - super(client777, protocolFactory778, transport779, resultHandler781, false); + public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler782, TAsyncClient client778, TProtocolFactory protocolFactory779, TNonblockingTransport transport780) throws TException { + super(client778, protocolFactory779, transport780, resultHandler782, false); this.req = req; } @@ -6749,17 +6798,17 @@ public ExecResp getResult() throws TException { } } - public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler785) throws TException { + public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler786) throws TException { checkReady(); - listListener_call method_call = new listListener_call(req, resultHandler785, this, ___protocolFactory, ___transport); + listListener_call method_call = new listListener_call(req, resultHandler786, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listListener_call extends TAsyncMethodCall { private ListListenerReq req; - public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler786, TAsyncClient client782, TProtocolFactory protocolFactory783, TNonblockingTransport transport784) throws TException { - super(client782, protocolFactory783, transport784, resultHandler786, false); + public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler787, TAsyncClient client783, TProtocolFactory protocolFactory784, TNonblockingTransport transport785) throws TException { + super(client783, protocolFactory784, transport785, resultHandler787, false); this.req = req; } @@ -6781,17 +6830,17 @@ public ListListenerResp getResult() throws TException { } } - public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler790) throws TException { + public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler791) throws TException { checkReady(); - getStats_call method_call = new getStats_call(req, resultHandler790, this, ___protocolFactory, ___transport); + getStats_call method_call = new getStats_call(req, resultHandler791, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getStats_call extends TAsyncMethodCall { private GetStatsReq req; - public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler791, TAsyncClient client787, TProtocolFactory protocolFactory788, TNonblockingTransport transport789) throws TException { - super(client787, protocolFactory788, transport789, resultHandler791, false); + public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler792, TAsyncClient client788, TProtocolFactory protocolFactory789, TNonblockingTransport transport790) throws TException { + super(client788, protocolFactory789, transport790, resultHandler792, false); this.req = req; } @@ -6813,17 +6862,17 @@ public GetStatsResp getResult() throws TException { } } - public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler795) throws TException { + public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler796) throws TException { checkReady(); - signInFTService_call method_call = new signInFTService_call(req, resultHandler795, this, ___protocolFactory, ___transport); + signInFTService_call method_call = new signInFTService_call(req, resultHandler796, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signInFTService_call extends TAsyncMethodCall { private SignInFTServiceReq req; - public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler796, TAsyncClient client792, TProtocolFactory protocolFactory793, TNonblockingTransport transport794) throws TException { - super(client792, protocolFactory793, transport794, resultHandler796, false); + public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler797, TAsyncClient client793, TProtocolFactory protocolFactory794, TNonblockingTransport transport795) throws TException { + super(client793, protocolFactory794, transport795, resultHandler797, false); this.req = req; } @@ -6845,17 +6894,17 @@ public ExecResp getResult() throws TException { } } - public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler800) throws TException { + public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler801) throws TException { checkReady(); - signOutFTService_call method_call = new signOutFTService_call(req, resultHandler800, this, ___protocolFactory, ___transport); + signOutFTService_call method_call = new signOutFTService_call(req, resultHandler801, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signOutFTService_call extends TAsyncMethodCall { private SignOutFTServiceReq req; - public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler801, TAsyncClient client797, TProtocolFactory protocolFactory798, TNonblockingTransport transport799) throws TException { - super(client797, protocolFactory798, transport799, resultHandler801, false); + public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler802, TAsyncClient client798, TProtocolFactory protocolFactory799, TNonblockingTransport transport800) throws TException { + super(client798, protocolFactory799, transport800, resultHandler802, false); this.req = req; } @@ -6877,17 +6926,17 @@ public ExecResp getResult() throws TException { } } - public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler805) throws TException { + public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler806) throws TException { checkReady(); - listFTClients_call method_call = new listFTClients_call(req, resultHandler805, this, ___protocolFactory, ___transport); + listFTClients_call method_call = new listFTClients_call(req, resultHandler806, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTClients_call extends TAsyncMethodCall { private ListFTClientsReq req; - public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler806, TAsyncClient client802, TProtocolFactory protocolFactory803, TNonblockingTransport transport804) throws TException { - super(client802, protocolFactory803, transport804, resultHandler806, false); + public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler807, TAsyncClient client803, TProtocolFactory protocolFactory804, TNonblockingTransport transport805) throws TException { + super(client803, protocolFactory804, transport805, resultHandler807, false); this.req = req; } @@ -6909,17 +6958,17 @@ public ListFTClientsResp getResult() throws TException { } } - public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler810) throws TException { + public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler811) throws TException { checkReady(); - createFTIndex_call method_call = new createFTIndex_call(req, resultHandler810, this, ___protocolFactory, ___transport); + createFTIndex_call method_call = new createFTIndex_call(req, resultHandler811, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createFTIndex_call extends TAsyncMethodCall { private CreateFTIndexReq req; - public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler811, TAsyncClient client807, TProtocolFactory protocolFactory808, TNonblockingTransport transport809) throws TException { - super(client807, protocolFactory808, transport809, resultHandler811, false); + public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler812, TAsyncClient client808, TProtocolFactory protocolFactory809, TNonblockingTransport transport810) throws TException { + super(client808, protocolFactory809, transport810, resultHandler812, false); this.req = req; } @@ -6941,17 +6990,17 @@ public ExecResp getResult() throws TException { } } - public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler815) throws TException { + public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler816) throws TException { checkReady(); - dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler815, this, ___protocolFactory, ___transport); + dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler816, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropFTIndex_call extends TAsyncMethodCall { private DropFTIndexReq req; - public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler816, TAsyncClient client812, TProtocolFactory protocolFactory813, TNonblockingTransport transport814) throws TException { - super(client812, protocolFactory813, transport814, resultHandler816, false); + public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler817, TAsyncClient client813, TProtocolFactory protocolFactory814, TNonblockingTransport transport815) throws TException { + super(client813, protocolFactory814, transport815, resultHandler817, false); this.req = req; } @@ -6973,17 +7022,17 @@ public ExecResp getResult() throws TException { } } - public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler820) throws TException { + public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler821) throws TException { checkReady(); - listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler820, this, ___protocolFactory, ___transport); + listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler821, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTIndexes_call extends TAsyncMethodCall { private ListFTIndexesReq req; - public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler821, TAsyncClient client817, TProtocolFactory protocolFactory818, TNonblockingTransport transport819) throws TException { - super(client817, protocolFactory818, transport819, resultHandler821, false); + public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler822, TAsyncClient client818, TProtocolFactory protocolFactory819, TNonblockingTransport transport820) throws TException { + super(client818, protocolFactory819, transport820, resultHandler822, false); this.req = req; } @@ -7005,17 +7054,17 @@ public ListFTIndexesResp getResult() throws TException { } } - public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler825) throws TException { + public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler826) throws TException { checkReady(); - createSession_call method_call = new createSession_call(req, resultHandler825, this, ___protocolFactory, ___transport); + createSession_call method_call = new createSession_call(req, resultHandler826, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSession_call extends TAsyncMethodCall { private CreateSessionReq req; - public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler826, TAsyncClient client822, TProtocolFactory protocolFactory823, TNonblockingTransport transport824) throws TException { - super(client822, protocolFactory823, transport824, resultHandler826, false); + public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler827, TAsyncClient client823, TProtocolFactory protocolFactory824, TNonblockingTransport transport825) throws TException { + super(client823, protocolFactory824, transport825, resultHandler827, false); this.req = req; } @@ -7037,17 +7086,17 @@ public CreateSessionResp getResult() throws TException { } } - public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler830) throws TException { + public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler831) throws TException { checkReady(); - updateSessions_call method_call = new updateSessions_call(req, resultHandler830, this, ___protocolFactory, ___transport); + updateSessions_call method_call = new updateSessions_call(req, resultHandler831, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateSessions_call extends TAsyncMethodCall { private UpdateSessionsReq req; - public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler831, TAsyncClient client827, TProtocolFactory protocolFactory828, TNonblockingTransport transport829) throws TException { - super(client827, protocolFactory828, transport829, resultHandler831, false); + public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler832, TAsyncClient client828, TProtocolFactory protocolFactory829, TNonblockingTransport transport830) throws TException { + super(client828, protocolFactory829, transport830, resultHandler832, false); this.req = req; } @@ -7069,17 +7118,17 @@ public UpdateSessionsResp getResult() throws TException { } } - public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler835) throws TException { + public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler836) throws TException { checkReady(); - listSessions_call method_call = new listSessions_call(req, resultHandler835, this, ___protocolFactory, ___transport); + listSessions_call method_call = new listSessions_call(req, resultHandler836, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSessions_call extends TAsyncMethodCall { private ListSessionsReq req; - public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler836, TAsyncClient client832, TProtocolFactory protocolFactory833, TNonblockingTransport transport834) throws TException { - super(client832, protocolFactory833, transport834, resultHandler836, false); + public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler837, TAsyncClient client833, TProtocolFactory protocolFactory834, TNonblockingTransport transport835) throws TException { + super(client833, protocolFactory834, transport835, resultHandler837, false); this.req = req; } @@ -7101,17 +7150,17 @@ public ListSessionsResp getResult() throws TException { } } - public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler840) throws TException { + public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler841) throws TException { checkReady(); - getSession_call method_call = new getSession_call(req, resultHandler840, this, ___protocolFactory, ___transport); + getSession_call method_call = new getSession_call(req, resultHandler841, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSession_call extends TAsyncMethodCall { private GetSessionReq req; - public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler841, TAsyncClient client837, TProtocolFactory protocolFactory838, TNonblockingTransport transport839) throws TException { - super(client837, protocolFactory838, transport839, resultHandler841, false); + public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler842, TAsyncClient client838, TProtocolFactory protocolFactory839, TNonblockingTransport transport840) throws TException { + super(client838, protocolFactory839, transport840, resultHandler842, false); this.req = req; } @@ -7133,17 +7182,17 @@ public GetSessionResp getResult() throws TException { } } - public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler845) throws TException { + public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler846) throws TException { checkReady(); - removeSession_call method_call = new removeSession_call(req, resultHandler845, this, ___protocolFactory, ___transport); + removeSession_call method_call = new removeSession_call(req, resultHandler846, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeSession_call extends TAsyncMethodCall { private RemoveSessionReq req; - public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler846, TAsyncClient client842, TProtocolFactory protocolFactory843, TNonblockingTransport transport844) throws TException { - super(client842, protocolFactory843, transport844, resultHandler846, false); + public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler847, TAsyncClient client843, TProtocolFactory protocolFactory844, TNonblockingTransport transport845) throws TException { + super(client843, protocolFactory844, transport845, resultHandler847, false); this.req = req; } @@ -7165,17 +7214,17 @@ public ExecResp getResult() throws TException { } } - public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler850) throws TException { + public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler851) throws TException { checkReady(); - killQuery_call method_call = new killQuery_call(req, resultHandler850, this, ___protocolFactory, ___transport); + killQuery_call method_call = new killQuery_call(req, resultHandler851, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class killQuery_call extends TAsyncMethodCall { private KillQueryReq req; - public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler851, TAsyncClient client847, TProtocolFactory protocolFactory848, TNonblockingTransport transport849) throws TException { - super(client847, protocolFactory848, transport849, resultHandler851, false); + public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler852, TAsyncClient client848, TProtocolFactory protocolFactory849, TNonblockingTransport transport850) throws TException { + super(client848, protocolFactory849, transport850, resultHandler852, false); this.req = req; } @@ -7197,17 +7246,17 @@ public ExecResp getResult() throws TException { } } - public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler855) throws TException { + public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler856) throws TException { checkReady(); - reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler855, this, ___protocolFactory, ___transport); + reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler856, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class reportTaskFinish_call extends TAsyncMethodCall { private ReportTaskReq req; - public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler856, TAsyncClient client852, TProtocolFactory protocolFactory853, TNonblockingTransport transport854) throws TException { - super(client852, protocolFactory853, transport854, resultHandler856, false); + public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler857, TAsyncClient client853, TProtocolFactory protocolFactory854, TNonblockingTransport transport855) throws TException { + super(client853, protocolFactory854, transport855, resultHandler857, false); this.req = req; } @@ -7229,17 +7278,17 @@ public ExecResp getResult() throws TException { } } - public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler860) throws TException { + public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler861) throws TException { checkReady(); - listCluster_call method_call = new listCluster_call(req, resultHandler860, this, ___protocolFactory, ___transport); + listCluster_call method_call = new listCluster_call(req, resultHandler861, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listCluster_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler861, TAsyncClient client857, TProtocolFactory protocolFactory858, TNonblockingTransport transport859) throws TException { - super(client857, protocolFactory858, transport859, resultHandler861, false); + public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler862, TAsyncClient client858, TProtocolFactory protocolFactory859, TNonblockingTransport transport860) throws TException { + super(client858, protocolFactory859, transport860, resultHandler862, false); this.req = req; } @@ -7261,17 +7310,17 @@ public ListClusterInfoResp getResult() throws TException { } } - public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler865) throws TException { + public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler866) throws TException { checkReady(); - getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler865, this, ___protocolFactory, ___transport); + getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler866, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getMetaDirInfo_call extends TAsyncMethodCall { private GetMetaDirInfoReq req; - public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler866, TAsyncClient client862, TProtocolFactory protocolFactory863, TNonblockingTransport transport864) throws TException { - super(client862, protocolFactory863, transport864, resultHandler866, false); + public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler867, TAsyncClient client863, TProtocolFactory protocolFactory864, TNonblockingTransport transport865) throws TException { + super(client863, protocolFactory864, transport865, resultHandler867, false); this.req = req; } @@ -7293,6 +7342,38 @@ public GetMetaDirInfoResp getResult() throws TException { } } + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler871) throws TException { + checkReady(); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler871, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class verifyClientVersion_call extends TAsyncMethodCall { + private VerifyClientVersionReq req; + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler872, TAsyncClient client868, TProtocolFactory protocolFactory869, TNonblockingTransport transport870) throws TException { + super(client868, protocolFactory869, transport870, resultHandler872, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.CALL, 0)); + verifyClientVersion_args args = new verifyClientVersion_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public VerifyClientVersionResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_verifyClientVersion(); + } + } + } public static class Processor implements TProcessor { @@ -7390,6 +7471,7 @@ public Processor(Iface iface) processMap_.put("reportTaskFinish", new reportTaskFinish()); processMap_.put("listCluster", new listCluster()); processMap_.put("getMetaDirInfo", new getMetaDirInfo()); + processMap_.put("verifyClientVersion", new verifyClientVersion()); } protected static interface ProcessFunction { @@ -9291,6 +9373,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class verifyClientVersion implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.verifyClientVersion", server_ctx); + verifyClientVersion_args args = new verifyClientVersion_args(); + event_handler_.preRead(handler_ctx, "MetaService.verifyClientVersion"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.verifyClientVersion", args); + verifyClientVersion_result result = new verifyClientVersion_result(); + result.success = iface_.verifyClientVersion(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.verifyClientVersion", result); + oprot.writeMessageBegin(new TMessage("verifyClientVersion", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.verifyClientVersion", result); + } + + } + } public static class createSpace_args implements TBase, java.io.Serializable, Cloneable, Comparable { @@ -47801,4 +47904,439 @@ public void validate() throws TException { } + public static class verifyClientVersion_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("verifyClientVersion_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public VerifyClientVersionReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, VerifyClientVersionReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(verifyClientVersion_args.class, metaDataMap); + } + + public verifyClientVersion_args() { + } + + public verifyClientVersion_args( + VerifyClientVersionReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public verifyClientVersion_args(verifyClientVersion_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public verifyClientVersion_args deepCopy() { + return new verifyClientVersion_args(this); + } + + public VerifyClientVersionReq getReq() { + return this.req; + } + + public verifyClientVersion_args setReq(VerifyClientVersionReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((VerifyClientVersionReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof verifyClientVersion_args)) + return false; + verifyClientVersion_args that = (verifyClientVersion_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(verifyClientVersion_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new VerifyClientVersionReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("verifyClientVersion_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class verifyClientVersion_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("verifyClientVersion_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public VerifyClientVersionResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, VerifyClientVersionResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(verifyClientVersion_result.class, metaDataMap); + } + + public verifyClientVersion_result() { + } + + public verifyClientVersion_result( + VerifyClientVersionResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public verifyClientVersion_result(verifyClientVersion_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public verifyClientVersion_result deepCopy() { + return new verifyClientVersion_result(this); + } + + public VerifyClientVersionResp getSuccess() { + return this.success; + } + + public verifyClientVersion_result setSuccess(VerifyClientVersionResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((VerifyClientVersionResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof verifyClientVersion_result)) + return false; + verifyClientVersion_result that = (verifyClientVersion_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(verifyClientVersion_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new VerifyClientVersionResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("verifyClientVersion_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java b/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java index 52262fbe4..fc77cc24b 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java @@ -27,7 +27,8 @@ public enum PropertyType implements com.facebook.thrift.TEnum { TIMESTAMP(21), DATE(24), DATETIME(25), - TIME(26); + TIME(26), + GEOGRAPHY(31); private final int value; @@ -78,6 +79,8 @@ public static PropertyType findByValue(int value) { return DATETIME; case 26: return TIME; + case 31: + return GEOGRAPHY; default: return null; } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java new file mode 100644 index 000000000..384c0e95c --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java @@ -0,0 +1,275 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class VerifyClientVersionReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionReq"); + private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)1); + + public byte[] version; + public static final int VERSION = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.REQUIRED, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(VerifyClientVersionReq.class, metaDataMap); + } + + public VerifyClientVersionReq() { + this.version = "2.6.0".getBytes(); + + } + + public VerifyClientVersionReq( + byte[] version) { + this(); + this.version = version; + } + + public static class Builder { + private byte[] version; + + public Builder() { + } + + public Builder setVersion(final byte[] version) { + this.version = version; + return this; + } + + public VerifyClientVersionReq build() { + VerifyClientVersionReq result = new VerifyClientVersionReq(); + result.setVersion(this.version); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public VerifyClientVersionReq(VerifyClientVersionReq other) { + if (other.isSetVersion()) { + this.version = TBaseHelper.deepCopy(other.version); + } + } + + public VerifyClientVersionReq deepCopy() { + return new VerifyClientVersionReq(this); + } + + public byte[] getVersion() { + return this.version; + } + + public VerifyClientVersionReq setVersion(byte[] version) { + this.version = version; + return this; + } + + public void unsetVersion() { + this.version = null; + } + + // Returns true if field version is set (has been assigned a value) and false otherwise + public boolean isSetVersion() { + return this.version != null; + } + + public void setVersionIsSet(boolean __value) { + if (!__value) { + this.version = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case VERSION: + if (__value == null) { + unsetVersion(); + } else { + setVersion((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case VERSION: + return getVersion(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof VerifyClientVersionReq)) + return false; + VerifyClientVersionReq that = (VerifyClientVersionReq)_that; + + if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {version}); + } + + @Override + public int compareTo(VerifyClientVersionReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(version, other.version); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case VERSION: + if (__field.type == TType.STRING) { + this.version = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.version != null) { + oprot.writeFieldBegin(VERSION_FIELD_DESC); + oprot.writeBinary(this.version); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("VerifyClientVersionReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("version"); + sb.append(space); + sb.append(":").append(space); + if (this.getVersion() == null) { + sb.append("null"); + } else { + int __version_size = Math.min(this.getVersion().length, 128); + for (int i = 0; i < __version_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); + } + if (this.getVersion().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (version == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'version' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionResp.java b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionResp.java new file mode 100644 index 000000000..aec55d70f --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionResp.java @@ -0,0 +1,474 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class VerifyClientVersionResp implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionResp"); + private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); + private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); + private static final TField ERROR_MSG_FIELD_DESC = new TField("error_msg", TType.STRING, (short)3); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode code; + public com.vesoft.nebula.HostAddr leader; + public byte[] error_msg; + public static final int CODE = 1; + public static final int LEADER = 2; + public static final int ERROR_MSG = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(ERROR_MSG, new FieldMetaData("error_msg", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(VerifyClientVersionResp.class, metaDataMap); + } + + public VerifyClientVersionResp() { + } + + public VerifyClientVersionResp( + com.vesoft.nebula.ErrorCode code, + com.vesoft.nebula.HostAddr leader) { + this(); + this.code = code; + this.leader = leader; + } + + public VerifyClientVersionResp( + com.vesoft.nebula.ErrorCode code, + com.vesoft.nebula.HostAddr leader, + byte[] error_msg) { + this(); + this.code = code; + this.leader = leader; + this.error_msg = error_msg; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode code; + private com.vesoft.nebula.HostAddr leader; + private byte[] error_msg; + + public Builder() { + } + + public Builder setCode(final com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public Builder setError_msg(final byte[] error_msg) { + this.error_msg = error_msg; + return this; + } + + public VerifyClientVersionResp build() { + VerifyClientVersionResp result = new VerifyClientVersionResp(); + result.setCode(this.code); + result.setLeader(this.leader); + result.setError_msg(this.error_msg); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public VerifyClientVersionResp(VerifyClientVersionResp other) { + if (other.isSetCode()) { + this.code = TBaseHelper.deepCopy(other.code); + } + if (other.isSetLeader()) { + this.leader = TBaseHelper.deepCopy(other.leader); + } + if (other.isSetError_msg()) { + this.error_msg = TBaseHelper.deepCopy(other.error_msg); + } + } + + public VerifyClientVersionResp deepCopy() { + return new VerifyClientVersionResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getCode() { + return this.code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public VerifyClientVersionResp setCode(com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public void unsetCode() { + this.code = null; + } + + // Returns true if field code is set (has been assigned a value) and false otherwise + public boolean isSetCode() { + return this.code != null; + } + + public void setCodeIsSet(boolean __value) { + if (!__value) { + this.code = null; + } + } + + public com.vesoft.nebula.HostAddr getLeader() { + return this.leader; + } + + public VerifyClientVersionResp setLeader(com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public void unsetLeader() { + this.leader = null; + } + + // Returns true if field leader is set (has been assigned a value) and false otherwise + public boolean isSetLeader() { + return this.leader != null; + } + + public void setLeaderIsSet(boolean __value) { + if (!__value) { + this.leader = null; + } + } + + public byte[] getError_msg() { + return this.error_msg; + } + + public VerifyClientVersionResp setError_msg(byte[] error_msg) { + this.error_msg = error_msg; + return this; + } + + public void unsetError_msg() { + this.error_msg = null; + } + + // Returns true if field error_msg is set (has been assigned a value) and false otherwise + public boolean isSetError_msg() { + return this.error_msg != null; + } + + public void setError_msgIsSet(boolean __value) { + if (!__value) { + this.error_msg = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CODE: + if (__value == null) { + unsetCode(); + } else { + setCode((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case LEADER: + if (__value == null) { + unsetLeader(); + } else { + setLeader((com.vesoft.nebula.HostAddr)__value); + } + break; + + case ERROR_MSG: + if (__value == null) { + unsetError_msg(); + } else { + setError_msg((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CODE: + return getCode(); + + case LEADER: + return getLeader(); + + case ERROR_MSG: + return getError_msg(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof VerifyClientVersionResp)) + return false; + VerifyClientVersionResp that = (VerifyClientVersionResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetError_msg(), that.isSetError_msg(), this.error_msg, that.error_msg)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {code, leader, error_msg}); + } + + @Override + public int compareTo(VerifyClientVersionResp other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCode()).compareTo(other.isSetCode()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(code, other.code); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetLeader()).compareTo(other.isSetLeader()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(leader, other.leader); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetError_msg()).compareTo(other.isSetError_msg()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(error_msg, other.error_msg); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CODE: + if (__field.type == TType.I32) { + this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LEADER: + if (__field.type == TType.STRUCT) { + this.leader = new com.vesoft.nebula.HostAddr(); + this.leader.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ERROR_MSG: + if (__field.type == TType.STRING) { + this.error_msg = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.code != null) { + oprot.writeFieldBegin(CODE_FIELD_DESC); + oprot.writeI32(this.code == null ? 0 : this.code.getValue()); + oprot.writeFieldEnd(); + } + if (this.leader != null) { + oprot.writeFieldBegin(LEADER_FIELD_DESC); + this.leader.write(oprot); + oprot.writeFieldEnd(); + } + if (this.error_msg != null) { + if (isSetError_msg()) { + oprot.writeFieldBegin(ERROR_MSG_FIELD_DESC); + oprot.writeBinary(this.error_msg); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("VerifyClientVersionResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("code"); + sb.append(space); + sb.append(":").append(space); + if (this.getCode() == null) { + sb.append("null"); + } else { + String code_name = this.getCode() == null ? "null" : this.getCode().name(); + if (code_name != null) { + sb.append(code_name); + sb.append(" ("); + } + sb.append(this.getCode()); + if (code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("leader"); + sb.append(space); + sb.append(":").append(space); + if (this.getLeader() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); + } + first = false; + if (isSetError_msg()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("error_msg"); + sb.append(space); + sb.append(":").append(space); + if (this.getError_msg() == null) { + sb.append("null"); + } else { + int __error_msg_size = Math.min(this.getError_msg().length, 128); + for (int i = 0; i < __error_msg_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getError_msg()[i]).length() > 1 ? Integer.toHexString(this.getError_msg()[i]).substring(Integer.toHexString(this.getError_msg()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getError_msg()[i]).toUpperCase()); + } + if (this.getError_msg().length > 128) sb.append(" ..."); + } + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java new file mode 100644 index 000000000..60e78656c --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java @@ -0,0 +1,705 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ChainAddEdgesRequest implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ChainAddEdgesRequest"); + private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); + private static final TField PROP_NAMES_FIELD_DESC = new TField("prop_names", TType.LIST, (short)3); + private static final TField IF_NOT_EXISTS_FIELD_DESC = new TField("if_not_exists", TType.BOOL, (short)4); + private static final TField TERM_FIELD_DESC = new TField("term", TType.I64, (short)5); + private static final TField EDGE_VERSION_FIELD_DESC = new TField("edge_version", TType.I64, (short)6); + + public int space_id; + public Map> parts; + public List prop_names; + public boolean if_not_exists; + public long term; + public long edge_version; + public static final int SPACE_ID = 1; + public static final int PARTS = 2; + public static final int PROP_NAMES = 3; + public static final int IF_NOT_EXISTS = 4; + public static final int TERM = 5; + public static final int EDGE_VERSION = 6; + + // isset id assignments + private static final int __SPACE_ID_ISSET_ID = 0; + private static final int __IF_NOT_EXISTS_ISSET_ID = 1; + private static final int __TERM_ISSET_ID = 2; + private static final int __EDGE_VERSION_ISSET_ID = 3; + private BitSet __isset_bit_vector = new BitSet(4); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, NewEdge.class))))); + tmpMetaDataMap.put(PROP_NAMES, new FieldMetaData("prop_names", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.STRING)))); + tmpMetaDataMap.put(IF_NOT_EXISTS, new FieldMetaData("if_not_exists", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(TERM, new FieldMetaData("term", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(EDGE_VERSION, new FieldMetaData("edge_version", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I64))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ChainAddEdgesRequest.class, metaDataMap); + } + + public ChainAddEdgesRequest() { + } + + public ChainAddEdgesRequest( + int space_id, + Map> parts, + List prop_names, + boolean if_not_exists, + long term) { + this(); + this.space_id = space_id; + setSpace_idIsSet(true); + this.parts = parts; + this.prop_names = prop_names; + this.if_not_exists = if_not_exists; + setIf_not_existsIsSet(true); + this.term = term; + setTermIsSet(true); + } + + public ChainAddEdgesRequest( + int space_id, + Map> parts, + List prop_names, + boolean if_not_exists, + long term, + long edge_version) { + this(); + this.space_id = space_id; + setSpace_idIsSet(true); + this.parts = parts; + this.prop_names = prop_names; + this.if_not_exists = if_not_exists; + setIf_not_existsIsSet(true); + this.term = term; + setTermIsSet(true); + this.edge_version = edge_version; + setEdge_versionIsSet(true); + } + + public static class Builder { + private int space_id; + private Map> parts; + private List prop_names; + private boolean if_not_exists; + private long term; + private long edge_version; + + BitSet __optional_isset = new BitSet(4); + + public Builder() { + } + + public Builder setSpace_id(final int space_id) { + this.space_id = space_id; + __optional_isset.set(__SPACE_ID_ISSET_ID, true); + return this; + } + + public Builder setParts(final Map> parts) { + this.parts = parts; + return this; + } + + public Builder setProp_names(final List prop_names) { + this.prop_names = prop_names; + return this; + } + + public Builder setIf_not_exists(final boolean if_not_exists) { + this.if_not_exists = if_not_exists; + __optional_isset.set(__IF_NOT_EXISTS_ISSET_ID, true); + return this; + } + + public Builder setTerm(final long term) { + this.term = term; + __optional_isset.set(__TERM_ISSET_ID, true); + return this; + } + + public Builder setEdge_version(final long edge_version) { + this.edge_version = edge_version; + __optional_isset.set(__EDGE_VERSION_ISSET_ID, true); + return this; + } + + public ChainAddEdgesRequest build() { + ChainAddEdgesRequest result = new ChainAddEdgesRequest(); + if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { + result.setSpace_id(this.space_id); + } + result.setParts(this.parts); + result.setProp_names(this.prop_names); + if (__optional_isset.get(__IF_NOT_EXISTS_ISSET_ID)) { + result.setIf_not_exists(this.if_not_exists); + } + if (__optional_isset.get(__TERM_ISSET_ID)) { + result.setTerm(this.term); + } + if (__optional_isset.get(__EDGE_VERSION_ISSET_ID)) { + result.setEdge_version(this.edge_version); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ChainAddEdgesRequest(ChainAddEdgesRequest other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetParts()) { + this.parts = TBaseHelper.deepCopy(other.parts); + } + if (other.isSetProp_names()) { + this.prop_names = TBaseHelper.deepCopy(other.prop_names); + } + this.if_not_exists = TBaseHelper.deepCopy(other.if_not_exists); + this.term = TBaseHelper.deepCopy(other.term); + this.edge_version = TBaseHelper.deepCopy(other.edge_version); + } + + public ChainAddEdgesRequest deepCopy() { + return new ChainAddEdgesRequest(this); + } + + public int getSpace_id() { + return this.space_id; + } + + public ChainAddEdgesRequest setSpace_id(int space_id) { + this.space_id = space_id; + setSpace_idIsSet(true); + return this; + } + + public void unsetSpace_id() { + __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + } + + // Returns true if field space_id is set (has been assigned a value) and false otherwise + public boolean isSetSpace_id() { + return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + } + + public void setSpace_idIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + } + + public Map> getParts() { + return this.parts; + } + + public ChainAddEdgesRequest setParts(Map> parts) { + this.parts = parts; + return this; + } + + public void unsetParts() { + this.parts = null; + } + + // Returns true if field parts is set (has been assigned a value) and false otherwise + public boolean isSetParts() { + return this.parts != null; + } + + public void setPartsIsSet(boolean __value) { + if (!__value) { + this.parts = null; + } + } + + public List getProp_names() { + return this.prop_names; + } + + public ChainAddEdgesRequest setProp_names(List prop_names) { + this.prop_names = prop_names; + return this; + } + + public void unsetProp_names() { + this.prop_names = null; + } + + // Returns true if field prop_names is set (has been assigned a value) and false otherwise + public boolean isSetProp_names() { + return this.prop_names != null; + } + + public void setProp_namesIsSet(boolean __value) { + if (!__value) { + this.prop_names = null; + } + } + + public boolean isIf_not_exists() { + return this.if_not_exists; + } + + public ChainAddEdgesRequest setIf_not_exists(boolean if_not_exists) { + this.if_not_exists = if_not_exists; + setIf_not_existsIsSet(true); + return this; + } + + public void unsetIf_not_exists() { + __isset_bit_vector.clear(__IF_NOT_EXISTS_ISSET_ID); + } + + // Returns true if field if_not_exists is set (has been assigned a value) and false otherwise + public boolean isSetIf_not_exists() { + return __isset_bit_vector.get(__IF_NOT_EXISTS_ISSET_ID); + } + + public void setIf_not_existsIsSet(boolean __value) { + __isset_bit_vector.set(__IF_NOT_EXISTS_ISSET_ID, __value); + } + + public long getTerm() { + return this.term; + } + + public ChainAddEdgesRequest setTerm(long term) { + this.term = term; + setTermIsSet(true); + return this; + } + + public void unsetTerm() { + __isset_bit_vector.clear(__TERM_ISSET_ID); + } + + // Returns true if field term is set (has been assigned a value) and false otherwise + public boolean isSetTerm() { + return __isset_bit_vector.get(__TERM_ISSET_ID); + } + + public void setTermIsSet(boolean __value) { + __isset_bit_vector.set(__TERM_ISSET_ID, __value); + } + + public long getEdge_version() { + return this.edge_version; + } + + public ChainAddEdgesRequest setEdge_version(long edge_version) { + this.edge_version = edge_version; + setEdge_versionIsSet(true); + return this; + } + + public void unsetEdge_version() { + __isset_bit_vector.clear(__EDGE_VERSION_ISSET_ID); + } + + // Returns true if field edge_version is set (has been assigned a value) and false otherwise + public boolean isSetEdge_version() { + return __isset_bit_vector.get(__EDGE_VERSION_ISSET_ID); + } + + public void setEdge_versionIsSet(boolean __value) { + __isset_bit_vector.set(__EDGE_VERSION_ISSET_ID, __value); + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SPACE_ID: + if (__value == null) { + unsetSpace_id(); + } else { + setSpace_id((Integer)__value); + } + break; + + case PARTS: + if (__value == null) { + unsetParts(); + } else { + setParts((Map>)__value); + } + break; + + case PROP_NAMES: + if (__value == null) { + unsetProp_names(); + } else { + setProp_names((List)__value); + } + break; + + case IF_NOT_EXISTS: + if (__value == null) { + unsetIf_not_exists(); + } else { + setIf_not_exists((Boolean)__value); + } + break; + + case TERM: + if (__value == null) { + unsetTerm(); + } else { + setTerm((Long)__value); + } + break; + + case EDGE_VERSION: + if (__value == null) { + unsetEdge_version(); + } else { + setEdge_version((Long)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SPACE_ID: + return new Integer(getSpace_id()); + + case PARTS: + return getParts(); + + case PROP_NAMES: + return getProp_names(); + + case IF_NOT_EXISTS: + return new Boolean(isIf_not_exists()); + + case TERM: + return new Long(getTerm()); + + case EDGE_VERSION: + return new Long(getEdge_version()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ChainAddEdgesRequest)) + return false; + ChainAddEdgesRequest that = (ChainAddEdgesRequest)_that; + + if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetProp_names(), that.isSetProp_names(), this.prop_names, that.prop_names)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.if_not_exists, that.if_not_exists)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.term, that.term)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetEdge_version(), that.isSetEdge_version(), this.edge_version, that.edge_version)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {space_id, parts, prop_names, if_not_exists, term, edge_version}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SPACE_ID: + if (__field.type == TType.I32) { + this.space_id = iprot.readI32(); + setSpace_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARTS: + if (__field.type == TType.MAP) { + { + TMap _map268 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map268.size)); + for (int _i269 = 0; + (_map268.size < 0) ? iprot.peekMap() : (_i269 < _map268.size); + ++_i269) + { + int _key270; + List _val271; + _key270 = iprot.readI32(); + { + TList _list272 = iprot.readListBegin(); + _val271 = new ArrayList(Math.max(0, _list272.size)); + for (int _i273 = 0; + (_list272.size < 0) ? iprot.peekList() : (_i273 < _list272.size); + ++_i273) + { + NewEdge _elem274; + _elem274 = new NewEdge(); + _elem274.read(iprot); + _val271.add(_elem274); + } + iprot.readListEnd(); + } + this.parts.put(_key270, _val271); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PROP_NAMES: + if (__field.type == TType.LIST) { + { + TList _list275 = iprot.readListBegin(); + this.prop_names = new ArrayList(Math.max(0, _list275.size)); + for (int _i276 = 0; + (_list275.size < 0) ? iprot.peekList() : (_i276 < _list275.size); + ++_i276) + { + byte[] _elem277; + _elem277 = iprot.readBinary(); + this.prop_names.add(_elem277); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case IF_NOT_EXISTS: + if (__field.type == TType.BOOL) { + this.if_not_exists = iprot.readBool(); + setIf_not_existsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TERM: + if (__field.type == TType.I64) { + this.term = iprot.readI64(); + setTermIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case EDGE_VERSION: + if (__field.type == TType.I64) { + this.edge_version = iprot.readI64(); + setEdge_versionIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); + oprot.writeI32(this.space_id); + oprot.writeFieldEnd(); + if (this.parts != null) { + oprot.writeFieldBegin(PARTS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); + for (Map.Entry> _iter278 : this.parts.entrySet()) { + oprot.writeI32(_iter278.getKey()); + { + oprot.writeListBegin(new TList(TType.STRUCT, _iter278.getValue().size())); + for (NewEdge _iter279 : _iter278.getValue()) { + _iter279.write(oprot); + } + oprot.writeListEnd(); + } + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.prop_names != null) { + oprot.writeFieldBegin(PROP_NAMES_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRING, this.prop_names.size())); + for (byte[] _iter280 : this.prop_names) { + oprot.writeBinary(_iter280); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(IF_NOT_EXISTS_FIELD_DESC); + oprot.writeBool(this.if_not_exists); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(TERM_FIELD_DESC); + oprot.writeI64(this.term); + oprot.writeFieldEnd(); + if (isSetEdge_version()) { + oprot.writeFieldBegin(EDGE_VERSION_FIELD_DESC); + oprot.writeI64(this.edge_version); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ChainAddEdgesRequest"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("space_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("parts"); + sb.append(space); + sb.append(":").append(space); + if (this.getParts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParts(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("prop_names"); + sb.append(space); + sb.append(":").append(space); + if (this.getProp_names() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getProp_names(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("if_not_exists"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIf_not_exists(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("term"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTerm(), indent + 1, prettyPrint)); + first = false; + if (isSetEdge_version()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("edge_version"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getEdge_version(), indent + 1, prettyPrint)); + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java new file mode 100644 index 000000000..ef8fad589 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java @@ -0,0 +1,595 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ChainUpdateEdgeRequest implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ChainUpdateEdgeRequest"); + private static final TField UPDATE_EDGE_REQUEST_FIELD_DESC = new TField("update_edge_request", TType.STRUCT, (short)1); + private static final TField TERM_FIELD_DESC = new TField("term", TType.I64, (short)2); + private static final TField EDGE_VERSION_FIELD_DESC = new TField("edge_version", TType.I64, (short)3); + private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)4); + private static final TField PARTS_FIELD_DESC = new TField("parts", TType.LIST, (short)5); + + public UpdateEdgeRequest update_edge_request; + public long term; + public long edge_version; + public int space_id; + public List parts; + public static final int UPDATE_EDGE_REQUEST = 1; + public static final int TERM = 2; + public static final int EDGE_VERSION = 3; + public static final int SPACE_ID = 4; + public static final int PARTS = 5; + + // isset id assignments + private static final int __TERM_ISSET_ID = 0; + private static final int __EDGE_VERSION_ISSET_ID = 1; + private static final int __SPACE_ID_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(UPDATE_EDGE_REQUEST, new FieldMetaData("update_edge_request", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, UpdateEdgeRequest.class))); + tmpMetaDataMap.put(TERM, new FieldMetaData("term", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(EDGE_VERSION, new FieldMetaData("edge_version", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.REQUIRED, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.I32)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ChainUpdateEdgeRequest.class, metaDataMap); + } + + public ChainUpdateEdgeRequest() { + } + + public ChainUpdateEdgeRequest( + List parts) { + this(); + this.parts = parts; + } + + public ChainUpdateEdgeRequest( + UpdateEdgeRequest update_edge_request, + long term, + int space_id, + List parts) { + this(); + this.update_edge_request = update_edge_request; + this.term = term; + setTermIsSet(true); + this.space_id = space_id; + setSpace_idIsSet(true); + this.parts = parts; + } + + public ChainUpdateEdgeRequest( + UpdateEdgeRequest update_edge_request, + long term, + long edge_version, + int space_id, + List parts) { + this(); + this.update_edge_request = update_edge_request; + this.term = term; + setTermIsSet(true); + this.edge_version = edge_version; + setEdge_versionIsSet(true); + this.space_id = space_id; + setSpace_idIsSet(true); + this.parts = parts; + } + + public static class Builder { + private UpdateEdgeRequest update_edge_request; + private long term; + private long edge_version; + private int space_id; + private List parts; + + BitSet __optional_isset = new BitSet(3); + + public Builder() { + } + + public Builder setUpdate_edge_request(final UpdateEdgeRequest update_edge_request) { + this.update_edge_request = update_edge_request; + return this; + } + + public Builder setTerm(final long term) { + this.term = term; + __optional_isset.set(__TERM_ISSET_ID, true); + return this; + } + + public Builder setEdge_version(final long edge_version) { + this.edge_version = edge_version; + __optional_isset.set(__EDGE_VERSION_ISSET_ID, true); + return this; + } + + public Builder setSpace_id(final int space_id) { + this.space_id = space_id; + __optional_isset.set(__SPACE_ID_ISSET_ID, true); + return this; + } + + public Builder setParts(final List parts) { + this.parts = parts; + return this; + } + + public ChainUpdateEdgeRequest build() { + ChainUpdateEdgeRequest result = new ChainUpdateEdgeRequest(); + result.setUpdate_edge_request(this.update_edge_request); + if (__optional_isset.get(__TERM_ISSET_ID)) { + result.setTerm(this.term); + } + if (__optional_isset.get(__EDGE_VERSION_ISSET_ID)) { + result.setEdge_version(this.edge_version); + } + if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { + result.setSpace_id(this.space_id); + } + result.setParts(this.parts); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ChainUpdateEdgeRequest(ChainUpdateEdgeRequest other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + if (other.isSetUpdate_edge_request()) { + this.update_edge_request = TBaseHelper.deepCopy(other.update_edge_request); + } + this.term = TBaseHelper.deepCopy(other.term); + this.edge_version = TBaseHelper.deepCopy(other.edge_version); + this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetParts()) { + this.parts = TBaseHelper.deepCopy(other.parts); + } + } + + public ChainUpdateEdgeRequest deepCopy() { + return new ChainUpdateEdgeRequest(this); + } + + public UpdateEdgeRequest getUpdate_edge_request() { + return this.update_edge_request; + } + + public ChainUpdateEdgeRequest setUpdate_edge_request(UpdateEdgeRequest update_edge_request) { + this.update_edge_request = update_edge_request; + return this; + } + + public void unsetUpdate_edge_request() { + this.update_edge_request = null; + } + + // Returns true if field update_edge_request is set (has been assigned a value) and false otherwise + public boolean isSetUpdate_edge_request() { + return this.update_edge_request != null; + } + + public void setUpdate_edge_requestIsSet(boolean __value) { + if (!__value) { + this.update_edge_request = null; + } + } + + public long getTerm() { + return this.term; + } + + public ChainUpdateEdgeRequest setTerm(long term) { + this.term = term; + setTermIsSet(true); + return this; + } + + public void unsetTerm() { + __isset_bit_vector.clear(__TERM_ISSET_ID); + } + + // Returns true if field term is set (has been assigned a value) and false otherwise + public boolean isSetTerm() { + return __isset_bit_vector.get(__TERM_ISSET_ID); + } + + public void setTermIsSet(boolean __value) { + __isset_bit_vector.set(__TERM_ISSET_ID, __value); + } + + public long getEdge_version() { + return this.edge_version; + } + + public ChainUpdateEdgeRequest setEdge_version(long edge_version) { + this.edge_version = edge_version; + setEdge_versionIsSet(true); + return this; + } + + public void unsetEdge_version() { + __isset_bit_vector.clear(__EDGE_VERSION_ISSET_ID); + } + + // Returns true if field edge_version is set (has been assigned a value) and false otherwise + public boolean isSetEdge_version() { + return __isset_bit_vector.get(__EDGE_VERSION_ISSET_ID); + } + + public void setEdge_versionIsSet(boolean __value) { + __isset_bit_vector.set(__EDGE_VERSION_ISSET_ID, __value); + } + + public int getSpace_id() { + return this.space_id; + } + + public ChainUpdateEdgeRequest setSpace_id(int space_id) { + this.space_id = space_id; + setSpace_idIsSet(true); + return this; + } + + public void unsetSpace_id() { + __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + } + + // Returns true if field space_id is set (has been assigned a value) and false otherwise + public boolean isSetSpace_id() { + return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + } + + public void setSpace_idIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + } + + public List getParts() { + return this.parts; + } + + public ChainUpdateEdgeRequest setParts(List parts) { + this.parts = parts; + return this; + } + + public void unsetParts() { + this.parts = null; + } + + // Returns true if field parts is set (has been assigned a value) and false otherwise + public boolean isSetParts() { + return this.parts != null; + } + + public void setPartsIsSet(boolean __value) { + if (!__value) { + this.parts = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case UPDATE_EDGE_REQUEST: + if (__value == null) { + unsetUpdate_edge_request(); + } else { + setUpdate_edge_request((UpdateEdgeRequest)__value); + } + break; + + case TERM: + if (__value == null) { + unsetTerm(); + } else { + setTerm((Long)__value); + } + break; + + case EDGE_VERSION: + if (__value == null) { + unsetEdge_version(); + } else { + setEdge_version((Long)__value); + } + break; + + case SPACE_ID: + if (__value == null) { + unsetSpace_id(); + } else { + setSpace_id((Integer)__value); + } + break; + + case PARTS: + if (__value == null) { + unsetParts(); + } else { + setParts((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case UPDATE_EDGE_REQUEST: + return getUpdate_edge_request(); + + case TERM: + return new Long(getTerm()); + + case EDGE_VERSION: + return new Long(getEdge_version()); + + case SPACE_ID: + return new Integer(getSpace_id()); + + case PARTS: + return getParts(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ChainUpdateEdgeRequest)) + return false; + ChainUpdateEdgeRequest that = (ChainUpdateEdgeRequest)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetUpdate_edge_request(), that.isSetUpdate_edge_request(), this.update_edge_request, that.update_edge_request)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.term, that.term)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetEdge_version(), that.isSetEdge_version(), this.edge_version, that.edge_version)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {update_edge_request, term, edge_version, space_id, parts}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case UPDATE_EDGE_REQUEST: + if (__field.type == TType.STRUCT) { + this.update_edge_request = new UpdateEdgeRequest(); + this.update_edge_request.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TERM: + if (__field.type == TType.I64) { + this.term = iprot.readI64(); + setTermIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case EDGE_VERSION: + if (__field.type == TType.I64) { + this.edge_version = iprot.readI64(); + setEdge_versionIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SPACE_ID: + if (__field.type == TType.I32) { + this.space_id = iprot.readI32(); + setSpace_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARTS: + if (__field.type == TType.LIST) { + { + TList _list281 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list281.size)); + for (int _i282 = 0; + (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); + ++_i282) + { + int _elem283; + _elem283 = iprot.readI32(); + this.parts.add(_elem283); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.update_edge_request != null) { + oprot.writeFieldBegin(UPDATE_EDGE_REQUEST_FIELD_DESC); + this.update_edge_request.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(TERM_FIELD_DESC); + oprot.writeI64(this.term); + oprot.writeFieldEnd(); + if (isSetEdge_version()) { + oprot.writeFieldBegin(EDGE_VERSION_FIELD_DESC); + oprot.writeI64(this.edge_version); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); + oprot.writeI32(this.space_id); + oprot.writeFieldEnd(); + if (this.parts != null) { + oprot.writeFieldBegin(PARTS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.I32, this.parts.size())); + for (int _iter284 : this.parts) { + oprot.writeI32(_iter284); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ChainUpdateEdgeRequest"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("update_edge_request"); + sb.append(space); + sb.append(":").append(space); + if (this.getUpdate_edge_request() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getUpdate_edge_request(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("term"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTerm(), indent + 1, prettyPrint)); + first = false; + if (isSetEdge_version()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("edge_version"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getEdge_version(), indent + 1, prettyPrint)); + first = false; + } + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("space_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("parts"); + sb.append(space); + sb.append(":").append(space); + if (this.getParts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParts(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (parts == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'parts' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java index faea62896..351d4458e 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java @@ -231,17 +231,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void get(KVGetRequest req, AsyncMethodCallback resultHandler454) throws TException { + public void get(KVGetRequest req, AsyncMethodCallback resultHandler483) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler454, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler483, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private KVGetRequest req; - public get_call(KVGetRequest req, AsyncMethodCallback resultHandler455, TAsyncClient client451, TProtocolFactory protocolFactory452, TNonblockingTransport transport453) throws TException { - super(client451, protocolFactory452, transport453, resultHandler455, false); + public get_call(KVGetRequest req, AsyncMethodCallback resultHandler484, TAsyncClient client480, TProtocolFactory protocolFactory481, TNonblockingTransport transport482) throws TException { + super(client480, protocolFactory481, transport482, resultHandler484, false); this.req = req; } @@ -263,17 +263,17 @@ public KVGetResponse getResult() throws TException { } } - public void put(KVPutRequest req, AsyncMethodCallback resultHandler459) throws TException { + public void put(KVPutRequest req, AsyncMethodCallback resultHandler488) throws TException { checkReady(); - put_call method_call = new put_call(req, resultHandler459, this, ___protocolFactory, ___transport); + put_call method_call = new put_call(req, resultHandler488, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class put_call extends TAsyncMethodCall { private KVPutRequest req; - public put_call(KVPutRequest req, AsyncMethodCallback resultHandler460, TAsyncClient client456, TProtocolFactory protocolFactory457, TNonblockingTransport transport458) throws TException { - super(client456, protocolFactory457, transport458, resultHandler460, false); + public put_call(KVPutRequest req, AsyncMethodCallback resultHandler489, TAsyncClient client485, TProtocolFactory protocolFactory486, TNonblockingTransport transport487) throws TException { + super(client485, protocolFactory486, transport487, resultHandler489, false); this.req = req; } @@ -295,17 +295,17 @@ public ExecResponse getResult() throws TException { } } - public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler464) throws TException { + public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler493) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler464, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler493, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private KVRemoveRequest req; - public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler465, TAsyncClient client461, TProtocolFactory protocolFactory462, TNonblockingTransport transport463) throws TException { - super(client461, protocolFactory462, transport463, resultHandler465, false); + public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler494, TAsyncClient client490, TProtocolFactory protocolFactory491, TNonblockingTransport transport492) throws TException { + super(client490, protocolFactory491, transport492, resultHandler494, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java deleted file mode 100644 index 4712c0e7f..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java +++ /dev/null @@ -1,439 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetValueRequest implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetValueRequest"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)2); - private static final TField KEY_FIELD_DESC = new TField("key", TType.STRING, (short)3); - - public int space_id; - public int part_id; - public byte[] key; - public static final int SPACE_ID = 1; - public static final int PART_ID = 2; - public static final int KEY = 3; - - // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private static final int __PART_ID_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(KEY, new FieldMetaData("key", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetValueRequest.class, metaDataMap); - } - - public GetValueRequest() { - } - - public GetValueRequest( - int space_id, - int part_id, - byte[] key) { - this(); - this.space_id = space_id; - setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); - this.key = key; - } - - public static class Builder { - private int space_id; - private int part_id; - private byte[] key; - - BitSet __optional_isset = new BitSet(2); - - public Builder() { - } - - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); - return this; - } - - public Builder setPart_id(final int part_id) { - this.part_id = part_id; - __optional_isset.set(__PART_ID_ISSET_ID, true); - return this; - } - - public Builder setKey(final byte[] key) { - this.key = key; - return this; - } - - public GetValueRequest build() { - GetValueRequest result = new GetValueRequest(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } - if (__optional_isset.get(__PART_ID_ISSET_ID)) { - result.setPart_id(this.part_id); - } - result.setKey(this.key); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetValueRequest(GetValueRequest other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); - this.part_id = TBaseHelper.deepCopy(other.part_id); - if (other.isSetKey()) { - this.key = TBaseHelper.deepCopy(other.key); - } - } - - public GetValueRequest deepCopy() { - return new GetValueRequest(this); - } - - public int getSpace_id() { - return this.space_id; - } - - public GetValueRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); - return this; - } - - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); - } - - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); - } - - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); - } - - public int getPart_id() { - return this.part_id; - } - - public GetValueRequest setPart_id(int part_id) { - this.part_id = part_id; - setPart_idIsSet(true); - return this; - } - - public void unsetPart_id() { - __isset_bit_vector.clear(__PART_ID_ISSET_ID); - } - - // Returns true if field part_id is set (has been assigned a value) and false otherwise - public boolean isSetPart_id() { - return __isset_bit_vector.get(__PART_ID_ISSET_ID); - } - - public void setPart_idIsSet(boolean __value) { - __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); - } - - public byte[] getKey() { - return this.key; - } - - public GetValueRequest setKey(byte[] key) { - this.key = key; - return this; - } - - public void unsetKey() { - this.key = null; - } - - // Returns true if field key is set (has been assigned a value) and false otherwise - public boolean isSetKey() { - return this.key != null; - } - - public void setKeyIsSet(boolean __value) { - if (!__value) { - this.key = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SPACE_ID: - if (__value == null) { - unsetSpace_id(); - } else { - setSpace_id((Integer)__value); - } - break; - - case PART_ID: - if (__value == null) { - unsetPart_id(); - } else { - setPart_id((Integer)__value); - } - break; - - case KEY: - if (__value == null) { - unsetKey(); - } else { - setKey((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); - - case PART_ID: - return new Integer(getPart_id()); - - case KEY: - return getKey(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetValueRequest)) - return false; - GetValueRequest that = (GetValueRequest)_that; - - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetKey(), that.isSetKey(), this.key, that.key)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, part_id, key}); - } - - @Override - public int compareTo(GetValueRequest other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(part_id, other.part_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetKey()).compareTo(other.isSetKey()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(key, other.key); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case PART_ID: - if (__field.type == TType.I32) { - this.part_id = iprot.readI32(); - setPart_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case KEY: - if (__field.type == TType.STRING) { - this.key = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(PART_ID_FIELD_DESC); - oprot.writeI32(this.part_id); - oprot.writeFieldEnd(); - if (this.key != null) { - oprot.writeFieldBegin(KEY_FIELD_DESC); - oprot.writeBinary(this.key); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetValueRequest"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("space_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("part_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("key"); - sb.append(space); - sb.append(":").append(space); - if (this.getKey() == null) { - sb.append("null"); - } else { - int __key_size = Math.min(this.getKey().length, 128); - for (int i = 0; i < __key_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getKey()[i]).length() > 1 ? Integer.toHexString(this.getKey()[i]).substring(Integer.toHexString(this.getKey()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getKey()[i]).toUpperCase()); - } - if (this.getKey().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java deleted file mode 100644 index 8a0b704b8..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java +++ /dev/null @@ -1,365 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetValueResponse implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetValueResponse"); - private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); - private static final TField VALUE_FIELD_DESC = new TField("value", TType.STRING, (short)2); - - public ResponseCommon result; - public byte[] value; - public static final int RESULT = 1; - public static final int VALUE = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, - new StructMetaData(TType.STRUCT, ResponseCommon.class))); - tmpMetaDataMap.put(VALUE, new FieldMetaData("value", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetValueResponse.class, metaDataMap); - } - - public GetValueResponse() { - } - - public GetValueResponse( - ResponseCommon result) { - this(); - this.result = result; - } - - public GetValueResponse( - ResponseCommon result, - byte[] value) { - this(); - this.result = result; - this.value = value; - } - - public static class Builder { - private ResponseCommon result; - private byte[] value; - - public Builder() { - } - - public Builder setResult(final ResponseCommon result) { - this.result = result; - return this; - } - - public Builder setValue(final byte[] value) { - this.value = value; - return this; - } - - public GetValueResponse build() { - GetValueResponse result = new GetValueResponse(); - result.setResult(this.result); - result.setValue(this.value); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetValueResponse(GetValueResponse other) { - if (other.isSetResult()) { - this.result = TBaseHelper.deepCopy(other.result); - } - if (other.isSetValue()) { - this.value = TBaseHelper.deepCopy(other.value); - } - } - - public GetValueResponse deepCopy() { - return new GetValueResponse(this); - } - - public ResponseCommon getResult() { - return this.result; - } - - public GetValueResponse setResult(ResponseCommon result) { - this.result = result; - return this; - } - - public void unsetResult() { - this.result = null; - } - - // Returns true if field result is set (has been assigned a value) and false otherwise - public boolean isSetResult() { - return this.result != null; - } - - public void setResultIsSet(boolean __value) { - if (!__value) { - this.result = null; - } - } - - public byte[] getValue() { - return this.value; - } - - public GetValueResponse setValue(byte[] value) { - this.value = value; - return this; - } - - public void unsetValue() { - this.value = null; - } - - // Returns true if field value is set (has been assigned a value) and false otherwise - public boolean isSetValue() { - return this.value != null; - } - - public void setValueIsSet(boolean __value) { - if (!__value) { - this.value = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case RESULT: - if (__value == null) { - unsetResult(); - } else { - setResult((ResponseCommon)__value); - } - break; - - case VALUE: - if (__value == null) { - unsetValue(); - } else { - setValue((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case RESULT: - return getResult(); - - case VALUE: - return getValue(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetValueResponse)) - return false; - GetValueResponse that = (GetValueResponse)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetValue(), that.isSetValue(), this.value, that.value)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, value}); - } - - @Override - public int compareTo(GetValueResponse other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(result, other.result); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(value, other.value); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case RESULT: - if (__field.type == TType.STRUCT) { - this.result = new ResponseCommon(); - this.result.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case VALUE: - if (__field.type == TType.STRING) { - this.value = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.result != null) { - oprot.writeFieldBegin(RESULT_FIELD_DESC); - this.result.write(oprot); - oprot.writeFieldEnd(); - } - if (this.value != null) { - oprot.writeFieldBegin(VALUE_FIELD_DESC); - oprot.writeBinary(this.value); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetValueResponse"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("result"); - sb.append(space); - sb.append(":").append(space); - if (this.getResult() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("value"); - sb.append(space); - sb.append(":").append(space); - if (this.getValue() == null) { - sb.append("null"); - } else { - int __value_size = Math.min(this.getValue().length, 128); - for (int i = 0; i < __value_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getValue()[i]).length() > 1 ? Integer.toHexString(this.getValue()[i]).substring(Integer.toHexString(this.getValue()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getValue()[i]).toUpperCase()); - } - if (this.getValue().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - if (result == null) { - throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); - } - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java index 844249043..99ea338d6 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java @@ -59,7 +59,9 @@ public interface Iface { public GetNeighborsResponse lookupAndTraverse(LookupAndTraverseRequest req) throws TException; - public ExecResponse addEdgesAtomic(AddEdgesRequest req) throws TException; + public UpdateResponse chainUpdateEdge(UpdateEdgeRequest req) throws TException; + + public ExecResponse chainAddEdges(AddEdgesRequest req) throws TException; } @@ -93,7 +95,9 @@ public interface AsyncIface { public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler) throws TException; - public void addEdgesAtomic(AddEdgesRequest req, AsyncMethodCallback resultHandler) throws TException; + public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler) throws TException; + + public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler) throws TException; } @@ -756,49 +760,94 @@ public GetNeighborsResponse recv_lookupAndTraverse() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "lookupAndTraverse failed: unknown result"); } - public ExecResponse addEdgesAtomic(AddEdgesRequest req) throws TException + public UpdateResponse chainUpdateEdge(UpdateEdgeRequest req) throws TException { - ContextStack ctx = getContextStack("GraphStorageService.addEdgesAtomic", null); + ContextStack ctx = getContextStack("GraphStorageService.chainUpdateEdge", null); this.setContextStack(ctx); - send_addEdgesAtomic(req); - return recv_addEdgesAtomic(); + send_chainUpdateEdge(req); + return recv_chainUpdateEdge(); } - public void send_addEdgesAtomic(AddEdgesRequest req) throws TException + public void send_chainUpdateEdge(UpdateEdgeRequest req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "GraphStorageService.addEdgesAtomic", null); - oprot_.writeMessageBegin(new TMessage("addEdgesAtomic", TMessageType.CALL, seqid_)); - addEdgesAtomic_args args = new addEdgesAtomic_args(); + super.preWrite(ctx, "GraphStorageService.chainUpdateEdge", null); + oprot_.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.CALL, seqid_)); + chainUpdateEdge_args args = new chainUpdateEdge_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "GraphStorageService.addEdgesAtomic", args); + super.postWrite(ctx, "GraphStorageService.chainUpdateEdge", args); return; } - public ExecResponse recv_addEdgesAtomic() throws TException + public UpdateResponse recv_chainUpdateEdge() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "GraphStorageService.addEdgesAtomic"); + super.preRead(ctx, "GraphStorageService.chainUpdateEdge"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - addEdgesAtomic_result result = new addEdgesAtomic_result(); + chainUpdateEdge_result result = new chainUpdateEdge_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "GraphStorageService.addEdgesAtomic", result); + super.postRead(ctx, "GraphStorageService.chainUpdateEdge", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "addEdgesAtomic failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "chainUpdateEdge failed: unknown result"); + } + + public ExecResponse chainAddEdges(AddEdgesRequest req) throws TException + { + ContextStack ctx = getContextStack("GraphStorageService.chainAddEdges", null); + this.setContextStack(ctx); + send_chainAddEdges(req); + return recv_chainAddEdges(); + } + + public void send_chainAddEdges(AddEdgesRequest req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphStorageService.chainAddEdges", null); + oprot_.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.CALL, seqid_)); + chainAddEdges_args args = new chainAddEdges_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphStorageService.chainAddEdges", args); + return; + } + + public ExecResponse recv_chainAddEdges() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphStorageService.chainAddEdges"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + chainAddEdges_result result = new chainAddEdges_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphStorageService.chainAddEdges", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "chainAddEdges failed: unknown result"); } } @@ -819,17 +868,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler280) throws TException { + public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler304) throws TException { checkReady(); - getNeighbors_call method_call = new getNeighbors_call(req, resultHandler280, this, ___protocolFactory, ___transport); + getNeighbors_call method_call = new getNeighbors_call(req, resultHandler304, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getNeighbors_call extends TAsyncMethodCall { private GetNeighborsRequest req; - public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler281, TAsyncClient client277, TProtocolFactory protocolFactory278, TNonblockingTransport transport279) throws TException { - super(client277, protocolFactory278, transport279, resultHandler281, false); + public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler305, TAsyncClient client301, TProtocolFactory protocolFactory302, TNonblockingTransport transport303) throws TException { + super(client301, protocolFactory302, transport303, resultHandler305, false); this.req = req; } @@ -851,17 +900,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler285) throws TException { + public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler309) throws TException { checkReady(); - getProps_call method_call = new getProps_call(req, resultHandler285, this, ___protocolFactory, ___transport); + getProps_call method_call = new getProps_call(req, resultHandler309, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getProps_call extends TAsyncMethodCall { private GetPropRequest req; - public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler286, TAsyncClient client282, TProtocolFactory protocolFactory283, TNonblockingTransport transport284) throws TException { - super(client282, protocolFactory283, transport284, resultHandler286, false); + public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler310, TAsyncClient client306, TProtocolFactory protocolFactory307, TNonblockingTransport transport308) throws TException { + super(client306, protocolFactory307, transport308, resultHandler310, false); this.req = req; } @@ -883,17 +932,17 @@ public GetPropResponse getResult() throws TException { } } - public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler290) throws TException { + public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler314) throws TException { checkReady(); - addVertices_call method_call = new addVertices_call(req, resultHandler290, this, ___protocolFactory, ___transport); + addVertices_call method_call = new addVertices_call(req, resultHandler314, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addVertices_call extends TAsyncMethodCall { private AddVerticesRequest req; - public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler291, TAsyncClient client287, TProtocolFactory protocolFactory288, TNonblockingTransport transport289) throws TException { - super(client287, protocolFactory288, transport289, resultHandler291, false); + public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler315, TAsyncClient client311, TProtocolFactory protocolFactory312, TNonblockingTransport transport313) throws TException { + super(client311, protocolFactory312, transport313, resultHandler315, false); this.req = req; } @@ -915,17 +964,17 @@ public ExecResponse getResult() throws TException { } } - public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler295) throws TException { + public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler319) throws TException { checkReady(); - addEdges_call method_call = new addEdges_call(req, resultHandler295, this, ___protocolFactory, ___transport); + addEdges_call method_call = new addEdges_call(req, resultHandler319, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler296, TAsyncClient client292, TProtocolFactory protocolFactory293, TNonblockingTransport transport294) throws TException { - super(client292, protocolFactory293, transport294, resultHandler296, false); + public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler320, TAsyncClient client316, TProtocolFactory protocolFactory317, TNonblockingTransport transport318) throws TException { + super(client316, protocolFactory317, transport318, resultHandler320, false); this.req = req; } @@ -947,17 +996,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler300) throws TException { + public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler324) throws TException { checkReady(); - deleteEdges_call method_call = new deleteEdges_call(req, resultHandler300, this, ___protocolFactory, ___transport); + deleteEdges_call method_call = new deleteEdges_call(req, resultHandler324, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteEdges_call extends TAsyncMethodCall { private DeleteEdgesRequest req; - public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler301, TAsyncClient client297, TProtocolFactory protocolFactory298, TNonblockingTransport transport299) throws TException { - super(client297, protocolFactory298, transport299, resultHandler301, false); + public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler325, TAsyncClient client321, TProtocolFactory protocolFactory322, TNonblockingTransport transport323) throws TException { + super(client321, protocolFactory322, transport323, resultHandler325, false); this.req = req; } @@ -979,17 +1028,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler305) throws TException { + public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler329) throws TException { checkReady(); - deleteVertices_call method_call = new deleteVertices_call(req, resultHandler305, this, ___protocolFactory, ___transport); + deleteVertices_call method_call = new deleteVertices_call(req, resultHandler329, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteVertices_call extends TAsyncMethodCall { private DeleteVerticesRequest req; - public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler306, TAsyncClient client302, TProtocolFactory protocolFactory303, TNonblockingTransport transport304) throws TException { - super(client302, protocolFactory303, transport304, resultHandler306, false); + public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler330, TAsyncClient client326, TProtocolFactory protocolFactory327, TNonblockingTransport transport328) throws TException { + super(client326, protocolFactory327, transport328, resultHandler330, false); this.req = req; } @@ -1011,17 +1060,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler310) throws TException { + public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler334) throws TException { checkReady(); - deleteTags_call method_call = new deleteTags_call(req, resultHandler310, this, ___protocolFactory, ___transport); + deleteTags_call method_call = new deleteTags_call(req, resultHandler334, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteTags_call extends TAsyncMethodCall { private DeleteTagsRequest req; - public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler311, TAsyncClient client307, TProtocolFactory protocolFactory308, TNonblockingTransport transport309) throws TException { - super(client307, protocolFactory308, transport309, resultHandler311, false); + public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler335, TAsyncClient client331, TProtocolFactory protocolFactory332, TNonblockingTransport transport333) throws TException { + super(client331, protocolFactory332, transport333, resultHandler335, false); this.req = req; } @@ -1043,17 +1092,17 @@ public ExecResponse getResult() throws TException { } } - public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler315) throws TException { + public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler339) throws TException { checkReady(); - updateVertex_call method_call = new updateVertex_call(req, resultHandler315, this, ___protocolFactory, ___transport); + updateVertex_call method_call = new updateVertex_call(req, resultHandler339, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateVertex_call extends TAsyncMethodCall { private UpdateVertexRequest req; - public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler316, TAsyncClient client312, TProtocolFactory protocolFactory313, TNonblockingTransport transport314) throws TException { - super(client312, protocolFactory313, transport314, resultHandler316, false); + public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler340, TAsyncClient client336, TProtocolFactory protocolFactory337, TNonblockingTransport transport338) throws TException { + super(client336, protocolFactory337, transport338, resultHandler340, false); this.req = req; } @@ -1075,17 +1124,17 @@ public UpdateResponse getResult() throws TException { } } - public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler320) throws TException { + public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler344) throws TException { checkReady(); - updateEdge_call method_call = new updateEdge_call(req, resultHandler320, this, ___protocolFactory, ___transport); + updateEdge_call method_call = new updateEdge_call(req, resultHandler344, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler321, TAsyncClient client317, TProtocolFactory protocolFactory318, TNonblockingTransport transport319) throws TException { - super(client317, protocolFactory318, transport319, resultHandler321, false); + public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler345, TAsyncClient client341, TProtocolFactory protocolFactory342, TNonblockingTransport transport343) throws TException { + super(client341, protocolFactory342, transport343, resultHandler345, false); this.req = req; } @@ -1107,17 +1156,17 @@ public UpdateResponse getResult() throws TException { } } - public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler325) throws TException { + public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler349) throws TException { checkReady(); - scanVertex_call method_call = new scanVertex_call(req, resultHandler325, this, ___protocolFactory, ___transport); + scanVertex_call method_call = new scanVertex_call(req, resultHandler349, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanVertex_call extends TAsyncMethodCall { private ScanVertexRequest req; - public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler326, TAsyncClient client322, TProtocolFactory protocolFactory323, TNonblockingTransport transport324) throws TException { - super(client322, protocolFactory323, transport324, resultHandler326, false); + public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler350, TAsyncClient client346, TProtocolFactory protocolFactory347, TNonblockingTransport transport348) throws TException { + super(client346, protocolFactory347, transport348, resultHandler350, false); this.req = req; } @@ -1139,17 +1188,17 @@ public ScanVertexResponse getResult() throws TException { } } - public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler330) throws TException { + public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler354) throws TException { checkReady(); - scanEdge_call method_call = new scanEdge_call(req, resultHandler330, this, ___protocolFactory, ___transport); + scanEdge_call method_call = new scanEdge_call(req, resultHandler354, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanEdge_call extends TAsyncMethodCall { private ScanEdgeRequest req; - public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler331, TAsyncClient client327, TProtocolFactory protocolFactory328, TNonblockingTransport transport329) throws TException { - super(client327, protocolFactory328, transport329, resultHandler331, false); + public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler355, TAsyncClient client351, TProtocolFactory protocolFactory352, TNonblockingTransport transport353) throws TException { + super(client351, protocolFactory352, transport353, resultHandler355, false); this.req = req; } @@ -1171,17 +1220,17 @@ public ScanEdgeResponse getResult() throws TException { } } - public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler335) throws TException { + public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler359) throws TException { checkReady(); - getUUID_call method_call = new getUUID_call(req, resultHandler335, this, ___protocolFactory, ___transport); + getUUID_call method_call = new getUUID_call(req, resultHandler359, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUUID_call extends TAsyncMethodCall { private GetUUIDReq req; - public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler336, TAsyncClient client332, TProtocolFactory protocolFactory333, TNonblockingTransport transport334) throws TException { - super(client332, protocolFactory333, transport334, resultHandler336, false); + public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler360, TAsyncClient client356, TProtocolFactory protocolFactory357, TNonblockingTransport transport358) throws TException { + super(client356, protocolFactory357, transport358, resultHandler360, false); this.req = req; } @@ -1203,17 +1252,17 @@ public GetUUIDResp getResult() throws TException { } } - public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler340) throws TException { + public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler364) throws TException { checkReady(); - lookupIndex_call method_call = new lookupIndex_call(req, resultHandler340, this, ___protocolFactory, ___transport); + lookupIndex_call method_call = new lookupIndex_call(req, resultHandler364, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupIndex_call extends TAsyncMethodCall { private LookupIndexRequest req; - public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler341, TAsyncClient client337, TProtocolFactory protocolFactory338, TNonblockingTransport transport339) throws TException { - super(client337, protocolFactory338, transport339, resultHandler341, false); + public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler365, TAsyncClient client361, TProtocolFactory protocolFactory362, TNonblockingTransport transport363) throws TException { + super(client361, protocolFactory362, transport363, resultHandler365, false); this.req = req; } @@ -1235,17 +1284,17 @@ public LookupIndexResp getResult() throws TException { } } - public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler345) throws TException { + public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler369) throws TException { checkReady(); - lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler345, this, ___protocolFactory, ___transport); + lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler369, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupAndTraverse_call extends TAsyncMethodCall { private LookupAndTraverseRequest req; - public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler346, TAsyncClient client342, TProtocolFactory protocolFactory343, TNonblockingTransport transport344) throws TException { - super(client342, protocolFactory343, transport344, resultHandler346, false); + public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler370, TAsyncClient client366, TProtocolFactory protocolFactory367, TNonblockingTransport transport368) throws TException { + super(client366, protocolFactory367, transport368, resultHandler370, false); this.req = req; } @@ -1267,23 +1316,55 @@ public GetNeighborsResponse getResult() throws TException { } } - public void addEdgesAtomic(AddEdgesRequest req, AsyncMethodCallback resultHandler350) throws TException { + public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler374) throws TException { checkReady(); - addEdgesAtomic_call method_call = new addEdgesAtomic_call(req, resultHandler350, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler374, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class addEdgesAtomic_call extends TAsyncMethodCall { + public static class chainUpdateEdge_call extends TAsyncMethodCall { + private UpdateEdgeRequest req; + public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler375, TAsyncClient client371, TProtocolFactory protocolFactory372, TNonblockingTransport transport373) throws TException { + super(client371, protocolFactory372, transport373, resultHandler375, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.CALL, 0)); + chainUpdateEdge_args args = new chainUpdateEdge_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public UpdateResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_chainUpdateEdge(); + } + } + + public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler379) throws TException { + checkReady(); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler379, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class chainAddEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public addEdgesAtomic_call(AddEdgesRequest req, AsyncMethodCallback resultHandler351, TAsyncClient client347, TProtocolFactory protocolFactory348, TNonblockingTransport transport349) throws TException { - super(client347, protocolFactory348, transport349, resultHandler351, false); + public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler380, TAsyncClient client376, TProtocolFactory protocolFactory377, TNonblockingTransport transport378) throws TException { + super(client376, protocolFactory377, transport378, resultHandler380, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("addEdgesAtomic", TMessageType.CALL, 0)); - addEdgesAtomic_args args = new addEdgesAtomic_args(); + prot.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.CALL, 0)); + chainAddEdges_args args = new chainAddEdges_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); @@ -1295,7 +1376,7 @@ public ExecResponse getResult() throws TException { } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_addEdgesAtomic(); + return (new Client(prot)).recv_chainAddEdges(); } } @@ -1321,7 +1402,8 @@ public Processor(Iface iface) processMap_.put("getUUID", new getUUID()); processMap_.put("lookupIndex", new lookupIndex()); processMap_.put("lookupAndTraverse", new lookupAndTraverse()); - processMap_.put("addEdgesAtomic", new addEdgesAtomic()); + processMap_.put("chainUpdateEdge", new chainUpdateEdge()); + processMap_.put("chainAddEdges", new chainAddEdges()); } protected static interface ProcessFunction { @@ -1648,23 +1730,44 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class addEdgesAtomic implements ProcessFunction { + private class chainUpdateEdge implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphStorageService.chainUpdateEdge", server_ctx); + chainUpdateEdge_args args = new chainUpdateEdge_args(); + event_handler_.preRead(handler_ctx, "GraphStorageService.chainUpdateEdge"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphStorageService.chainUpdateEdge", args); + chainUpdateEdge_result result = new chainUpdateEdge_result(); + result.success = iface_.chainUpdateEdge(args.req); + event_handler_.preWrite(handler_ctx, "GraphStorageService.chainUpdateEdge", result); + oprot.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphStorageService.chainUpdateEdge", result); + } + + } + + private class chainAddEdges implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("GraphStorageService.addEdgesAtomic", server_ctx); - addEdgesAtomic_args args = new addEdgesAtomic_args(); - event_handler_.preRead(handler_ctx, "GraphStorageService.addEdgesAtomic"); + Object handler_ctx = event_handler_.getContext("GraphStorageService.chainAddEdges", server_ctx); + chainAddEdges_args args = new chainAddEdges_args(); + event_handler_.preRead(handler_ctx, "GraphStorageService.chainAddEdges"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "GraphStorageService.addEdgesAtomic", args); - addEdgesAtomic_result result = new addEdgesAtomic_result(); - result.success = iface_.addEdgesAtomic(args.req); - event_handler_.preWrite(handler_ctx, "GraphStorageService.addEdgesAtomic", result); - oprot.writeMessageBegin(new TMessage("addEdgesAtomic", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "GraphStorageService.chainAddEdges", args); + chainAddEdges_result result = new chainAddEdges_result(); + result.success = iface_.chainAddEdges(args.req); + event_handler_.preWrite(handler_ctx, "GraphStorageService.chainAddEdges", result); + oprot.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "GraphStorageService.addEdgesAtomic", result); + event_handler_.postWrite(handler_ctx, "GraphStorageService.chainAddEdges", result); } } @@ -7301,8 +7404,397 @@ public void validate() throws TException { } - public static class addEdgesAtomic_args implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("addEdgesAtomic_args"); + public static class chainUpdateEdge_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainUpdateEdge_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public UpdateEdgeRequest req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, UpdateEdgeRequest.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(chainUpdateEdge_args.class, metaDataMap); + } + + public chainUpdateEdge_args() { + } + + public chainUpdateEdge_args( + UpdateEdgeRequest req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public chainUpdateEdge_args(chainUpdateEdge_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public chainUpdateEdge_args deepCopy() { + return new chainUpdateEdge_args(this); + } + + public UpdateEdgeRequest getReq() { + return this.req; + } + + public chainUpdateEdge_args setReq(UpdateEdgeRequest req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((UpdateEdgeRequest)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof chainUpdateEdge_args)) + return false; + chainUpdateEdge_args that = (chainUpdateEdge_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new UpdateEdgeRequest(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("chainUpdateEdge_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class chainUpdateEdge_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainUpdateEdge_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public UpdateResponse success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, UpdateResponse.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(chainUpdateEdge_result.class, metaDataMap); + } + + public chainUpdateEdge_result() { + } + + public chainUpdateEdge_result( + UpdateResponse success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public chainUpdateEdge_result(chainUpdateEdge_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public chainUpdateEdge_result deepCopy() { + return new chainUpdateEdge_result(this); + } + + public UpdateResponse getSuccess() { + return this.success; + } + + public chainUpdateEdge_result setSuccess(UpdateResponse success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((UpdateResponse)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof chainUpdateEdge_result)) + return false; + chainUpdateEdge_result that = (chainUpdateEdge_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new UpdateResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("chainUpdateEdge_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class chainAddEdges_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainAddEdges_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); public AddEdgesRequest req; @@ -7320,13 +7812,13 @@ public static class addEdgesAtomic_args implements TBase, java.io.Serializable, } static { - FieldMetaData.addStructMetaDataMap(addEdgesAtomic_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainAddEdges_args.class, metaDataMap); } - public addEdgesAtomic_args() { + public chainAddEdges_args() { } - public addEdgesAtomic_args( + public chainAddEdges_args( AddEdgesRequest req) { this(); this.req = req; @@ -7335,21 +7827,21 @@ public addEdgesAtomic_args( /** * Performs a deep copy on other. */ - public addEdgesAtomic_args(addEdgesAtomic_args other) { + public chainAddEdges_args(chainAddEdges_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addEdgesAtomic_args deepCopy() { - return new addEdgesAtomic_args(this); + public chainAddEdges_args deepCopy() { + return new chainAddEdges_args(this); } public AddEdgesRequest getReq() { return this.req; } - public addEdgesAtomic_args setReq(AddEdgesRequest req) { + public chainAddEdges_args setReq(AddEdgesRequest req) { this.req = req; return this; } @@ -7400,9 +7892,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addEdgesAtomic_args)) + if (!(_that instanceof chainAddEdges_args)) return false; - addEdgesAtomic_args that = (addEdgesAtomic_args)_that; + chainAddEdges_args that = (chainAddEdges_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -7469,7 +7961,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addEdgesAtomic_args"); + StringBuilder sb = new StringBuilder("chainAddEdges_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -7496,8 +7988,8 @@ public void validate() throws TException { } - public static class addEdgesAtomic_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addEdgesAtomic_result"); + public static class chainAddEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("chainAddEdges_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResponse success; @@ -7515,13 +8007,13 @@ public static class addEdgesAtomic_result implements TBase, java.io.Serializable } static { - FieldMetaData.addStructMetaDataMap(addEdgesAtomic_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainAddEdges_result.class, metaDataMap); } - public addEdgesAtomic_result() { + public chainAddEdges_result() { } - public addEdgesAtomic_result( + public chainAddEdges_result( ExecResponse success) { this(); this.success = success; @@ -7530,21 +8022,21 @@ public addEdgesAtomic_result( /** * Performs a deep copy on other. */ - public addEdgesAtomic_result(addEdgesAtomic_result other) { + public chainAddEdges_result(chainAddEdges_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addEdgesAtomic_result deepCopy() { - return new addEdgesAtomic_result(this); + public chainAddEdges_result deepCopy() { + return new chainAddEdges_result(this); } public ExecResponse getSuccess() { return this.success; } - public addEdgesAtomic_result setSuccess(ExecResponse success) { + public chainAddEdges_result setSuccess(ExecResponse success) { this.success = success; return this; } @@ -7595,9 +8087,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addEdgesAtomic_result)) + if (!(_that instanceof chainAddEdges_result)) return false; - addEdgesAtomic_result that = (addEdgesAtomic_result)_that; + chainAddEdges_result that = (chainAddEdges_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -7610,7 +8102,7 @@ public int hashCode() { } @Override - public int compareTo(addEdgesAtomic_result other) { + public int compareTo(chainAddEdges_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -7686,7 +8178,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addEdgesAtomic_result"); + StringBuilder sb = new StringBuilder("chainAddEdges_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java index 0b7b04369..dc8f229b4 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java @@ -31,17 +31,17 @@ public class InternalStorageService { public interface Iface { - public GetValueResponse getValue(GetValueRequest req) throws TException; + public ExecResponse chainAddEdges(ChainAddEdgesRequest req) throws TException; - public ExecResponse forwardTransaction(InternalTxnRequest req) throws TException; + public UpdateResponse chainUpdateEdge(ChainUpdateEdgeRequest req) throws TException; } public interface AsyncIface { - public void getValue(GetValueRequest req, AsyncMethodCallback resultHandler) throws TException; + public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler) throws TException; - public void forwardTransaction(InternalTxnRequest req, AsyncMethodCallback resultHandler) throws TException; + public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler) throws TException; } @@ -74,94 +74,94 @@ public TProtocol getOutputProtocol() return this.oprot_; } - public GetValueResponse getValue(GetValueRequest req) throws TException + public ExecResponse chainAddEdges(ChainAddEdgesRequest req) throws TException { - ContextStack ctx = getContextStack("InternalStorageService.getValue", null); + ContextStack ctx = getContextStack("InternalStorageService.chainAddEdges", null); this.setContextStack(ctx); - send_getValue(req); - return recv_getValue(); + send_chainAddEdges(req); + return recv_chainAddEdges(); } - public void send_getValue(GetValueRequest req) throws TException + public void send_chainAddEdges(ChainAddEdgesRequest req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "InternalStorageService.getValue", null); - oprot_.writeMessageBegin(new TMessage("getValue", TMessageType.CALL, seqid_)); - getValue_args args = new getValue_args(); + super.preWrite(ctx, "InternalStorageService.chainAddEdges", null); + oprot_.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.CALL, seqid_)); + chainAddEdges_args args = new chainAddEdges_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "InternalStorageService.getValue", args); + super.postWrite(ctx, "InternalStorageService.chainAddEdges", args); return; } - public GetValueResponse recv_getValue() throws TException + public ExecResponse recv_chainAddEdges() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "InternalStorageService.getValue"); + super.preRead(ctx, "InternalStorageService.chainAddEdges"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - getValue_result result = new getValue_result(); + chainAddEdges_result result = new chainAddEdges_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "InternalStorageService.getValue", result); + super.postRead(ctx, "InternalStorageService.chainAddEdges", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "getValue failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "chainAddEdges failed: unknown result"); } - public ExecResponse forwardTransaction(InternalTxnRequest req) throws TException + public UpdateResponse chainUpdateEdge(ChainUpdateEdgeRequest req) throws TException { - ContextStack ctx = getContextStack("InternalStorageService.forwardTransaction", null); + ContextStack ctx = getContextStack("InternalStorageService.chainUpdateEdge", null); this.setContextStack(ctx); - send_forwardTransaction(req); - return recv_forwardTransaction(); + send_chainUpdateEdge(req); + return recv_chainUpdateEdge(); } - public void send_forwardTransaction(InternalTxnRequest req) throws TException + public void send_chainUpdateEdge(ChainUpdateEdgeRequest req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "InternalStorageService.forwardTransaction", null); - oprot_.writeMessageBegin(new TMessage("forwardTransaction", TMessageType.CALL, seqid_)); - forwardTransaction_args args = new forwardTransaction_args(); + super.preWrite(ctx, "InternalStorageService.chainUpdateEdge", null); + oprot_.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.CALL, seqid_)); + chainUpdateEdge_args args = new chainUpdateEdge_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "InternalStorageService.forwardTransaction", args); + super.postWrite(ctx, "InternalStorageService.chainUpdateEdge", args); return; } - public ExecResponse recv_forwardTransaction() throws TException + public UpdateResponse recv_chainUpdateEdge() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "InternalStorageService.forwardTransaction"); + super.preRead(ctx, "InternalStorageService.chainUpdateEdge"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - forwardTransaction_result result = new forwardTransaction_result(); + chainUpdateEdge_result result = new chainUpdateEdge_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "InternalStorageService.forwardTransaction", result); + super.postRead(ctx, "InternalStorageService.chainUpdateEdge", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "forwardTransaction failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "chainUpdateEdge failed: unknown result"); } } @@ -182,67 +182,67 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void getValue(GetValueRequest req, AsyncMethodCallback resultHandler471) throws TException { + public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler500) throws TException { checkReady(); - getValue_call method_call = new getValue_call(req, resultHandler471, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler500, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class getValue_call extends TAsyncMethodCall { - private GetValueRequest req; - public getValue_call(GetValueRequest req, AsyncMethodCallback resultHandler472, TAsyncClient client468, TProtocolFactory protocolFactory469, TNonblockingTransport transport470) throws TException { - super(client468, protocolFactory469, transport470, resultHandler472, false); + public static class chainAddEdges_call extends TAsyncMethodCall { + private ChainAddEdgesRequest req; + public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler501, TAsyncClient client497, TProtocolFactory protocolFactory498, TNonblockingTransport transport499) throws TException { + super(client497, protocolFactory498, transport499, resultHandler501, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("getValue", TMessageType.CALL, 0)); - getValue_args args = new getValue_args(); + prot.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.CALL, 0)); + chainAddEdges_args args = new chainAddEdges_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); } - public GetValueResponse getResult() throws TException { + public ExecResponse getResult() throws TException { if (getState() != State.RESPONSE_READ) { throw new IllegalStateException("Method call not finished!"); } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_getValue(); + return (new Client(prot)).recv_chainAddEdges(); } } - public void forwardTransaction(InternalTxnRequest req, AsyncMethodCallback resultHandler476) throws TException { + public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler505) throws TException { checkReady(); - forwardTransaction_call method_call = new forwardTransaction_call(req, resultHandler476, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler505, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class forwardTransaction_call extends TAsyncMethodCall { - private InternalTxnRequest req; - public forwardTransaction_call(InternalTxnRequest req, AsyncMethodCallback resultHandler477, TAsyncClient client473, TProtocolFactory protocolFactory474, TNonblockingTransport transport475) throws TException { - super(client473, protocolFactory474, transport475, resultHandler477, false); + public static class chainUpdateEdge_call extends TAsyncMethodCall { + private ChainUpdateEdgeRequest req; + public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler506, TAsyncClient client502, TProtocolFactory protocolFactory503, TNonblockingTransport transport504) throws TException { + super(client502, protocolFactory503, transport504, resultHandler506, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("forwardTransaction", TMessageType.CALL, 0)); - forwardTransaction_args args = new forwardTransaction_args(); + prot.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.CALL, 0)); + chainUpdateEdge_args args = new chainUpdateEdge_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); } - public ExecResponse getResult() throws TException { + public UpdateResponse getResult() throws TException { if (getState() != State.RESPONSE_READ) { throw new IllegalStateException("Method call not finished!"); } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_forwardTransaction(); + return (new Client(prot)).recv_chainUpdateEdge(); } } @@ -254,8 +254,8 @@ public Processor(Iface iface) { iface_ = iface; event_handler_ = new TProcessorEventHandler(); // Empty handler - processMap_.put("getValue", new getValue()); - processMap_.put("forwardTransaction", new forwardTransaction()); + processMap_.put("chainAddEdges", new chainAddEdges()); + processMap_.put("chainUpdateEdge", new chainUpdateEdge()); } protected static interface ProcessFunction { @@ -288,55 +288,55 @@ public boolean process(TProtocol iprot, TProtocol oprot, TConnectionContext serv return true; } - private class getValue implements ProcessFunction { + private class chainAddEdges implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("InternalStorageService.getValue", server_ctx); - getValue_args args = new getValue_args(); - event_handler_.preRead(handler_ctx, "InternalStorageService.getValue"); + Object handler_ctx = event_handler_.getContext("InternalStorageService.chainAddEdges", server_ctx); + chainAddEdges_args args = new chainAddEdges_args(); + event_handler_.preRead(handler_ctx, "InternalStorageService.chainAddEdges"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "InternalStorageService.getValue", args); - getValue_result result = new getValue_result(); - result.success = iface_.getValue(args.req); - event_handler_.preWrite(handler_ctx, "InternalStorageService.getValue", result); - oprot.writeMessageBegin(new TMessage("getValue", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "InternalStorageService.chainAddEdges", args); + chainAddEdges_result result = new chainAddEdges_result(); + result.success = iface_.chainAddEdges(args.req); + event_handler_.preWrite(handler_ctx, "InternalStorageService.chainAddEdges", result); + oprot.writeMessageBegin(new TMessage("chainAddEdges", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "InternalStorageService.getValue", result); + event_handler_.postWrite(handler_ctx, "InternalStorageService.chainAddEdges", result); } } - private class forwardTransaction implements ProcessFunction { + private class chainUpdateEdge implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("InternalStorageService.forwardTransaction", server_ctx); - forwardTransaction_args args = new forwardTransaction_args(); - event_handler_.preRead(handler_ctx, "InternalStorageService.forwardTransaction"); + Object handler_ctx = event_handler_.getContext("InternalStorageService.chainUpdateEdge", server_ctx); + chainUpdateEdge_args args = new chainUpdateEdge_args(); + event_handler_.preRead(handler_ctx, "InternalStorageService.chainUpdateEdge"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "InternalStorageService.forwardTransaction", args); - forwardTransaction_result result = new forwardTransaction_result(); - result.success = iface_.forwardTransaction(args.req); - event_handler_.preWrite(handler_ctx, "InternalStorageService.forwardTransaction", result); - oprot.writeMessageBegin(new TMessage("forwardTransaction", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "InternalStorageService.chainUpdateEdge", args); + chainUpdateEdge_result result = new chainUpdateEdge_result(); + result.success = iface_.chainUpdateEdge(args.req); + event_handler_.preWrite(handler_ctx, "InternalStorageService.chainUpdateEdge", result); + oprot.writeMessageBegin(new TMessage("chainUpdateEdge", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "InternalStorageService.forwardTransaction", result); + event_handler_.postWrite(handler_ctx, "InternalStorageService.chainUpdateEdge", result); } } } - public static class getValue_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getValue_args"); + public static class chainAddEdges_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainAddEdges_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetValueRequest req; + public ChainAddEdgesRequest req; public static final int REQ = 1; // isset id assignments @@ -346,19 +346,19 @@ public static class getValue_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetValueRequest.class))); + new StructMetaData(TType.STRUCT, ChainAddEdgesRequest.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getValue_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainAddEdges_args.class, metaDataMap); } - public getValue_args() { + public chainAddEdges_args() { } - public getValue_args( - GetValueRequest req) { + public chainAddEdges_args( + ChainAddEdgesRequest req) { this(); this.req = req; } @@ -366,21 +366,21 @@ public getValue_args( /** * Performs a deep copy on other. */ - public getValue_args(getValue_args other) { + public chainAddEdges_args(chainAddEdges_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getValue_args deepCopy() { - return new getValue_args(this); + public chainAddEdges_args deepCopy() { + return new chainAddEdges_args(this); } - public GetValueRequest getReq() { + public ChainAddEdgesRequest getReq() { return this.req; } - public getValue_args setReq(GetValueRequest req) { + public chainAddEdges_args setReq(ChainAddEdgesRequest req) { this.req = req; return this; } @@ -406,7 +406,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetValueRequest)__value); + setReq((ChainAddEdgesRequest)__value); } break; @@ -431,9 +431,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getValue_args)) + if (!(_that instanceof chainAddEdges_args)) return false; - getValue_args that = (getValue_args)_that; + chainAddEdges_args that = (chainAddEdges_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -445,29 +445,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } - @Override - public int compareTo(getValue_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -481,7 +458,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetValueRequest(); + this.req = new ChainAddEdgesRequest(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -523,7 +500,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getValue_args"); + StringBuilder sb = new StringBuilder("chainAddEdges_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -550,11 +527,11 @@ public void validate() throws TException { } - public static class getValue_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getValue_result"); + public static class chainAddEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("chainAddEdges_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetValueResponse success; + public ExecResponse success; public static final int SUCCESS = 0; // isset id assignments @@ -564,19 +541,19 @@ public static class getValue_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetValueResponse.class))); + new StructMetaData(TType.STRUCT, ExecResponse.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getValue_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainAddEdges_result.class, metaDataMap); } - public getValue_result() { + public chainAddEdges_result() { } - public getValue_result( - GetValueResponse success) { + public chainAddEdges_result( + ExecResponse success) { this(); this.success = success; } @@ -584,21 +561,21 @@ public getValue_result( /** * Performs a deep copy on other. */ - public getValue_result(getValue_result other) { + public chainAddEdges_result(chainAddEdges_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getValue_result deepCopy() { - return new getValue_result(this); + public chainAddEdges_result deepCopy() { + return new chainAddEdges_result(this); } - public GetValueResponse getSuccess() { + public ExecResponse getSuccess() { return this.success; } - public getValue_result setSuccess(GetValueResponse success) { + public chainAddEdges_result setSuccess(ExecResponse success) { this.success = success; return this; } @@ -624,7 +601,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetValueResponse)__value); + setSuccess((ExecResponse)__value); } break; @@ -649,9 +626,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getValue_result)) + if (!(_that instanceof chainAddEdges_result)) return false; - getValue_result that = (getValue_result)_that; + chainAddEdges_result that = (chainAddEdges_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -664,7 +641,7 @@ public int hashCode() { } @Override - public int compareTo(getValue_result other) { + public int compareTo(chainAddEdges_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -699,7 +676,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetValueResponse(); + this.success = new ExecResponse(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -740,7 +717,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getValue_result"); + StringBuilder sb = new StringBuilder("chainAddEdges_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -767,11 +744,11 @@ public void validate() throws TException { } - public static class forwardTransaction_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("forwardTransaction_args"); + public static class chainUpdateEdge_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainUpdateEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public InternalTxnRequest req; + public ChainUpdateEdgeRequest req; public static final int REQ = 1; // isset id assignments @@ -781,19 +758,19 @@ public static class forwardTransaction_args implements TBase, java.io.Serializab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, InternalTxnRequest.class))); + new StructMetaData(TType.STRUCT, ChainUpdateEdgeRequest.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(forwardTransaction_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainUpdateEdge_args.class, metaDataMap); } - public forwardTransaction_args() { + public chainUpdateEdge_args() { } - public forwardTransaction_args( - InternalTxnRequest req) { + public chainUpdateEdge_args( + ChainUpdateEdgeRequest req) { this(); this.req = req; } @@ -801,21 +778,21 @@ public forwardTransaction_args( /** * Performs a deep copy on other. */ - public forwardTransaction_args(forwardTransaction_args other) { + public chainUpdateEdge_args(chainUpdateEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public forwardTransaction_args deepCopy() { - return new forwardTransaction_args(this); + public chainUpdateEdge_args deepCopy() { + return new chainUpdateEdge_args(this); } - public InternalTxnRequest getReq() { + public ChainUpdateEdgeRequest getReq() { return this.req; } - public forwardTransaction_args setReq(InternalTxnRequest req) { + public chainUpdateEdge_args setReq(ChainUpdateEdgeRequest req) { this.req = req; return this; } @@ -841,7 +818,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((InternalTxnRequest)__value); + setReq((ChainUpdateEdgeRequest)__value); } break; @@ -866,9 +843,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof forwardTransaction_args)) + if (!(_that instanceof chainUpdateEdge_args)) return false; - forwardTransaction_args that = (forwardTransaction_args)_that; + chainUpdateEdge_args that = (chainUpdateEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -880,29 +857,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } - @Override - public int compareTo(forwardTransaction_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -916,7 +870,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new InternalTxnRequest(); + this.req = new ChainUpdateEdgeRequest(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -958,7 +912,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("forwardTransaction_args"); + StringBuilder sb = new StringBuilder("chainUpdateEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -985,11 +939,11 @@ public void validate() throws TException { } - public static class forwardTransaction_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("forwardTransaction_result"); + public static class chainUpdateEdge_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("chainUpdateEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResponse success; + public UpdateResponse success; public static final int SUCCESS = 0; // isset id assignments @@ -999,19 +953,19 @@ public static class forwardTransaction_result implements TBase, java.io.Serializ static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResponse.class))); + new StructMetaData(TType.STRUCT, UpdateResponse.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(forwardTransaction_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(chainUpdateEdge_result.class, metaDataMap); } - public forwardTransaction_result() { + public chainUpdateEdge_result() { } - public forwardTransaction_result( - ExecResponse success) { + public chainUpdateEdge_result( + UpdateResponse success) { this(); this.success = success; } @@ -1019,21 +973,21 @@ public forwardTransaction_result( /** * Performs a deep copy on other. */ - public forwardTransaction_result(forwardTransaction_result other) { + public chainUpdateEdge_result(chainUpdateEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public forwardTransaction_result deepCopy() { - return new forwardTransaction_result(this); + public chainUpdateEdge_result deepCopy() { + return new chainUpdateEdge_result(this); } - public ExecResponse getSuccess() { + public UpdateResponse getSuccess() { return this.success; } - public forwardTransaction_result setSuccess(ExecResponse success) { + public chainUpdateEdge_result setSuccess(UpdateResponse success) { this.success = success; return this; } @@ -1059,7 +1013,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResponse)__value); + setSuccess((UpdateResponse)__value); } break; @@ -1084,9 +1038,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof forwardTransaction_result)) + if (!(_that instanceof chainUpdateEdge_result)) return false; - forwardTransaction_result that = (forwardTransaction_result)_that; + chainUpdateEdge_result that = (chainUpdateEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -1098,29 +1052,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } - @Override - public int compareTo(forwardTransaction_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -1134,7 +1065,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResponse(); + this.success = new UpdateResponse(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -1175,7 +1106,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("forwardTransaction_result"); + StringBuilder sb = new StringBuilder("chainUpdateEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java index 36b4e5cd5..1fc752175 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java @@ -24,31 +24,28 @@ import com.facebook.thrift.protocol.*; @SuppressWarnings({ "unused", "serial" }) -public class InternalTxnRequest implements TBase, java.io.Serializable, Cloneable, Comparable { +public class InternalTxnRequest implements TBase, java.io.Serializable, Cloneable { private static final TStruct STRUCT_DESC = new TStruct("InternalTxnRequest"); private static final TField TXN_ID_FIELD_DESC = new TField("txn_id", TType.I64, (short)1); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)2); - private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)3); - private static final TField POSITION_FIELD_DESC = new TField("position", TType.I32, (short)4); - private static final TField DATA_FIELD_DESC = new TField("data", TType.LIST, (short)5); + private static final TField TERM_OF_PARTS_FIELD_DESC = new TField("term_of_parts", TType.MAP, (short)2); + private static final TField ADD_EDGE_REQ_FIELD_DESC = new TField("add_edge_req", TType.STRUCT, (short)3); + private static final TField UPD_EDGE_REQ_FIELD_DESC = new TField("upd_edge_req", TType.STRUCT, (short)4); + private static final TField EDGE_VER_FIELD_DESC = new TField("edge_ver", TType.MAP, (short)5); public long txn_id; - public int space_id; - public int part_id; - public int position; - public List> data; + public Map term_of_parts; + public AddEdgesRequest add_edge_req; + public UpdateEdgeRequest upd_edge_req; + public Map> edge_ver; public static final int TXN_ID = 1; - public static final int SPACE_ID = 2; - public static final int PART_ID = 3; - public static final int POSITION = 4; - public static final int DATA = 5; + public static final int TERM_OF_PARTS = 2; + public static final int ADD_EDGE_REQ = 3; + public static final int UPD_EDGE_REQ = 4; + public static final int EDGE_VER = 5; // isset id assignments private static final int __TXN_ID_ISSET_ID = 0; - private static final int __SPACE_ID_ISSET_ID = 1; - private static final int __PART_ID_ISSET_ID = 2; - private static final int __POSITION_ISSET_ID = 3; - private BitSet __isset_bit_vector = new BitSet(4); + private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; @@ -56,16 +53,19 @@ public class InternalTxnRequest implements TBase, java.io.Serializable, Cloneabl Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(TXN_ID, new FieldMetaData("txn_id", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(POSITION, new FieldMetaData("position", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(DATA, new FieldMetaData("data", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, + tmpMetaDataMap.put(TERM_OF_PARTS, new FieldMetaData("term_of_parts", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new FieldValueMetaData(TType.I64)))); + tmpMetaDataMap.put(ADD_EDGE_REQ, new FieldMetaData("add_edge_req", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, AddEdgesRequest.class))); + tmpMetaDataMap.put(UPD_EDGE_REQ, new FieldMetaData("upd_edge_req", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, UpdateEdgeRequest.class))); + tmpMetaDataMap.put(EDGE_VER, new FieldMetaData("edge_ver", TFieldRequirementType.OPTIONAL, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), new ListMetaData(TType.LIST, - new FieldValueMetaData(TType.STRING))))); + new FieldValueMetaData(TType.I64))))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -78,30 +78,36 @@ public InternalTxnRequest() { public InternalTxnRequest( long txn_id, - int space_id, - int part_id, - int position, - List> data) { + Map term_of_parts) { this(); this.txn_id = txn_id; setTxn_idIsSet(true); - this.space_id = space_id; - setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); - this.position = position; - setPositionIsSet(true); - this.data = data; + this.term_of_parts = term_of_parts; + } + + public InternalTxnRequest( + long txn_id, + Map term_of_parts, + AddEdgesRequest add_edge_req, + UpdateEdgeRequest upd_edge_req, + Map> edge_ver) { + this(); + this.txn_id = txn_id; + setTxn_idIsSet(true); + this.term_of_parts = term_of_parts; + this.add_edge_req = add_edge_req; + this.upd_edge_req = upd_edge_req; + this.edge_ver = edge_ver; } public static class Builder { private long txn_id; - private int space_id; - private int part_id; - private int position; - private List> data; + private Map term_of_parts; + private AddEdgesRequest add_edge_req; + private UpdateEdgeRequest upd_edge_req; + private Map> edge_ver; - BitSet __optional_isset = new BitSet(4); + BitSet __optional_isset = new BitSet(1); public Builder() { } @@ -112,26 +118,23 @@ public Builder setTxn_id(final long txn_id) { return this; } - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); + public Builder setTerm_of_parts(final Map term_of_parts) { + this.term_of_parts = term_of_parts; return this; } - public Builder setPart_id(final int part_id) { - this.part_id = part_id; - __optional_isset.set(__PART_ID_ISSET_ID, true); + public Builder setAdd_edge_req(final AddEdgesRequest add_edge_req) { + this.add_edge_req = add_edge_req; return this; } - public Builder setPosition(final int position) { - this.position = position; - __optional_isset.set(__POSITION_ISSET_ID, true); + public Builder setUpd_edge_req(final UpdateEdgeRequest upd_edge_req) { + this.upd_edge_req = upd_edge_req; return this; } - public Builder setData(final List> data) { - this.data = data; + public Builder setEdge_ver(final Map> edge_ver) { + this.edge_ver = edge_ver; return this; } @@ -140,16 +143,10 @@ public InternalTxnRequest build() { if (__optional_isset.get(__TXN_ID_ISSET_ID)) { result.setTxn_id(this.txn_id); } - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } - if (__optional_isset.get(__PART_ID_ISSET_ID)) { - result.setPart_id(this.part_id); - } - if (__optional_isset.get(__POSITION_ISSET_ID)) { - result.setPosition(this.position); - } - result.setData(this.data); + result.setTerm_of_parts(this.term_of_parts); + result.setAdd_edge_req(this.add_edge_req); + result.setUpd_edge_req(this.upd_edge_req); + result.setEdge_ver(this.edge_ver); return result; } } @@ -165,11 +162,17 @@ public InternalTxnRequest(InternalTxnRequest other) { __isset_bit_vector.clear(); __isset_bit_vector.or(other.__isset_bit_vector); this.txn_id = TBaseHelper.deepCopy(other.txn_id); - this.space_id = TBaseHelper.deepCopy(other.space_id); - this.part_id = TBaseHelper.deepCopy(other.part_id); - this.position = TBaseHelper.deepCopy(other.position); - if (other.isSetData()) { - this.data = TBaseHelper.deepCopy(other.data); + if (other.isSetTerm_of_parts()) { + this.term_of_parts = TBaseHelper.deepCopy(other.term_of_parts); + } + if (other.isSetAdd_edge_req()) { + this.add_edge_req = TBaseHelper.deepCopy(other.add_edge_req); + } + if (other.isSetUpd_edge_req()) { + this.upd_edge_req = TBaseHelper.deepCopy(other.upd_edge_req); + } + if (other.isSetEdge_ver()) { + this.edge_ver = TBaseHelper.deepCopy(other.edge_ver); } } @@ -200,96 +203,99 @@ public void setTxn_idIsSet(boolean __value) { __isset_bit_vector.set(__TXN_ID_ISSET_ID, __value); } - public int getSpace_id() { - return this.space_id; + public Map getTerm_of_parts() { + return this.term_of_parts; } - public InternalTxnRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); + public InternalTxnRequest setTerm_of_parts(Map term_of_parts) { + this.term_of_parts = term_of_parts; return this; } - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + public void unsetTerm_of_parts() { + this.term_of_parts = null; } - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + // Returns true if field term_of_parts is set (has been assigned a value) and false otherwise + public boolean isSetTerm_of_parts() { + return this.term_of_parts != null; } - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + public void setTerm_of_partsIsSet(boolean __value) { + if (!__value) { + this.term_of_parts = null; + } } - public int getPart_id() { - return this.part_id; + public AddEdgesRequest getAdd_edge_req() { + return this.add_edge_req; } - public InternalTxnRequest setPart_id(int part_id) { - this.part_id = part_id; - setPart_idIsSet(true); + public InternalTxnRequest setAdd_edge_req(AddEdgesRequest add_edge_req) { + this.add_edge_req = add_edge_req; return this; } - public void unsetPart_id() { - __isset_bit_vector.clear(__PART_ID_ISSET_ID); + public void unsetAdd_edge_req() { + this.add_edge_req = null; } - // Returns true if field part_id is set (has been assigned a value) and false otherwise - public boolean isSetPart_id() { - return __isset_bit_vector.get(__PART_ID_ISSET_ID); + // Returns true if field add_edge_req is set (has been assigned a value) and false otherwise + public boolean isSetAdd_edge_req() { + return this.add_edge_req != null; } - public void setPart_idIsSet(boolean __value) { - __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); + public void setAdd_edge_reqIsSet(boolean __value) { + if (!__value) { + this.add_edge_req = null; + } } - public int getPosition() { - return this.position; + public UpdateEdgeRequest getUpd_edge_req() { + return this.upd_edge_req; } - public InternalTxnRequest setPosition(int position) { - this.position = position; - setPositionIsSet(true); + public InternalTxnRequest setUpd_edge_req(UpdateEdgeRequest upd_edge_req) { + this.upd_edge_req = upd_edge_req; return this; } - public void unsetPosition() { - __isset_bit_vector.clear(__POSITION_ISSET_ID); + public void unsetUpd_edge_req() { + this.upd_edge_req = null; } - // Returns true if field position is set (has been assigned a value) and false otherwise - public boolean isSetPosition() { - return __isset_bit_vector.get(__POSITION_ISSET_ID); + // Returns true if field upd_edge_req is set (has been assigned a value) and false otherwise + public boolean isSetUpd_edge_req() { + return this.upd_edge_req != null; } - public void setPositionIsSet(boolean __value) { - __isset_bit_vector.set(__POSITION_ISSET_ID, __value); + public void setUpd_edge_reqIsSet(boolean __value) { + if (!__value) { + this.upd_edge_req = null; + } } - public List> getData() { - return this.data; + public Map> getEdge_ver() { + return this.edge_ver; } - public InternalTxnRequest setData(List> data) { - this.data = data; + public InternalTxnRequest setEdge_ver(Map> edge_ver) { + this.edge_ver = edge_ver; return this; } - public void unsetData() { - this.data = null; + public void unsetEdge_ver() { + this.edge_ver = null; } - // Returns true if field data is set (has been assigned a value) and false otherwise - public boolean isSetData() { - return this.data != null; + // Returns true if field edge_ver is set (has been assigned a value) and false otherwise + public boolean isSetEdge_ver() { + return this.edge_ver != null; } - public void setDataIsSet(boolean __value) { + public void setEdge_verIsSet(boolean __value) { if (!__value) { - this.data = null; + this.edge_ver = null; } } @@ -304,35 +310,35 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case SPACE_ID: + case TERM_OF_PARTS: if (__value == null) { - unsetSpace_id(); + unsetTerm_of_parts(); } else { - setSpace_id((Integer)__value); + setTerm_of_parts((Map)__value); } break; - case PART_ID: + case ADD_EDGE_REQ: if (__value == null) { - unsetPart_id(); + unsetAdd_edge_req(); } else { - setPart_id((Integer)__value); + setAdd_edge_req((AddEdgesRequest)__value); } break; - case POSITION: + case UPD_EDGE_REQ: if (__value == null) { - unsetPosition(); + unsetUpd_edge_req(); } else { - setPosition((Integer)__value); + setUpd_edge_req((UpdateEdgeRequest)__value); } break; - case DATA: + case EDGE_VER: if (__value == null) { - unsetData(); + unsetEdge_ver(); } else { - setData((List>)__value); + setEdge_ver((Map>)__value); } break; @@ -346,17 +352,17 @@ public Object getFieldValue(int fieldID) { case TXN_ID: return new Long(getTxn_id()); - case SPACE_ID: - return new Integer(getSpace_id()); + case TERM_OF_PARTS: + return getTerm_of_parts(); - case PART_ID: - return new Integer(getPart_id()); + case ADD_EDGE_REQ: + return getAdd_edge_req(); - case POSITION: - return new Integer(getPosition()); + case UPD_EDGE_REQ: + return getUpd_edge_req(); - case DATA: - return getData(); + case EDGE_VER: + return getEdge_ver(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -375,75 +381,20 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.txn_id, that.txn_id)) { return false; } - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetTerm_of_parts(), that.isSetTerm_of_parts(), this.term_of_parts, that.term_of_parts)) { return false; } - if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetAdd_edge_req(), that.isSetAdd_edge_req(), this.add_edge_req, that.add_edge_req)) { return false; } - if (!TBaseHelper.equalsNobinary(this.position, that.position)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetUpd_edge_req(), that.isSetUpd_edge_req(), this.upd_edge_req, that.upd_edge_req)) { return false; } - if (!TBaseHelper.equalsSlow(this.isSetData(), that.isSetData(), this.data, that.data)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetEdge_ver(), that.isSetEdge_ver(), this.edge_ver, that.edge_ver)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {txn_id, space_id, part_id, position, data}); - } - - @Override - public int compareTo(InternalTxnRequest other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetTxn_id()).compareTo(other.isSetTxn_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(txn_id, other.txn_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(part_id, other.part_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetPosition()).compareTo(other.isSetPosition()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(position, other.position); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(data, other.data); - if (lastComparison != 0) { - return lastComparison; - } - return 0; + return Arrays.deepHashCode(new Object[] {txn_id, term_of_parts, add_edge_req, upd_edge_req, edge_ver}); } public void read(TProtocol iprot) throws TException { @@ -465,56 +416,71 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); + case TERM_OF_PARTS: + if (__field.type == TType.MAP) { + { + TMap _map254 = iprot.readMapBegin(); + this.term_of_parts = new HashMap(Math.max(0, 2*_map254.size)); + for (int _i255 = 0; + (_map254.size < 0) ? iprot.peekMap() : (_i255 < _map254.size); + ++_i255) + { + int _key256; + long _val257; + _key256 = iprot.readI32(); + _val257 = iprot.readI64(); + this.term_of_parts.put(_key256, _val257); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } break; - case PART_ID: - if (__field.type == TType.I32) { - this.part_id = iprot.readI32(); - setPart_idIsSet(true); + case ADD_EDGE_REQ: + if (__field.type == TType.STRUCT) { + this.add_edge_req = new AddEdgesRequest(); + this.add_edge_req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); } break; - case POSITION: - if (__field.type == TType.I32) { - this.position = iprot.readI32(); - setPositionIsSet(true); + case UPD_EDGE_REQ: + if (__field.type == TType.STRUCT) { + this.upd_edge_req = new UpdateEdgeRequest(); + this.upd_edge_req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); } break; - case DATA: - if (__field.type == TType.LIST) { + case EDGE_VER: + if (__field.type == TType.MAP) { { - TList _list254 = iprot.readListBegin(); - this.data = new ArrayList>(Math.max(0, _list254.size)); - for (int _i255 = 0; - (_list254.size < 0) ? iprot.peekList() : (_i255 < _list254.size); - ++_i255) + TMap _map258 = iprot.readMapBegin(); + this.edge_ver = new HashMap>(Math.max(0, 2*_map258.size)); + for (int _i259 = 0; + (_map258.size < 0) ? iprot.peekMap() : (_i259 < _map258.size); + ++_i259) { - List _elem256; + int _key260; + List _val261; + _key260 = iprot.readI32(); { - TList _list257 = iprot.readListBegin(); - _elem256 = new ArrayList(Math.max(0, _list257.size)); - for (int _i258 = 0; - (_list257.size < 0) ? iprot.peekList() : (_i258 < _list257.size); - ++_i258) + TList _list262 = iprot.readListBegin(); + _val261 = new ArrayList(Math.max(0, _list262.size)); + for (int _i263 = 0; + (_list262.size < 0) ? iprot.peekList() : (_i263 < _list262.size); + ++_i263) { - byte[] _elem259; - _elem259 = iprot.readBinary(); - _elem256.add(_elem259); + long _elem264; + _elem264 = iprot.readI64(); + _val261.add(_elem264); } iprot.readListEnd(); } - this.data.add(_elem256); + this.edge_ver.put(_key260, _val261); } - iprot.readListEnd(); + iprot.readMapEnd(); } } else { TProtocolUtil.skip(iprot, __field.type); @@ -540,31 +506,51 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TXN_ID_FIELD_DESC); oprot.writeI64(this.txn_id); oprot.writeFieldEnd(); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(PART_ID_FIELD_DESC); - oprot.writeI32(this.part_id); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(POSITION_FIELD_DESC); - oprot.writeI32(this.position); - oprot.writeFieldEnd(); - if (this.data != null) { - oprot.writeFieldBegin(DATA_FIELD_DESC); + if (this.term_of_parts != null) { + oprot.writeFieldBegin(TERM_OF_PARTS_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.LIST, this.data.size())); - for (List _iter260 : this.data) { - { - oprot.writeListBegin(new TList(TType.STRING, _iter260.size())); - for (byte[] _iter261 : _iter260) { - oprot.writeBinary(_iter261); + oprot.writeMapBegin(new TMap(TType.I32, TType.I64, this.term_of_parts.size())); + for (Map.Entry _iter265 : this.term_of_parts.entrySet()) { + oprot.writeI32(_iter265.getKey()); + oprot.writeI64(_iter265.getValue()); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.add_edge_req != null) { + if (isSetAdd_edge_req()) { + oprot.writeFieldBegin(ADD_EDGE_REQ_FIELD_DESC); + this.add_edge_req.write(oprot); + oprot.writeFieldEnd(); + } + } + if (this.upd_edge_req != null) { + if (isSetUpd_edge_req()) { + oprot.writeFieldBegin(UPD_EDGE_REQ_FIELD_DESC); + this.upd_edge_req.write(oprot); + oprot.writeFieldEnd(); + } + } + if (this.edge_ver != null) { + if (isSetEdge_ver()) { + oprot.writeFieldBegin(EDGE_VER_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.edge_ver.size())); + for (Map.Entry> _iter266 : this.edge_ver.entrySet()) { + oprot.writeI32(_iter266.getKey()); + { + oprot.writeListBegin(new TList(TType.I64, _iter266.getValue().size())); + for (long _iter267 : _iter266.getValue()) { + oprot.writeI64(_iter267); + } + oprot.writeListEnd(); } - oprot.writeListEnd(); } + oprot.writeMapEnd(); } - oprot.writeListEnd(); + oprot.writeFieldEnd(); } - oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); @@ -594,36 +580,57 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("space_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("part_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("position"); + sb.append("term_of_parts"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPosition(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("data"); - sb.append(space); - sb.append(":").append(space); - if (this.getData() == null) { + if (this.getTerm_of_parts() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getData(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getTerm_of_parts(), indent + 1, prettyPrint)); } first = false; + if (isSetAdd_edge_req()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("add_edge_req"); + sb.append(space); + sb.append(":").append(space); + if (this.getAdd_edge_req() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getAdd_edge_req(), indent + 1, prettyPrint)); + } + first = false; + } + if (isSetUpd_edge_req()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("upd_edge_req"); + sb.append(space); + sb.append(":").append(space); + if (this.getUpd_edge_req() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getUpd_edge_req(), indent + 1, prettyPrint)); + } + first = false; + } + if (isSetEdge_ver()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("edge_ver"); + sb.append(space); + sb.append(":").append(space); + if (this.getEdge_ver() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getEdge_ver(), indent + 1, prettyPrint)); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/RequestCommon.java b/client/src/main/generated/com/vesoft/nebula/storage/RequestCommon.java index 96a5a568e..94c7bcb37 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/RequestCommon.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/RequestCommon.java @@ -28,16 +28,20 @@ public class RequestCommon implements TBase, java.io.Serializable, Cloneable, Co private static final TStruct STRUCT_DESC = new TStruct("RequestCommon"); private static final TField SESSION_ID_FIELD_DESC = new TField("session_id", TType.I64, (short)1); private static final TField PLAN_ID_FIELD_DESC = new TField("plan_id", TType.I64, (short)2); + private static final TField PROFILE_DETAIL_FIELD_DESC = new TField("profile_detail", TType.BOOL, (short)3); public long session_id; public long plan_id; + public boolean profile_detail; public static final int SESSION_ID = 1; public static final int PLAN_ID = 2; + public static final int PROFILE_DETAIL = 3; // isset id assignments private static final int __SESSION_ID_ISSET_ID = 0; private static final int __PLAN_ID_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); + private static final int __PROFILE_DETAIL_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); public static final Map metaDataMap; @@ -47,6 +51,8 @@ public class RequestCommon implements TBase, java.io.Serializable, Cloneable, Co new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(PLAN_ID, new FieldMetaData("plan_id", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(PROFILE_DETAIL, new FieldMetaData("profile_detail", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.BOOL))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -59,19 +65,23 @@ public RequestCommon() { public RequestCommon( long session_id, - long plan_id) { + long plan_id, + boolean profile_detail) { this(); this.session_id = session_id; setSession_idIsSet(true); this.plan_id = plan_id; setPlan_idIsSet(true); + this.profile_detail = profile_detail; + setProfile_detailIsSet(true); } public static class Builder { private long session_id; private long plan_id; + private boolean profile_detail; - BitSet __optional_isset = new BitSet(2); + BitSet __optional_isset = new BitSet(3); public Builder() { } @@ -88,6 +98,12 @@ public Builder setPlan_id(final long plan_id) { return this; } + public Builder setProfile_detail(final boolean profile_detail) { + this.profile_detail = profile_detail; + __optional_isset.set(__PROFILE_DETAIL_ISSET_ID, true); + return this; + } + public RequestCommon build() { RequestCommon result = new RequestCommon(); if (__optional_isset.get(__SESSION_ID_ISSET_ID)) { @@ -96,6 +112,9 @@ public RequestCommon build() { if (__optional_isset.get(__PLAN_ID_ISSET_ID)) { result.setPlan_id(this.plan_id); } + if (__optional_isset.get(__PROFILE_DETAIL_ISSET_ID)) { + result.setProfile_detail(this.profile_detail); + } return result; } } @@ -112,6 +131,7 @@ public RequestCommon(RequestCommon other) { __isset_bit_vector.or(other.__isset_bit_vector); this.session_id = TBaseHelper.deepCopy(other.session_id); this.plan_id = TBaseHelper.deepCopy(other.plan_id); + this.profile_detail = TBaseHelper.deepCopy(other.profile_detail); } public RequestCommon deepCopy() { @@ -164,6 +184,29 @@ public void setPlan_idIsSet(boolean __value) { __isset_bit_vector.set(__PLAN_ID_ISSET_ID, __value); } + public boolean isProfile_detail() { + return this.profile_detail; + } + + public RequestCommon setProfile_detail(boolean profile_detail) { + this.profile_detail = profile_detail; + setProfile_detailIsSet(true); + return this; + } + + public void unsetProfile_detail() { + __isset_bit_vector.clear(__PROFILE_DETAIL_ISSET_ID); + } + + // Returns true if field profile_detail is set (has been assigned a value) and false otherwise + public boolean isSetProfile_detail() { + return __isset_bit_vector.get(__PROFILE_DETAIL_ISSET_ID); + } + + public void setProfile_detailIsSet(boolean __value) { + __isset_bit_vector.set(__PROFILE_DETAIL_ISSET_ID, __value); + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SESSION_ID: @@ -182,6 +225,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case PROFILE_DETAIL: + if (__value == null) { + unsetProfile_detail(); + } else { + setProfile_detail((Boolean)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -195,6 +246,9 @@ public Object getFieldValue(int fieldID) { case PLAN_ID: return new Long(getPlan_id()); + case PROFILE_DETAIL: + return new Boolean(isProfile_detail()); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -214,12 +268,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetPlan_id(), that.isSetPlan_id(), this.plan_id, that.plan_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetProfile_detail(), that.isSetProfile_detail(), this.profile_detail, that.profile_detail)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {session_id, plan_id}); + return Arrays.deepHashCode(new Object[] {session_id, plan_id, profile_detail}); } @Override @@ -250,6 +306,14 @@ public int compareTo(RequestCommon other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetProfile_detail()).compareTo(other.isSetProfile_detail()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(profile_detail, other.profile_detail); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -280,6 +344,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case PROFILE_DETAIL: + if (__field.type == TType.BOOL) { + this.profile_detail = iprot.readBool(); + setProfile_detailIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -307,6 +379,11 @@ public void write(TProtocol oprot) throws TException { oprot.writeI64(this.plan_id); oprot.writeFieldEnd(); } + if (isSetProfile_detail()) { + oprot.writeFieldBegin(PROFILE_DETAIL_FIELD_DESC); + oprot.writeBool(this.profile_detail); + oprot.writeFieldEnd(); + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -346,6 +423,16 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getPlan_id(), indent + 1, prettyPrint)); first = false; } + if (isSetProfile_detail()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("profile_detail"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isProfile_detail(), indent + 1, prettyPrint)); + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java index 8b6e3019c..04627c6a4 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java @@ -868,17 +868,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler371) throws TException { + public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler400) throws TException { checkReady(); - transLeader_call method_call = new transLeader_call(req, resultHandler371, this, ___protocolFactory, ___transport); + transLeader_call method_call = new transLeader_call(req, resultHandler400, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class transLeader_call extends TAsyncMethodCall { private TransLeaderReq req; - public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler372, TAsyncClient client368, TProtocolFactory protocolFactory369, TNonblockingTransport transport370) throws TException { - super(client368, protocolFactory369, transport370, resultHandler372, false); + public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler401, TAsyncClient client397, TProtocolFactory protocolFactory398, TNonblockingTransport transport399) throws TException { + super(client397, protocolFactory398, transport399, resultHandler401, false); this.req = req; } @@ -900,17 +900,17 @@ public AdminExecResp getResult() throws TException { } } - public void addPart(AddPartReq req, AsyncMethodCallback resultHandler376) throws TException { + public void addPart(AddPartReq req, AsyncMethodCallback resultHandler405) throws TException { checkReady(); - addPart_call method_call = new addPart_call(req, resultHandler376, this, ___protocolFactory, ___transport); + addPart_call method_call = new addPart_call(req, resultHandler405, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addPart_call extends TAsyncMethodCall { private AddPartReq req; - public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler377, TAsyncClient client373, TProtocolFactory protocolFactory374, TNonblockingTransport transport375) throws TException { - super(client373, protocolFactory374, transport375, resultHandler377, false); + public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler406, TAsyncClient client402, TProtocolFactory protocolFactory403, TNonblockingTransport transport404) throws TException { + super(client402, protocolFactory403, transport404, resultHandler406, false); this.req = req; } @@ -932,17 +932,17 @@ public AdminExecResp getResult() throws TException { } } - public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler381) throws TException { + public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler410) throws TException { checkReady(); - addLearner_call method_call = new addLearner_call(req, resultHandler381, this, ___protocolFactory, ___transport); + addLearner_call method_call = new addLearner_call(req, resultHandler410, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addLearner_call extends TAsyncMethodCall { private AddLearnerReq req; - public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler382, TAsyncClient client378, TProtocolFactory protocolFactory379, TNonblockingTransport transport380) throws TException { - super(client378, protocolFactory379, transport380, resultHandler382, false); + public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler411, TAsyncClient client407, TProtocolFactory protocolFactory408, TNonblockingTransport transport409) throws TException { + super(client407, protocolFactory408, transport409, resultHandler411, false); this.req = req; } @@ -964,17 +964,17 @@ public AdminExecResp getResult() throws TException { } } - public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler386) throws TException { + public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler415) throws TException { checkReady(); - removePart_call method_call = new removePart_call(req, resultHandler386, this, ___protocolFactory, ___transport); + removePart_call method_call = new removePart_call(req, resultHandler415, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removePart_call extends TAsyncMethodCall { private RemovePartReq req; - public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler387, TAsyncClient client383, TProtocolFactory protocolFactory384, TNonblockingTransport transport385) throws TException { - super(client383, protocolFactory384, transport385, resultHandler387, false); + public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler416, TAsyncClient client412, TProtocolFactory protocolFactory413, TNonblockingTransport transport414) throws TException { + super(client412, protocolFactory413, transport414, resultHandler416, false); this.req = req; } @@ -996,17 +996,17 @@ public AdminExecResp getResult() throws TException { } } - public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler391) throws TException { + public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler420) throws TException { checkReady(); - memberChange_call method_call = new memberChange_call(req, resultHandler391, this, ___protocolFactory, ___transport); + memberChange_call method_call = new memberChange_call(req, resultHandler420, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class memberChange_call extends TAsyncMethodCall { private MemberChangeReq req; - public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler392, TAsyncClient client388, TProtocolFactory protocolFactory389, TNonblockingTransport transport390) throws TException { - super(client388, protocolFactory389, transport390, resultHandler392, false); + public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler421, TAsyncClient client417, TProtocolFactory protocolFactory418, TNonblockingTransport transport419) throws TException { + super(client417, protocolFactory418, transport419, resultHandler421, false); this.req = req; } @@ -1028,17 +1028,17 @@ public AdminExecResp getResult() throws TException { } } - public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler396) throws TException { + public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler425) throws TException { checkReady(); - waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler396, this, ___protocolFactory, ___transport); + waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler425, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class waitingForCatchUpData_call extends TAsyncMethodCall { private CatchUpDataReq req; - public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler397, TAsyncClient client393, TProtocolFactory protocolFactory394, TNonblockingTransport transport395) throws TException { - super(client393, protocolFactory394, transport395, resultHandler397, false); + public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler426, TAsyncClient client422, TProtocolFactory protocolFactory423, TNonblockingTransport transport424) throws TException { + super(client422, protocolFactory423, transport424, resultHandler426, false); this.req = req; } @@ -1060,17 +1060,17 @@ public AdminExecResp getResult() throws TException { } } - public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler401) throws TException { + public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler430) throws TException { checkReady(); - createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler401, this, ___protocolFactory, ___transport); + createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler430, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createCheckpoint_call extends TAsyncMethodCall { private CreateCPRequest req; - public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler402, TAsyncClient client398, TProtocolFactory protocolFactory399, TNonblockingTransport transport400) throws TException { - super(client398, protocolFactory399, transport400, resultHandler402, false); + public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler431, TAsyncClient client427, TProtocolFactory protocolFactory428, TNonblockingTransport transport429) throws TException { + super(client427, protocolFactory428, transport429, resultHandler431, false); this.req = req; } @@ -1092,17 +1092,17 @@ public CreateCPResp getResult() throws TException { } } - public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler406) throws TException { + public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler435) throws TException { checkReady(); - dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler406, this, ___protocolFactory, ___transport); + dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler435, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropCheckpoint_call extends TAsyncMethodCall { private DropCPRequest req; - public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler407, TAsyncClient client403, TProtocolFactory protocolFactory404, TNonblockingTransport transport405) throws TException { - super(client403, protocolFactory404, transport405, resultHandler407, false); + public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler436, TAsyncClient client432, TProtocolFactory protocolFactory433, TNonblockingTransport transport434) throws TException { + super(client432, protocolFactory433, transport434, resultHandler436, false); this.req = req; } @@ -1124,17 +1124,17 @@ public AdminExecResp getResult() throws TException { } } - public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler411) throws TException { + public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler440) throws TException { checkReady(); - blockingWrites_call method_call = new blockingWrites_call(req, resultHandler411, this, ___protocolFactory, ___transport); + blockingWrites_call method_call = new blockingWrites_call(req, resultHandler440, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class blockingWrites_call extends TAsyncMethodCall { private BlockingSignRequest req; - public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler412, TAsyncClient client408, TProtocolFactory protocolFactory409, TNonblockingTransport transport410) throws TException { - super(client408, protocolFactory409, transport410, resultHandler412, false); + public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler441, TAsyncClient client437, TProtocolFactory protocolFactory438, TNonblockingTransport transport439) throws TException { + super(client437, protocolFactory438, transport439, resultHandler441, false); this.req = req; } @@ -1156,17 +1156,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler416) throws TException { + public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler445) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler416, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler445, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler417, TAsyncClient client413, TProtocolFactory protocolFactory414, TNonblockingTransport transport415) throws TException { - super(client413, protocolFactory414, transport415, resultHandler417, false); + public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler446, TAsyncClient client442, TProtocolFactory protocolFactory443, TNonblockingTransport transport444) throws TException { + super(client442, protocolFactory443, transport444, resultHandler446, false); this.req = req; } @@ -1188,17 +1188,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler421) throws TException { + public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler450) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler421, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler450, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler422, TAsyncClient client418, TProtocolFactory protocolFactory419, TNonblockingTransport transport420) throws TException { - super(client418, protocolFactory419, transport420, resultHandler422, false); + public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler451, TAsyncClient client447, TProtocolFactory protocolFactory448, TNonblockingTransport transport449) throws TException { + super(client447, protocolFactory448, transport449, resultHandler451, false); this.req = req; } @@ -1220,17 +1220,17 @@ public AdminExecResp getResult() throws TException { } } - public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler426) throws TException { + public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler455) throws TException { checkReady(); - getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler426, this, ___protocolFactory, ___transport); + getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler455, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getLeaderParts_call extends TAsyncMethodCall { private GetLeaderReq req; - public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler427, TAsyncClient client423, TProtocolFactory protocolFactory424, TNonblockingTransport transport425) throws TException { - super(client423, protocolFactory424, transport425, resultHandler427, false); + public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler456, TAsyncClient client452, TProtocolFactory protocolFactory453, TNonblockingTransport transport454) throws TException { + super(client452, protocolFactory453, transport454, resultHandler456, false); this.req = req; } @@ -1252,17 +1252,17 @@ public GetLeaderPartsResp getResult() throws TException { } } - public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler431) throws TException { + public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler460) throws TException { checkReady(); - checkPeers_call method_call = new checkPeers_call(req, resultHandler431, this, ___protocolFactory, ___transport); + checkPeers_call method_call = new checkPeers_call(req, resultHandler460, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class checkPeers_call extends TAsyncMethodCall { private CheckPeersReq req; - public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler432, TAsyncClient client428, TProtocolFactory protocolFactory429, TNonblockingTransport transport430) throws TException { - super(client428, protocolFactory429, transport430, resultHandler432, false); + public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler461, TAsyncClient client457, TProtocolFactory protocolFactory458, TNonblockingTransport transport459) throws TException { + super(client457, protocolFactory458, transport459, resultHandler461, false); this.req = req; } @@ -1284,17 +1284,17 @@ public AdminExecResp getResult() throws TException { } } - public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler436) throws TException { + public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler465) throws TException { checkReady(); - addAdminTask_call method_call = new addAdminTask_call(req, resultHandler436, this, ___protocolFactory, ___transport); + addAdminTask_call method_call = new addAdminTask_call(req, resultHandler465, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addAdminTask_call extends TAsyncMethodCall { private AddAdminTaskRequest req; - public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler437, TAsyncClient client433, TProtocolFactory protocolFactory434, TNonblockingTransport transport435) throws TException { - super(client433, protocolFactory434, transport435, resultHandler437, false); + public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler466, TAsyncClient client462, TProtocolFactory protocolFactory463, TNonblockingTransport transport464) throws TException { + super(client462, protocolFactory463, transport464, resultHandler466, false); this.req = req; } @@ -1316,17 +1316,17 @@ public AdminExecResp getResult() throws TException { } } - public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler441) throws TException { + public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler470) throws TException { checkReady(); - stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler441, this, ___protocolFactory, ___transport); + stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler470, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class stopAdminTask_call extends TAsyncMethodCall { private StopAdminTaskRequest req; - public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler442, TAsyncClient client438, TProtocolFactory protocolFactory439, TNonblockingTransport transport440) throws TException { - super(client438, protocolFactory439, transport440, resultHandler442, false); + public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler471, TAsyncClient client467, TProtocolFactory protocolFactory468, TNonblockingTransport transport469) throws TException { + super(client467, protocolFactory468, transport469, resultHandler471, false); this.req = req; } @@ -1348,17 +1348,17 @@ public AdminExecResp getResult() throws TException { } } - public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler446) throws TException { + public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler475) throws TException { checkReady(); - listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler446, this, ___protocolFactory, ___transport); + listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler475, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listClusterInfo_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler447, TAsyncClient client443, TProtocolFactory protocolFactory444, TNonblockingTransport transport445) throws TException { - super(client443, protocolFactory444, transport445, resultHandler447, false); + public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler476, TAsyncClient client472, TProtocolFactory protocolFactory473, TNonblockingTransport transport474) throws TException { + super(client472, protocolFactory473, transport474, resultHandler476, false); this.req = req; } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java new file mode 100644 index 000000000..6287a381f --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java @@ -0,0 +1,18 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.exception; + +/** + * + */ +public class ClientServerIncompatibleException extends Exception { + public ClientServerIncompatibleException(String message) { + super("Current client is not compatible with the remote server, please check the " + + "version: " + message); + } +} + diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java index 9e2ebd4ab..b9f088b89 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/ConnObjectPool.java @@ -2,6 +2,7 @@ import com.vesoft.nebula.client.graph.NebulaPoolConfig; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import org.apache.commons.pool2.BasePooledObjectFactory; import org.apache.commons.pool2.PooledObject; @@ -18,7 +19,7 @@ public ConnObjectPool(LoadBalancer loadBalancer, NebulaPoolConfig config) { } @Override - public SyncConnection create() throws IOErrorException { + public SyncConnection create() throws IOErrorException, ClientServerIncompatibleException { HostAddress address = loadBalancer.getAddress(); if (address == null) { throw new IOErrorException(IOErrorException.E_ALL_BROKEN, diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java index 5f94f1c84..40e43951e 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java @@ -2,6 +2,7 @@ import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; public abstract class Connection { @@ -12,11 +13,12 @@ public HostAddress getServerAddress() { } public abstract void open(HostAddress address, int timeout, SSLParam sslParam) - throws IOErrorException; + throws IOErrorException, ClientServerIncompatibleException; - public abstract void open(HostAddress address, int timeout) throws IOErrorException; + public abstract void open(HostAddress address, int timeout) throws IOErrorException, + ClientServerIncompatibleException; - public abstract void reopen() throws IOErrorException; + public abstract void reopen() throws IOErrorException, ClientServerIncompatibleException; public abstract void close(); diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/LoadBalancer.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/LoadBalancer.java index d586c12d1..b26eeaeae 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/LoadBalancer.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/LoadBalancer.java @@ -1,6 +1,7 @@ package com.vesoft.nebula.client.graph.net; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; public interface LoadBalancer { HostAddress getAddress(); diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java index 6fe80a2ba..54c0c4670 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java @@ -9,6 +9,7 @@ import com.vesoft.nebula.client.graph.NebulaPoolConfig; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.exception.InvalidConfigException; import com.vesoft.nebula.client.graph.exception.NotValidConnectionException; @@ -129,7 +130,8 @@ public void close() { * @throws AuthFailedException if authenticate failed */ public Session getSession(String userName, String password, boolean reconnect) - throws NotValidConnectionException, IOErrorException, AuthFailedException { + throws NotValidConnectionException, IOErrorException, AuthFailedException, + ClientServerIncompatibleException { checkNoInitAndClosed(); SyncConnection connection = null; try { diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java index 9e7c9402a..395eca3a0 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java @@ -2,6 +2,7 @@ import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import java.util.ArrayList; import java.util.HashMap; @@ -11,9 +12,11 @@ import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; - +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; public class RoundRobinLoadBalancer implements LoadBalancer { + private static final Logger LOGGER = LoggerFactory.getLogger(RoundRobinLoadBalancer.class); private static final int S_OK = 0; private static final int S_BAD = 1; private final List addresses = new ArrayList<>(); @@ -79,7 +82,8 @@ public boolean ping(HostAddress addr) { } connection.close(); return true; - } catch (IOErrorException e) { + } catch (IOErrorException | ClientServerIncompatibleException e) { + LOGGER.error("ping failed", e); return false; } } @@ -94,7 +98,7 @@ public boolean isServersOK() { return true; } - private void scheduleTask() { + private void scheduleTask() { updateServersStatus(); } } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java index 76d5dd83b..3b216910a 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java @@ -60,7 +60,8 @@ public Session(SyncConnection connection, * such as insert ngql `INSERT VERTEX person(name) VALUES "Tom":("Tom");` * @return The ResultSet */ - public synchronized ResultSet execute(String stmt) throws IOErrorException { + public synchronized ResultSet execute(String stmt) throws + IOErrorException { if (connection == null) { throw new IOErrorException(IOErrorException.E_CONNECT_BROKEN, "The session was released, couldn't use again."); @@ -158,7 +159,8 @@ public synchronized ResultSet execute(String stmt) throws IOErrorException { * such as insert ngql `INSERT VERTEX person(name) VALUES "Tom":("Tom");` * @return The JSON string */ - public synchronized String executeJson(String stmt) throws IOErrorException { + public synchronized String executeJson(String stmt) throws + IOErrorException { if (connection == null) { throw new IOErrorException(IOErrorException.E_CONNECT_BROKEN, "The session was released, couldn't use again."); diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java index 87e95cb4a..c514264a2 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java @@ -25,7 +25,8 @@ public SessionWrapper(Session session) { * @param stmt The query sentence. * @return The ResultSet. */ - public ResultSet execute(String stmt) throws IOErrorException { + public ResultSet execute(String stmt) + throws IOErrorException { if (!available()) { throw new InvalidSessionException(); } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java index 059199209..9c1aa9a88 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java @@ -9,6 +9,7 @@ import com.vesoft.nebula.client.graph.SessionsManagerConfig; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.exception.NotValidConnectionException; import java.net.UnknownHostException; @@ -44,7 +45,8 @@ private void checkConfig() { * @return SessionWrapper * @throws RuntimeException the exception when get SessionWrapper */ - public synchronized SessionWrapper getSessionWrapper() throws RuntimeException { + public synchronized SessionWrapper getSessionWrapper() throws RuntimeException, + ClientServerIncompatibleException { checkClose(); if (pool == null) { init(); diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java index 4e6a77161..d07bf5ae1 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java @@ -14,64 +14,79 @@ import com.facebook.thrift.transport.TTransport; import com.facebook.thrift.transport.TTransportException; import com.facebook.thrift.utils.StandardCharsets; +import com.google.common.base.Charsets; import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.SSLParam; import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.graph.AuthResponse; import com.vesoft.nebula.graph.ExecutionResponse; import com.vesoft.nebula.graph.GraphService; +import com.vesoft.nebula.graph.VerifyClientVersionReq; +import com.vesoft.nebula.graph.VerifyClientVersionResp; import com.vesoft.nebula.util.SslUtil; import java.io.IOException; import javax.net.ssl.SSLSocketFactory; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; public class SyncConnection extends Connection { + + private static final Logger LOGGER = LoggerFactory.getLogger(SyncConnection.class); + protected TTransport transport = null; protected TProtocol protocol = null; private GraphService.Client client = null; private int timeout = 0; private SSLParam sslParam = null; private boolean enabledSsl = false; + private SSLSocketFactory sslSocketFactory = null; @Override - public void open(HostAddress address, int timeout, SSLParam sslParam) throws IOErrorException { + public void open(HostAddress address, int timeout, SSLParam sslParam) + throws IOErrorException, ClientServerIncompatibleException { try { - SSLSocketFactory sslSocketFactory; this.serverAddr = address; this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; this.enabledSsl = true; this.sslParam = sslParam; - if (sslParam.getSignMode() == SSLParam.SignMode.CA_SIGNED) { - sslSocketFactory = - SslUtil.getSSLSocketFactoryWithCA((CASignedSSLParam) sslParam); - } else { - sslSocketFactory = - SslUtil.getSSLSocketFactoryWithoutCA((SelfSignedSSLParam) sslParam); - } if (sslSocketFactory == null) { - throw new IOErrorException(IOErrorException.E_UNKNOWN, - "SSL Socket Factory Creation failed"); + if (sslParam.getSignMode() == SSLParam.SignMode.CA_SIGNED) { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithCA((CASignedSSLParam) sslParam); + } else { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithoutCA((SelfSignedSSLParam) sslParam); + } } this.transport = new TSocket( sslSocketFactory.createSocket(address.getHost(), address.getPort()), this.timeout, this.timeout); this.protocol = new TCompactProtocol(transport); client = new GraphService.Client(protocol); - } catch (TException e) { + + // check if client version matches server version + VerifyClientVersionResp resp = + client.verifyClientVersion(new VerifyClientVersionReq()); + if (resp.error_code != ErrorCode.SUCCEEDED) { + client.getInputProtocol().getTransport().close(); + throw new ClientServerIncompatibleException(new String(resp.getError_msg(), + Charsets.UTF_8)); + } + } catch (TException | IOException e) { throw new IOErrorException(IOErrorException.E_UNKNOWN, e.getMessage()); - } catch (IOException e) { - e.printStackTrace(); } } @Override - public void open(HostAddress address, int timeout) throws IOErrorException { + public void open(HostAddress address, int timeout) + throws IOErrorException, ClientServerIncompatibleException { try { - this.enabledSsl = false; this.serverAddr = address; this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; this.transport = new TSocket( @@ -79,6 +94,15 @@ public void open(HostAddress address, int timeout) throws IOErrorException { this.transport.open(); this.protocol = new TCompactProtocol(transport); client = new GraphService.Client(protocol); + + // check if client version matches server version + VerifyClientVersionResp resp = + client.verifyClientVersion(new VerifyClientVersionReq()); + if (resp.error_code != ErrorCode.SUCCEEDED) { + client.getInputProtocol().getTransport().close(); + throw new ClientServerIncompatibleException(new String(resp.getError_msg(), + Charsets.UTF_8)); + } } catch (TException e) { throw new IOErrorException(IOErrorException.E_UNKNOWN, e.getMessage()); } @@ -95,7 +119,7 @@ public void open(HostAddress address, int timeout) throws IOErrorException { * @throws IOErrorException if io problem happen */ @Override - public void reopen() throws IOErrorException { + public void reopen() throws IOErrorException, ClientServerIncompatibleException { close(); if (enabledSsl) { open(serverAddr, timeout, sslParam); @@ -105,7 +129,7 @@ public void reopen() throws IOErrorException { } public AuthResult authenticate(String user, String password) - throws AuthFailedException, IOErrorException { + throws AuthFailedException, IOErrorException, ClientServerIncompatibleException { try { AuthResponse resp = client.authenticate(user.getBytes(), password.getBytes()); if (resp.error_code != ErrorCode.SUCCEEDED) { @@ -148,7 +172,11 @@ public ExecutionResponse execute(long sessionID, String stmt) throw new IOErrorException(IOErrorException.E_NO_OPEN, te.getMessage()); } else if (te.getType() == TTransportException.TIMED_OUT || te.getMessage().contains("Read timed out")) { - reopen(); + try { + reopen(); + } catch (ClientServerIncompatibleException ex) { + LOGGER.error(ex.getMessage()); + } throw new IOErrorException(IOErrorException.E_TIME_OUT, te.getMessage()); } } @@ -170,7 +198,11 @@ public String executeJson(long sessionID, String stmt) throw new IOErrorException(IOErrorException.E_NO_OPEN, te.getMessage()); } else if (te.getType() == TTransportException.TIMED_OUT || te.getMessage().contains("Read timed out")) { - reopen(); + try { + reopen(); + } catch (ClientServerIncompatibleException ex) { + LOGGER.error(ex.getMessage()); + } throw new IOErrorException(IOErrorException.E_TIME_OUT, te.getMessage()); } } @@ -188,7 +220,6 @@ public boolean ping() { execute(0, "YIELD 1;"); return true; } catch (IOErrorException e) { - e.printStackTrace(); return false; } } diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java index 47f7c14ed..41c74e478 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java @@ -10,9 +10,11 @@ import com.facebook.thrift.protocol.TCompactProtocol; import com.facebook.thrift.transport.TSocket; import com.facebook.thrift.transport.TTransportException; +import com.google.common.base.Charsets; import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.GetEdgeReq; @@ -39,6 +41,8 @@ import com.vesoft.nebula.meta.Schema; import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; +import com.vesoft.nebula.meta.VerifyClientVersionReq; +import com.vesoft.nebula.meta.VerifyClientVersionResp; import java.util.Arrays; import java.util.HashSet; import java.util.List; @@ -57,7 +61,6 @@ public class MetaClient extends AbstractMetaClient { private static final int DEFAULT_TIMEOUT_MS = 1000; private static final int DEFAULT_CONNECTION_RETRY_SIZE = 3; private static final int DEFAULT_EXECUTION_RETRY_SIZE = 3; - private static final int RETRY_TIMES = 1; private MetaService.Client client; @@ -85,30 +88,47 @@ public MetaClient(List addresses, int timeout, int connectionRetry, this.addresses = addresses; } - public void connect() throws TException { + public void connect() + throws TException, ClientServerIncompatibleException { doConnect(); } /** * connect nebula meta server */ - private void doConnect() throws TTransportException { + private void doConnect() + throws TTransportException, ClientServerIncompatibleException { Random random = new Random(System.currentTimeMillis()); int position = random.nextInt(addresses.size()); HostAddress address = addresses.get(position); getClient(address.getHost(), address.getPort()); } - private void getClient(String host, int port) throws TTransportException { + private void getClient(String host, int port) + throws TTransportException, ClientServerIncompatibleException { transport = new TSocket(host, port, timeout, timeout); transport.open(); protocol = new TCompactProtocol(transport); client = new MetaService.Client(protocol); + + // check if client version matches server version + VerifyClientVersionResp resp = + client.verifyClientVersion(new VerifyClientVersionReq()); + if (resp.getCode() != ErrorCode.SUCCEEDED) { + client.getInputProtocol().getTransport().close(); + throw new ClientServerIncompatibleException(new String(resp.getError_msg(), + Charsets.UTF_8)); + } } - private void freshClient(HostAddr leader) throws TTransportException { + private void freshClient(HostAddr leader) + throws TTransportException { close(); - getClient(leader.getHost(), leader.getPort()); + try { + getClient(leader.getHost(), leader.getPort()); + } catch (ClientServerIncompatibleException e) { + LOGGER.error(e.getMessage()); + } } /** diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java index a68b79e18..e26d389b2 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java @@ -10,6 +10,7 @@ import com.google.common.collect.Maps; import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.IdName; @@ -49,7 +50,8 @@ private class SpaceInfo { /** * init the meta info cache */ - public MetaManager(List address) throws TException { + public MetaManager(List address) + throws TException, ClientServerIncompatibleException { metaClient = new MetaClient(address); metaClient.connect(); fillMetaInfo(); diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index d71442857..ca6926b3c 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -13,6 +13,7 @@ import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.Time; import com.vesoft.nebula.client.graph.NebulaPoolConfig; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.net.NebulaPool; import com.vesoft.nebula.client.graph.net.Session; @@ -459,7 +460,7 @@ public void testSelfSignedSsl() { try { Runtime runtime = Runtime.getRuntime(); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-selfsigned.yaml up -d").waitFor(20,TimeUnit.SECONDS); + + "-selfsigned.yaml up -d"); NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); @@ -468,6 +469,7 @@ public void testSelfSignedSsl() { "src/test/resources/ssl/selfsigned.pem", "src/test/resources/ssl/selfsigned.key", "vesoft")); + TimeUnit.SECONDS.sleep(45); Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), nebulaSslPoolConfig)); sslSession = sslPool.getSession("root", "nebula", true); @@ -499,7 +501,7 @@ public void testCASignedSsl() { try { Runtime runtime = Runtime.getRuntime(); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-casigned.yaml up -d").waitFor(20,TimeUnit.SECONDS); + + "-casigned.yaml up -d"); NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); @@ -508,6 +510,7 @@ public void testCASignedSsl() { "src/test/resources/ssl/casigned.pem", "src/test/resources/ssl/casigned.crt", "src/test/resources/ssl/casigned.key")); + TimeUnit.SECONDS.sleep(45); Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), nebulaSslPoolConfig)); sslSession = sslPool.getSession("root", "nebula", true); diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java index d74845504..ba7a972a9 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java @@ -68,7 +68,7 @@ public void testInitFailed() { Collections.singletonList(new HostAddress("127.0.0.1", 3777)), config); assert false; - } catch (UnknownHostException e) { + } catch (UnknownHostException e) { System.out.println("We expect must reach here: init pool failed."); assert false; } catch (InvalidConfigException e) { diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java index 64a55b3e1..e598d6132 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java @@ -6,21 +6,17 @@ package com.vesoft.nebula.client.graph.net; -import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.client.graph.NebulaPoolConfig; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.util.ProcessUtil; -import java.io.BufferedReader; -import java.io.InputStreamReader; import java.util.Arrays; import java.util.List; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicReference; import org.junit.Assert; import org.junit.Test; @@ -110,7 +106,9 @@ public void testReconnectWithMultiServices() { new HostAddress("127.0.0.1", 9669), new HostAddress("127.0.0.1", 9670), new HostAddress("127.0.0.1", 9671)); + TimeUnit.SECONDS.sleep(15); Assert.assertTrue(pool.init(addresses, nebulaPoolConfig)); + TimeUnit.SECONDS.sleep(15); Session session = pool.getSession("root", "nebula", true); System.out.println("The address of session is " + session.getGraphHost()); diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java index 03b017091..7f1fc6704 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java @@ -11,6 +11,7 @@ import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.exception.InvalidConfigException; import com.vesoft.nebula.client.graph.exception.InvalidSessionException; @@ -45,7 +46,8 @@ public void testBase() { } catch (UnknownHostException | NotValidConnectionException | AuthFailedException - | InterruptedException e) { + | InterruptedException + | ClientServerIncompatibleException e) { Assert.assertFalse(e.getMessage(), false); } @@ -120,7 +122,7 @@ public void testBase() { assert false; } - } catch (InvalidConfigException | IOErrorException e) { + } catch (InvalidConfigException | IOErrorException | ClientServerIncompatibleException e) { Assert.fail(); } } diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java index 5c80bc114..2643824e4 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java @@ -10,6 +10,7 @@ import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.exception.NotValidConnectionException; import com.vesoft.nebula.client.graph.net.NebulaPool; @@ -44,7 +45,7 @@ public static void initGraph() { System.exit(1); } } catch (UnknownHostException | NotValidConnectionException - | IOErrorException | AuthFailedException e) { + | IOErrorException | AuthFailedException | ClientServerIncompatibleException e) { e.printStackTrace(); } finally { pool.close(); diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java index 6d3a06a2e..6a0a53660 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java @@ -7,6 +7,7 @@ package com.vesoft.nebula.client.meta; import com.facebook.thrift.TException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.client.util.ProcessUtil; import com.vesoft.nebula.meta.EdgeItem; @@ -40,7 +41,7 @@ private void connect() { metaClient = new MetaClient(address, port); try { metaClient.connect(); - } catch (TException e) { + } catch (TException | ClientServerIncompatibleException e) { e.printStackTrace(); assert (false); } @@ -51,7 +52,7 @@ public void testFailConnect() { MetaClient client = new MetaClient(address, port); try { client.connect(); - } catch (TException e) { + } catch (TException | ClientServerIncompatibleException e) { assert (true); } } diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java index ac3cf8ed9..9782a3924 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java @@ -8,6 +8,7 @@ import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; @@ -97,7 +98,7 @@ public void testGetSpaceParts() { Assert.assertEquals(hostAddr.port, 4400); } - public void testMultiVersionSchema() { + public void testMultiVersionSchema() throws ClientServerIncompatibleException { MockNebulaGraph.createMultiVersionTagAndEdge(); metaManager.close(); metaManager = new MetaManager( diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java index da9f98601..8a376b506 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java @@ -10,6 +10,7 @@ import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.AuthFailedException; +import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.exception.NotValidConnectionException; import com.vesoft.nebula.client.graph.net.NebulaPool; @@ -49,7 +50,7 @@ public static void initGraph() { assert (false); } } catch (UnknownHostException | NotValidConnectionException - | IOErrorException | AuthFailedException e) { + | IOErrorException | AuthFailedException | ClientServerIncompatibleException e) { e.printStackTrace(); } finally { pool.close(); diff --git a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java index ccfdff3f0..09bda6469 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java @@ -61,7 +61,7 @@ private Schema genNoDefaultVal() { new ColumnTypeDef(PropertyType.STRING)); columns.add(columnDef); columnDef = new ColumnDef(("Col09").getBytes(), - new ColumnTypeDef(PropertyType.FIXED_STRING, (short)12)); + new ColumnTypeDef(PropertyType.FIXED_STRING, (short)12, null)); columns.add(columnDef); columnDef = new ColumnDef(("Col10").getBytes(), new ColumnTypeDef(PropertyType.TIMESTAMP)); @@ -178,7 +178,7 @@ public MetaCacheImplTest() { "utf-8".getBytes(), "utf-8".getBytes(), new ColumnTypeDef( - PropertyType.FIXED_STRING, (short)20)); + PropertyType.FIXED_STRING, (short)20, null)); this.spaceItem = spaceItem; this.spaceItem.properties = spaceDesc; From 597c0ec4fd82f7b0cb4cb92ab3bac881f3c95663 Mon Sep 17 00:00:00 2001 From: Klay Date: Wed, 20 Oct 2021 19:26:44 -0700 Subject: [PATCH 04/25] geo support (#371) * initial checkin * Merge branch 'master' into klay-geo-support * Update TestDataFromServer.java * fix syntax * revert unnecessary changes * add copyright --- .../client/graph/data/CoordinateWrapper.java | 57 +++++++++++ .../client/graph/data/GeographyWrapper.java | 70 ++++++++++++++ .../client/graph/data/LineStringWrapper.java | 77 +++++++++++++++ .../client/graph/data/PointWrapper.java | 57 +++++++++++ .../client/graph/data/PolygonWrapper.java | 96 +++++++++++++++++++ .../client/graph/data/ValueWrapper.java | 29 +++++- .../nebula/client/graph/net/Connection.java | 1 + .../client/storage/data/BaseTableRow.java | 7 +- .../nebula/encoder/NebulaCodecImpl.java | 6 -- .../nebula/client/graph/data/TestData.java | 74 ++++++++++++-- .../client/graph/data/TestDataFromServer.java | 96 ++++++++++++++++++- .../nebula/client/storage/MockUtil.java | 9 +- .../processor/VertexProcessorTest.java | 10 +- 13 files changed, 569 insertions(+), 20 deletions(-) create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java new file mode 100644 index 000000000..2d95a84e4 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java @@ -0,0 +1,57 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Coordinate; +import java.util.Arrays; + +public class CoordinateWrapper extends BaseDataObject { + private final Coordinate coordinate; + + public CoordinateWrapper(Coordinate coordinate) { + this.coordinate = coordinate; + } + + public double getX() { + return coordinate.getX(); + } + + public double getY() { + return coordinate.getY(); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CoordinateWrapper that = (CoordinateWrapper) o; + return this.getX() == that.getX() + && this.getY() == that.getY(); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("COORDINATE"); + sb.append('('); + sb.append(coordinate.getX()); + sb.append(' '); + sb.append(coordinate.getY()); + sb.append(')'); + + return sb.toString(); + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {this.getX(), this.getY()}); + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java new file mode 100644 index 000000000..7a9962af7 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java @@ -0,0 +1,70 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Geography; +import java.util.Objects; + +public class GeographyWrapper extends BaseDataObject { + private final Geography geography; + + public GeographyWrapper(Geography geography) { + this.geography = geography; + } + + public PolygonWrapper getPolygonWrapper() { + return new PolygonWrapper(geography.getPgVal()); + } + + public LineStringWrapper getLineStringWrapper() { + return new LineStringWrapper(geography.getLsVal()); + } + + public PointWrapper getPointWrapper() { + return new PointWrapper(geography.getPtVal()); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GeographyWrapper that = (GeographyWrapper)o; + switch (geography.getSetField()) { + case Geography.PTVAL: + return getPointWrapper().equals(that.getPointWrapper()); + case Geography.LSVAL: + return getLineStringWrapper().equals(that.getLineStringWrapper()); + case Geography.PGVAL: + return getPolygonWrapper().equals(that.getPolygonWrapper()); + default: + return false; + } + } + + @Override + public String toString() { + switch (geography.getSetField()) { + case Geography.PTVAL: + return getPointWrapper().toString(); + case Geography.LSVAL: + return getLineStringWrapper().toString(); + case Geography.PGVAL: + return getPolygonWrapper().toString(); + default: + return ""; + } + } + + @Override + public int hashCode() { + return Objects.hash(geography); + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java new file mode 100644 index 000000000..f1ca7baf0 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java @@ -0,0 +1,77 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Coordinate; +import com.vesoft.nebula.LineString; +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + +public class LineStringWrapper extends BaseDataObject { + private final LineString lineString; + + public LineStringWrapper(LineString lineString) { + this.lineString = lineString; + } + + public List getCoordinateList() { + List coordList = new ArrayList<>(); + for (Coordinate coord : lineString.getCoordList()) { + coordList.add(new CoordinateWrapper(coord)); + } + return coordList; + } + + @Override + public int hashCode() { + return Objects.hash(lineString); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + LineStringWrapper that = (LineStringWrapper) o; + List thisList = getCoordinateList(); + List thatList = that.getCoordinateList(); + if (thisList.size() != thatList.size()) { + return false; + } + for (int i = 0; i < thisList.size(); i++) { + if (!thisList.get(i).equals(thatList.get(i))) { + return false; + } + } + return true; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("LINESTRING"); + sb.append('('); + if (lineString.getCoordList() != null) { + for (Coordinate coordinate : lineString.getCoordList()) { + sb.append(coordinate.getX()); + sb.append(' '); + sb.append(coordinate.getY()); + sb.append(','); + } + if (sb.charAt(sb.length() - 1) == ',') { + sb.deleteCharAt(sb.length() - 1); + } + } + sb.append(')'); + + return sb.toString(); + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java new file mode 100644 index 000000000..85fab7095 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java @@ -0,0 +1,57 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Coordinate; +import com.vesoft.nebula.Point; +import java.util.Objects; + +public class PointWrapper extends BaseDataObject { + private final Point point; + + public PointWrapper(Point point) { + this.point = point; + } + + public CoordinateWrapper getCoordinate() { + return new CoordinateWrapper(point.getCoord()); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + PointWrapper that = (PointWrapper) o; + return this.getCoordinate().equals(that.getCoordinate()); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("POINT"); + sb.append('('); + Coordinate coordinate = point.getCoord(); + if (coordinate != null) { + sb.append(coordinate.getX()); + sb.append(' '); + sb.append(coordinate.getY()); + } + sb.append(')'); + + return sb.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(point); + } + +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java new file mode 100644 index 000000000..ee6b2d377 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java @@ -0,0 +1,96 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License, + * attached with Common Clause Condition 1.0, found in the LICENSES directory. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Coordinate; +import com.vesoft.nebula.Polygon; +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + +public class PolygonWrapper extends BaseDataObject { + private final Polygon polygon; + + public PolygonWrapper(Polygon polygon) { + this.polygon = polygon; + } + + public List> getCoordListList() { + List> coordListList = new ArrayList<>(); + for (List cl: polygon.getCoordListList()) { + List coordList = new ArrayList<>(); + for (Coordinate coordinate : cl) { + coordList.add(new CoordinateWrapper(coordinate)); + } + coordListList.add(coordList); + } + return coordListList; + } + + @Override + public int hashCode() { + return Objects.hash(polygon); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + PolygonWrapper that = (PolygonWrapper) o; + List> thisListList = getCoordListList(); + List> thatListList = that.getCoordListList(); + if (thisListList.size() != thatListList.size()) { + return false; + } + for (int i = 0; i < thisListList.size(); i++) { + List thisList = thisListList.get(i); + List thatList = thatListList.get(i); + if (thisList.size() != thatList.size()) { + return false; + } + for (int j = 0; j < thisList.size(); j++) { + if (!thisList.get(j).equals(thatList.get(j))) { + return false; + } + } + } + return true; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("POLYGON"); + sb.append('('); + if (polygon.getCoordListList() != null) { + for (List cl : polygon.getCoordListList()) { + sb.append('('); + for (Coordinate coordinate : cl) { + sb.append(coordinate.getX()); + sb.append(' '); + sb.append(coordinate.getY()); + sb.append(','); + } + if (sb.charAt(sb.length() - 1) == ',') { + sb.deleteCharAt(sb.length() - 1); + } + sb.append(')'); + sb.append(','); + } + if (sb.charAt(sb.length() - 1) == ',') { + sb.deleteCharAt(sb.length() - 1); + } + } + sb.append(')'); + + return sb.toString(); + } +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java index fac334836..3e3986674 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java @@ -87,6 +87,8 @@ private String descType() { return "SET"; case Value.GVAL: return "DATASET"; + case Value.GGVAL: + return "GEOGRAPHY"; default: throw new IllegalArgumentException("Unknown field id " + value.getSetField()); } @@ -243,6 +245,14 @@ public boolean isPath() { return value.getSetField() == Value.PVAL; } + /** + * judge the Value is Geography type, the Geography type is the nebula's type + * @return boolean + */ + public boolean isGeography() { + return value.getSetField() == Value.GGVAL; + } + /** * Convert the original data type Value to NullType * @return NullType @@ -442,7 +452,7 @@ public Relationship asRelationship() throws InvalidValueException { /** * Convert the original data type Value to Path - * @return Path + * @return PathWrapper * @throws InvalidValueException if the value type is not path * @throws UnsupportedEncodingException if decode bianry failed */ @@ -456,6 +466,21 @@ public PathWrapper asPath() throws InvalidValueException, UnsupportedEncodingExc "Cannot get field PathWrapper because value's type is " + descType()); } + /** + * Convert the original data type Value to geography + * @return GeographyWrapper + * @throws InvalidValueException if the value type is not geography + */ + public GeographyWrapper asGeography() throws InvalidValueException { + if (value.getSetField() == Value.GGVAL) { + return (GeographyWrapper) new GeographyWrapper(value.getGgVal()) + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); + } + throw new InvalidValueException( + "Cannot get field GeographyWrapper because value's type is " + descType()); + } + @Override public boolean equals(Object o) { if (this == o) { @@ -511,6 +536,8 @@ public String toString() { return asRelationship().toString(); } else if (isPath()) { return asPath().toString(); + } else if (isGeography()) { + return asGeography().toString(); } return "Unknown type: " + descType(); } catch (UnsupportedEncodingException e) { diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java index 40e43951e..76944bb58 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Connection.java @@ -15,6 +15,7 @@ public HostAddress getServerAddress() { public abstract void open(HostAddress address, int timeout, SSLParam sslParam) throws IOErrorException, ClientServerIncompatibleException; + public abstract void open(HostAddress address, int timeout) throws IOErrorException, ClientServerIncompatibleException; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java index d832cc9c8..97035c495 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java @@ -8,6 +8,7 @@ import com.vesoft.nebula.client.graph.data.DateTimeWrapper; import com.vesoft.nebula.client.graph.data.DateWrapper; +import com.vesoft.nebula.client.graph.data.GeographyWrapper; import com.vesoft.nebula.client.graph.data.TimeWrapper; import com.vesoft.nebula.client.graph.data.ValueWrapper; import java.io.UnsupportedEncodingException; @@ -60,7 +61,6 @@ public DateWrapper getDate(int i) { return values.get(i).asDate(); } - public TimeWrapper getTime(int i) { return values.get(i).asTime(); } @@ -69,10 +69,15 @@ public DateTimeWrapper getDateTime(int i) { return values.get(i).asDateTime(); } + public GeographyWrapper getGeography(int i) { + return values.get(i).asGeography(); + } + public List getValues() { return values; } + /** * Displays all elements of this vertexTableRow in a string using a separator string. */ diff --git a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java index 47aed3c8d..f5f3c706f 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java @@ -6,21 +6,15 @@ package com.vesoft.nebula.encoder; -import com.vesoft.nebula.HostAddr; -import com.vesoft.nebula.client.meta.MetaCache; import com.vesoft.nebula.meta.ColumnDef; import com.vesoft.nebula.meta.ColumnTypeDef; import com.vesoft.nebula.meta.EdgeItem; -import com.vesoft.nebula.meta.PropertyType; import com.vesoft.nebula.meta.Schema; -import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.util.Arrays; import java.util.List; -import java.util.Map; -import org.apache.commons.codec.digest.MurmurHash2; /** * NebulaCodecImpl is an encoder to generate the given data. diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java index 4b46b4b9a..54af89306 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java @@ -6,16 +6,21 @@ package com.vesoft.nebula.client.graph.data; +import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.DataSet; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; import com.vesoft.nebula.Edge; import com.vesoft.nebula.ErrorCode; +import com.vesoft.nebula.Geography; +import com.vesoft.nebula.LineString; import com.vesoft.nebula.NList; import com.vesoft.nebula.NMap; import com.vesoft.nebula.NSet; import com.vesoft.nebula.NullType; import com.vesoft.nebula.Path; +import com.vesoft.nebula.Point; +import com.vesoft.nebula.Polygon; import com.vesoft.nebula.Row; import com.vesoft.nebula.Step; import com.vesoft.nebula.Tag; @@ -89,6 +94,8 @@ public Path getPath(String startId, int stepsNum) { return new Path(getVertex(startId), steps); } + + public Vertex getSimpleVertex() { Map props1 = new HashMap<>(); props1.put("tag1_prop".getBytes(), new Value(Value.IVAL, (long)100)); @@ -172,7 +179,17 @@ public DataSet getDateset() { (byte)10, (byte)10, (byte)30, (byte)0, 100)), new Value(Value.VVAL, getVertex("Tom")), new Value(Value.EVAL, getEdge("Tom", "Lily")), - new Value(Value.PVAL, getPath("Tom", 3)))); + new Value(Value.PVAL, getPath("Tom", 3)), + new Value(Value.GGVAL, new Geography(Geography.PTVAL, new Point(new Coordinate(1.0, + 2.0)))), + new Value(Value.GGVAL, new Geography(Geography.PGVAL, new Polygon(Arrays.asList( + Arrays.asList(new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0)), + Arrays.asList(new Coordinate(3.0, 6.0), new Coordinate(4.0, 8.0)) + )))), + new Value(Value.GGVAL, new Geography(Geography.LSVAL, new LineString(Arrays.asList( + new Coordinate(1.0, 2.0), + new Coordinate(2.0, 4.0) + )))))); final List columnNames = Arrays.asList( "col0_empty".getBytes(), "col1_null".getBytes(), @@ -188,7 +205,10 @@ public DataSet getDateset() { "col11_datetime".getBytes(), "col12_vertex".getBytes(), "col13_edge".getBytes(), - "col14_path".getBytes()); + "col14_path".getBytes(), + "col15_point".getBytes(), + "col16_polygon".getBytes(), + "col17_linestring".getBytes()); return new DataSet(columnNames, Collections.singletonList(row)); } @@ -268,7 +288,7 @@ public void testRelationShip() { } @Test - public void testPathWarpper() { + public void testPathWrapper() { try { Path path = getPath("Tom", 5); PathWrapper pathWrapper = new PathWrapper(path); @@ -325,12 +345,13 @@ public void testResult() { assert resultSet.getPlanDesc() != null; List expectColNames = Arrays.asList( "col0_empty", "col1_null", "col2_bool", "col3_int", "col4_double", "col5_string", - "col6_list", "col7_set", "col8_map", "col9_time", "col10_date", - "col11_datetime", "col12_vertex", "col13_edge", "col14_path"); + "col6_list", "col7_set", "col8_map", "col9_time", "col10_date", "col11_datetime", + "col12_vertex", "col13_edge", "col14_path", "col15_point", "col16_polygon", + "col17_linestring"); assert Objects.equals(resultSet.keys(), expectColNames); assert resultSet.getRows().size() == 1; ResultSet.Record record = resultSet.rowValues(0); - assert record.size() == 15; + assert record.size() == 18; assert record.get(0).isEmpty(); assert record.get(1).isNull(); @@ -414,6 +435,24 @@ public void testResult() { assert Objects.equals(record.get(14).asPath(), new PathWrapper(getPath("Tom", 3))); assert resultSet.toString().length() > 100; + + assert record.get(15).isGeography(); + assert Objects.equals(record.get(15).asGeography().toString(), + new PointWrapper(new Point(new Coordinate(1.0, 2.0))).toString()); + + assert record.get(16).isGeography(); + assert Objects.equals(record.get(16).asGeography().toString(), + new PolygonWrapper(new Polygon(Arrays.asList( + Arrays.asList(new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0)), + Arrays.asList(new Coordinate(3.0, 6.0), new Coordinate(4.0, 8.0)) + ))).toString()); + + assert record.get(17).isGeography(); + assert Objects.equals(record.get(17).asGeography().toString(), + new LineStringWrapper(new LineString(Arrays.asList( + new Coordinate(1.0, 2.0), + new Coordinate(2.0, 4.0) + ))).toString()); } catch (Exception e) { e.printStackTrace(); assert (false); @@ -458,6 +497,29 @@ public void testToString() { + "(\"vertex1\" :tag1 {tag1_prop: 200})-[:classmate@10{edge2_prop: 200}]->" + "(\"vertex2\" :tag2 {tag2_prop: 300})"; Assert.assertEquals(expectString, valueWrapper.asPath().toString()); + + valueWrapper = new ValueWrapper( + new Value(Value.GGVAL, new Geography(Geography.PTVAL, new Point(new Coordinate(1.0, + 2.0)))), "utf-8", 28800); + expectString = "POINT(1.0 2.0)"; + Assert.assertEquals(expectString, valueWrapper.asGeography().toString()); + + valueWrapper = new ValueWrapper( + new Value(Value.GGVAL, new Geography(Geography.PGVAL, new Polygon(Arrays.asList( + Arrays.asList(new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0)), + Arrays.asList(new Coordinate(3.0, 6.0), new Coordinate(4.0, 8.0)) + )))), "utf-8", 28800); + expectString = "POLYGON((1.0 2.0,2.0 4.0),(3.0 6.0,4.0 8.0))"; + Assert.assertEquals(expectString, valueWrapper.asGeography().toString()); + + valueWrapper = new ValueWrapper( + new Value(Value.GGVAL, new Geography(Geography.LSVAL, + new LineString(Arrays.asList( + new Coordinate(1.0, 2.0), + new Coordinate(2.0, 4.0) + )))), "utf-8", 28800); + expectString = "LINESTRING(1.0 2.0,2.0 4.0)"; + Assert.assertEquals(expectString, valueWrapper.asGeography().toString()); } catch (Exception e) { e.printStackTrace(); assert (false); diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index ca6926b3c..a995515f9 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -8,12 +8,16 @@ import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; +import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; import com.vesoft.nebula.ErrorCode; +import com.vesoft.nebula.Geography; +import com.vesoft.nebula.LineString; +import com.vesoft.nebula.Point; +import com.vesoft.nebula.Polygon; import com.vesoft.nebula.Time; import com.vesoft.nebula.client.graph.NebulaPoolConfig; -import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.graph.net.NebulaPool; import com.vesoft.nebula.client.graph.net.Session; @@ -54,7 +58,8 @@ public void setUp() throws Exception { + "CREATE TAG IF NOT EXISTS student(name string);" + "CREATE EDGE IF NOT EXISTS like(likeness double);" + "CREATE EDGE IF NOT EXISTS friend(start_year int, end_year int);" - + "CREATE TAG INDEX IF NOT EXISTS person_name_index ON person(name(8));"); + + "CREATE TAG INDEX IF NOT EXISTS person_name_index ON person(name(8));" + + "CREATE TAG IF NOT EXISTS any_shape(geo geography);"); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); TimeUnit.SECONDS.sleep(6); String insertVertexes = "INSERT VERTEX person(name, age, grade,friends, book_num, " @@ -103,6 +108,21 @@ public void setUp() throws Exception { + "'Bob'->'John'@100:(2018, 2020);"; resp = session.execute(insertEdges); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); + + String insertShape = "INSERT VERTEX any_shape(geo) VALUES 'Point':(ST_GeogFromText('POINT" + + "(3 8)'));"; + resp = session.execute(insertShape); + Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); + + insertShape = "INSERT VERTEX any_shape(geo) VALUES 'LString':(ST_GeogFromText('LINESTRING" + + "(3 8, 4.7 73.23)'));"; + resp = session.execute(insertShape); + Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); + + insertShape = "INSERT VERTEX any_shape(geo) VALUES 'Polygon':(ST_GeogFromText('POLYGON((0 " + + "1, 1 2, 2 3, 0 1))'));"; + resp = session.execute(insertShape); + Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); } @After @@ -173,6 +193,78 @@ public void testAllSchemaType() { Assert.assertEquals(ValueWrapper.NullType.__NULL__, properties.get("hobby").asNull().getNullType()); + result = session.execute("FETCH PROP ON any_shape 'Point';"); + Assert.assertTrue(result.isSucceeded()); + Assert.assertEquals("", result.getErrorMessage()); + Assert.assertFalse(result.getLatency() <= 0); + Assert.assertEquals("", result.getComment()); + Assert.assertEquals(ErrorCode.SUCCEEDED.getValue(), result.getErrorCode()); + Assert.assertEquals("test_data", result.getSpaceName()); + Assert.assertFalse(result.isEmpty()); + Assert.assertEquals(1, result.rowsSize()); + + Assert.assertTrue(result.rowValues(0).get(0).isVertex()); + node = result.rowValues(0).get(0).asNode(); + Assert.assertEquals("Point", node.getId().asString()); + Assert.assertEquals(Arrays.asList("any_shape"), node.tagNames()); + properties = node.properties("any_shape"); + GeographyWrapper geographyWrapper = new GeographyWrapper( + new Geography(Geography.PTVAL, new Point(new Coordinate(3, 8)))); + Assert.assertEquals(geographyWrapper, properties.get("geo").asGeography()); + Assert.assertEquals(geographyWrapper.toString(), + properties.get("geo").asGeography().toString()); + + result = session.execute("FETCH PROP ON any_shape 'LString';"); + Assert.assertTrue(result.isSucceeded()); + Assert.assertEquals("", result.getErrorMessage()); + Assert.assertFalse(result.getLatency() <= 0); + Assert.assertEquals("", result.getComment()); + Assert.assertEquals(ErrorCode.SUCCEEDED.getValue(), result.getErrorCode()); + Assert.assertEquals("test_data", result.getSpaceName()); + Assert.assertFalse(result.isEmpty()); + Assert.assertEquals(1, result.rowsSize()); + + Assert.assertTrue(result.rowValues(0).get(0).isVertex()); + node = result.rowValues(0).get(0).asNode(); + Assert.assertEquals("LString", node.getId().asString()); + Assert.assertEquals(Arrays.asList("any_shape"), node.tagNames()); + properties = node.properties("any_shape"); + geographyWrapper = new GeographyWrapper( + new Geography(Geography.LSVAL, new LineString(Arrays.asList(new Coordinate(3, + 8), new Coordinate(4.7, 73.23))))); + Assert.assertEquals(geographyWrapper, properties.get("geo").asGeography()); + Assert.assertEquals(geographyWrapper.toString(), + properties.get("geo").asGeography().toString()); + + + result = session.execute("FETCH PROP ON any_shape 'Polygon';"); + Assert.assertTrue(result.isSucceeded()); + Assert.assertEquals("", result.getErrorMessage()); + Assert.assertFalse(result.getLatency() <= 0); + Assert.assertEquals("", result.getComment()); + Assert.assertEquals(ErrorCode.SUCCEEDED.getValue(), result.getErrorCode()); + Assert.assertEquals("test_data", result.getSpaceName()); + Assert.assertFalse(result.isEmpty()); + Assert.assertEquals(1, result.rowsSize()); + + Assert.assertTrue(result.rowValues(0).get(0).isVertex()); + node = result.rowValues(0).get(0).asNode(); + Assert.assertEquals("Polygon", node.getId().asString()); + Assert.assertEquals(Arrays.asList("any_shape"), node.tagNames()); + properties = node.properties("any_shape"); + geographyWrapper = new GeographyWrapper( + new Geography(Geography.PGVAL, + new Polygon(Arrays.asList(Arrays.asList( + new Coordinate(0, 1), + new Coordinate(1, 2), + new Coordinate(2, 3), + new Coordinate(0,1)) + )))); + Assert.assertEquals(geographyWrapper, properties.get("geo").asGeography()); + Assert.assertEquals(geographyWrapper.toString(), + properties.get("geo").asGeography().toString()); + + } catch (IOErrorException | UnsupportedEncodingException e) { e.printStackTrace(); assert false; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java index 97037eb8d..649e73a56 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java @@ -6,9 +6,13 @@ package com.vesoft.nebula.client.storage; +import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.DataSet; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Geography; +import com.vesoft.nebula.Point; +import com.vesoft.nebula.Polygon; import com.vesoft.nebula.Row; import com.vesoft.nebula.Time; import com.vesoft.nebula.Value; @@ -26,7 +30,8 @@ public static List mockVertexDataSets() { columnNames.add("person.double_col3".getBytes()); columnNames.add("person.date_col4".getBytes()); columnNames.add("person.time_col5".getBytes()); - columnNames.add("person.datetime_col5".getBytes()); + columnNames.add("person.datetime_col6".getBytes()); + columnNames.add("person.geography_col7".getBytes()); // row 1 List values1 = new ArrayList<>(); @@ -38,6 +43,8 @@ public static List mockVertexDataSets() { values1.add(Value.tVal(new Time((byte) 12, (byte) 1, (byte) 1, 100))); values1.add(Value.dtVal(new DateTime((short) 2020, (byte) 1, (byte) 1, (byte) 12, (byte) 10, (byte) 30, 100))); + values1.add(Value.ggVal(new Geography(Geography.PTVAL, + new Point(new Coordinate(1.0,1.5))))); List rows = new ArrayList<>(); rows.add(new Row(values1)); diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java index 2df80c5b2..ebbdb8300 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java @@ -7,6 +7,7 @@ package com.vesoft.nebula.client.storage.processor; import com.vesoft.nebula.DataSet; +import com.vesoft.nebula.client.graph.data.PointWrapper; import com.vesoft.nebula.client.graph.data.ValueWrapper; import com.vesoft.nebula.client.storage.MockUtil; import com.vesoft.nebula.client.storage.data.VertexRow; @@ -32,7 +33,7 @@ public void testConstructVertexRow() { e.printStackTrace(); assert (false); } - assert (rows.get(0).getProps().size() == 6); + assert (rows.get(0).getProps().size() == 7); assert (rows.get(0).getProps().containsKey("boolean_col1")); assert (rows.get(0).getProps().containsKey("long_col2")); } @@ -40,9 +41,10 @@ public void testConstructVertexRow() { @Test public void testConstructEdgeTableRow() { List dataSets = MockUtil.mockVertexDataSets(); - List tableRows = VertexProcessor.constructVertexTableRow(dataSets, "utf-8"); + List tableRows = VertexProcessor + .constructVertexTableRow(dataSets, "utf-8"); assert (tableRows.size() == dataSets.get(0).getRows().size()); - assert (tableRows.get(0).getValues().size() == 7); + assert (tableRows.get(0).getValues().size() == 8); try { assert (tableRows.get(0).getVid().asString().equals("Tom")); assert (tableRows.get(0).getString(0).equals("Tom")); @@ -55,5 +57,7 @@ public void testConstructEdgeTableRow() { assert (tableRows.get(0).getDate(4).getYear() == 2020); assert (tableRows.get(0).getTime(5).getSecond() == 1); assert (tableRows.get(0).getDateTime(6).getDay() == 1); + assert (tableRows.get(0).getGeography(7).getPointWrapper().getCoordinate().getX() == 1.0); + } } From 2b82dda225b1e9590469a1e30f1446c3ce51b222 Mon Sep 17 00:00:00 2001 From: Myheart <1580680232@qq.com> Date: Fri, 22 Oct 2021 10:05:14 +0800 Subject: [PATCH 05/25] Bugfix/encoder row writer (#366) * fix field not nullable error * fix strList out of bound exception * fix field not nullable error * fix strList out of bound exception Co-authored-by: Anqi --- .../main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java | 2 +- .../src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java index f5f3c706f..276bd006e 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java @@ -199,7 +199,7 @@ private SchemaProviderImpl genSchemaProvider(long ver, Schema schema) { SchemaProviderImpl schemaProvider = new SchemaProviderImpl(ver); for (ColumnDef col : schema.getColumns()) { ColumnTypeDef type = col.getType(); - boolean nullable = col.isSetNullable(); + boolean nullable = col.isSetNullable() && col.isNullable(); boolean hasDefault = col.isSetDefault_value(); int len = type.isSetType_length() ? type.getType_length() : 0; schemaProvider.addField(new String(col.getName()), diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java index 955011ca5..ce21c58bc 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java @@ -831,6 +831,7 @@ public ByteBuffer processOutOfSpace() { // Set the new offset and length temp.putInt(offset, 0); temp.putInt(offset + Integer.BYTES, 0); + continue; } else { // Out of space string if (strNum >= strList.size()) { From 57f5c6c9fe629d686296b58c989188aba6fbdcc4 Mon Sep 17 00:00:00 2001 From: Anqi Date: Fri, 29 Oct 2021 13:56:52 +0800 Subject: [PATCH 06/25] sync the fetch syntax: add yield (#376) --- .../client/graph/data/TestDataFromServer.java | 57 ++++++++++--------- 1 file changed, 31 insertions(+), 26 deletions(-) diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index a995515f9..0718e985c 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -109,18 +109,18 @@ public void setUp() throws Exception { resp = session.execute(insertEdges); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); - String insertShape = "INSERT VERTEX any_shape(geo) VALUES 'Point':(ST_GeogFromText('POINT" - + "(3 8)'));"; + String insertShape = + "INSERT VERTEX any_shape(geo) VALUES 'Point':(ST_GeogFromText('POINT(3 8)'));"; resp = session.execute(insertShape); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); - insertShape = "INSERT VERTEX any_shape(geo) VALUES 'LString':(ST_GeogFromText('LINESTRING" - + "(3 8, 4.7 73.23)'));"; + insertShape = "INSERT VERTEX any_shape(geo) VALUES 'LString':" + + "(ST_GeogFromText('LINESTRING(3 8, 4.7 73.23)'));"; resp = session.execute(insertShape); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); - insertShape = "INSERT VERTEX any_shape(geo) VALUES 'Polygon':(ST_GeogFromText('POLYGON((0 " - + "1, 1 2, 2 3, 0 1))'));"; + insertShape = "INSERT VERTEX any_shape(geo) VALUES 'Polygon':" + + "(ST_GeogFromText('POLYGON((0 1, 1 2, 2 3, 0 1))'));"; resp = session.execute(insertShape); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); } @@ -136,7 +136,8 @@ public void tearDown() { @Test public void testAllSchemaType() { try { - ResultSet result = session.execute("FETCH PROP ON person 'Bob';"); + ResultSet result = session.execute( + "FETCH PROP ON person 'Bob' yield vertex as vertices_;"); Assert.assertTrue(result.isSucceeded()); Assert.assertEquals("", result.getErrorMessage()); Assert.assertFalse(result.getLatency() <= 0); @@ -193,7 +194,8 @@ public void testAllSchemaType() { Assert.assertEquals(ValueWrapper.NullType.__NULL__, properties.get("hobby").asNull().getNullType()); - result = session.execute("FETCH PROP ON any_shape 'Point';"); + result = session.execute( + "FETCH PROP ON any_shape 'Point' yield vertex as vertices_;"); Assert.assertTrue(result.isSucceeded()); Assert.assertEquals("", result.getErrorMessage()); Assert.assertFalse(result.getLatency() <= 0); @@ -214,7 +216,8 @@ public void testAllSchemaType() { Assert.assertEquals(geographyWrapper.toString(), properties.get("geo").asGeography().toString()); - result = session.execute("FETCH PROP ON any_shape 'LString';"); + result = session.execute( + "FETCH PROP ON any_shape 'LString' yield vertex as vertices_;"); Assert.assertTrue(result.isSucceeded()); Assert.assertEquals("", result.getErrorMessage()); Assert.assertFalse(result.getLatency() <= 0); @@ -237,7 +240,8 @@ public void testAllSchemaType() { properties.get("geo").asGeography().toString()); - result = session.execute("FETCH PROP ON any_shape 'Polygon';"); + result = session.execute( + "FETCH PROP ON any_shape 'Polygon' yield vertex as vertices_;"); Assert.assertTrue(result.isSucceeded()); Assert.assertEquals("", result.getErrorMessage()); Assert.assertFalse(result.getLatency() <= 0); @@ -254,12 +258,12 @@ public void testAllSchemaType() { properties = node.properties("any_shape"); geographyWrapper = new GeographyWrapper( new Geography(Geography.PGVAL, - new Polygon(Arrays.asList(Arrays.asList( - new Coordinate(0, 1), - new Coordinate(1, 2), - new Coordinate(2, 3), - new Coordinate(0,1)) - )))); + new Polygon(Arrays.asList(Arrays.asList( + new Coordinate(0, 1), + new Coordinate(1, 2), + new Coordinate(2, 3), + new Coordinate(0, 1)) + )))); Assert.assertEquals(geographyWrapper, properties.get("geo").asGeography()); Assert.assertEquals(geographyWrapper.toString(), properties.get("geo").asGeography().toString()); @@ -478,7 +482,8 @@ public void tesDataset() { @Test public void testErrorResult() { try { - ResultSet result = session.execute("FETCH PROP ON no_exist_tag \"nobody\""); + ResultSet result = session.execute( + "FETCH PROP ON no_exist_tag \"nobody\" yield vertex as vertices_"); Assert.assertTrue(result.toString().contains("ExecutionResponse")); } catch (IOErrorException e) { e.printStackTrace(); @@ -514,11 +519,11 @@ public void testComplexTypeForJson() { String rowData = resp.getJSONArray("results").getJSONObject(0).getJSONArray("data") .getJSONObject(0).getJSONArray("row").toJSONString(); Assert.assertEquals(rowData, "[{\"person.first_out_city\":1111,\"person" - + ".book_num\":100,\"person.age\":10,\"person.expend\":100,\"person.is_girl\":" - + "false,\"person.name\":\"Bob\",\"person.grade\":3,\"person.birthday\":\"2010" - + "-09-10T02:08:02.0Z\",\"student.name\":\"Bob\",\"person.child_name\":\"Hello" - + " Worl\",\"person.property\":1000,\"person.morning\":\"23:10:00.000000Z\",\"" - + "person.start_school\":\"2017-09-10\",\"person.friends\":10}]"); + + ".book_num\":100,\"person.age\":10,\"person.expend\":100,\"person.is_girl\":" + + "false,\"person.name\":\"Bob\",\"person.grade\":3,\"person.birthday\":\"2010" + + "-09-10T02:08:02.0Z\",\"student.name\":\"Bob\",\"person.child_name\":\"Hello" + + " Worl\",\"person.property\":1000,\"person.morning\":\"23:10:00.000000Z\",\"" + + "person.start_school\":\"2017-09-10\",\"person.friends\":10}]"); } catch (IOErrorException e) { e.printStackTrace(); assert false; @@ -552,7 +557,7 @@ public void testSelfSignedSsl() { try { Runtime runtime = Runtime.getRuntime(); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-selfsigned.yaml up -d"); + + "-selfsigned.yaml up -d"); NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); @@ -574,7 +579,7 @@ public void testSelfSignedSsl() { Assert.assertEquals(rowData, exp); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-selfsigned.yaml down").waitFor(60,TimeUnit.SECONDS); + + "-selfsigned.yaml down").waitFor(60, TimeUnit.SECONDS); } catch (Exception e) { e.printStackTrace(); assert false; @@ -593,7 +598,7 @@ public void testCASignedSsl() { try { Runtime runtime = Runtime.getRuntime(); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-casigned.yaml up -d"); + + "-casigned.yaml up -d"); NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); @@ -615,7 +620,7 @@ public void testCASignedSsl() { Assert.assertEquals(rowData, exp); runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-casigned.yaml down").waitFor(60,TimeUnit.SECONDS); + + "-casigned.yaml down").waitFor(60, TimeUnit.SECONDS); } catch (Exception e) { e.printStackTrace(); assert false; From 3d56b9c4542018b10703bb983dfa19e954557029 Mon Sep 17 00:00:00 2001 From: Anqi Date: Mon, 1 Nov 2021 11:26:30 +0800 Subject: [PATCH 07/25] add version match (#378) --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9c922675f..054c73808 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,8 @@ There are the version correspondence between client and Nebula: | 2.0.0-beta | 2.0.0-beta | | 2.0.0-rc1 | 2.0.0-rc1 | | 2.0.0/2.0.1 | 2.0.0/2.0.1 | -| 2.5.0 | >= 2.5.0 | +| 2.5.0 | 2.5.0 | +| 2.6.0 | 2.6.0 | | 2.0.0-SNAPSHOT| 2.0.0-nightly | ## Graph client example From efcfe1583609968be62c669de2161af3ec3c2f61 Mon Sep 17 00:00:00 2001 From: Anqi Date: Mon, 8 Nov 2021 18:58:32 +0800 Subject: [PATCH 08/25] support ssl for metaClient and storageClient (#379) * support ssl for MetaClient and StorageClient * start nebula server on workflow * update ssl test * fix typo --- .github/workflows/maven.yml | 27 +++ .../graph/net/RoundRobinLoadBalancer.java | 1 - .../vesoft/nebula/client/meta/MetaClient.java | 42 ++++- .../nebula/client/meta/MetaManager.java | 17 ++ .../storage/GraphStorageConnection.java | 44 ++++- .../nebula/client/storage/StorageClient.java | 29 +++- .../storage/StorageConnPoolFactory.java | 6 +- .../client/storage/StoragePoolConfig.java | 22 +++ .../client/graph/data/TestDataFromServer.java | 16 +- .../nebula/client/meta/MockNebulaGraph.java | 84 +++++++++ .../nebula/client/meta/TestMetaClient.java | 63 +++++++ .../nebula/client/meta/TestMetaManager.java | 83 +++++++++ .../client/storage/MockStorageData.java | 101 +++++++++++ .../client/storage/StorageClientTest.java | 163 ++++++++++++++++++ .../resources/docker-compose-casigned.yaml | 26 +-- .../resources/docker-compose-selfsigned.yaml | 47 ++--- 16 files changed, 708 insertions(+), 63 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 91f3ee1b1..d6270e2da 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -41,6 +41,33 @@ jobs: cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d sleep 10 + docker-compose ps + popd + popd + + - name: Install nebula-graph with CA SSL + run: | + pushd tmp + mkdir ca + pushd ca + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-casigned.yaml . + docker-compose -f docker-compose-casigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-casigned.yaml ps + popd + popd + + - name: Install nebula-graph with Self SSL + run: | + pushd tmp + mkdir self + pushd self + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-selfsigned.yaml . + docker-compose -f docker-compose-selfsigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-selfsigned.yaml ps popd popd diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java index 395eca3a0..9dd055e58 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/RoundRobinLoadBalancer.java @@ -83,7 +83,6 @@ public boolean ping(HostAddress addr) { connection.close(); return true; } catch (IOErrorException | ClientServerIncompatibleException e) { - LOGGER.error("ping failed", e); return false; } } diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java index 41c74e478..4fe02c70e 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java @@ -13,8 +13,12 @@ import com.google.common.base.Charsets; import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.HostAddr; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; +import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.GetEdgeReq; @@ -43,12 +47,15 @@ import com.vesoft.nebula.meta.TagItem; import com.vesoft.nebula.meta.VerifyClientVersionReq; import com.vesoft.nebula.meta.VerifyClientVersionResp; +import com.vesoft.nebula.util.SslUtil; +import java.io.IOException; import java.util.Arrays; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Random; import java.util.Set; +import javax.net.ssl.SSLSocketFactory; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -63,6 +70,9 @@ public class MetaClient extends AbstractMetaClient { private static final int DEFAULT_EXECUTION_RETRY_SIZE = 3; private static final int RETRY_TIMES = 1; + private boolean enableSSL = false; + private SSLParam sslParam = null; + private MetaService.Client client; private final List addresses; @@ -88,6 +98,17 @@ public MetaClient(List addresses, int timeout, int connectionRetry, this.addresses = addresses; } + public MetaClient(List addresses, int timeout, int connectionRetry, + int executionRetry, boolean enableSSL, SSLParam sslParam) { + super(addresses, timeout, connectionRetry, executionRetry); + this.addresses = addresses; + this.enableSSL = enableSSL; + this.sslParam = sslParam; + if (enableSSL && sslParam == null) { + throw new IllegalArgumentException("SSL is enabled, but SSLParam is null."); + } + } + public void connect() throws TException, ClientServerIncompatibleException { doConnect(); @@ -106,8 +127,25 @@ private void doConnect() private void getClient(String host, int port) throws TTransportException, ClientServerIncompatibleException { - transport = new TSocket(host, port, timeout, timeout); - transport.open(); + if (enableSSL) { + SSLSocketFactory sslSocketFactory; + if (sslParam.getSignMode() == SSLParam.SignMode.CA_SIGNED) { + sslSocketFactory = SslUtil.getSSLSocketFactoryWithCA((CASignedSSLParam) sslParam); + } else { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithoutCA((SelfSignedSSLParam) sslParam); + } + try { + transport = new TSocket(sslSocketFactory.createSocket(host, port), timeout, + timeout); + } catch (IOException e) { + throw new TTransportException(IOErrorException.E_UNKNOWN, e); + } + } else { + transport = new TSocket(host, port, timeout, timeout); + transport.open(); + } + protocol = new TCompactProtocol(transport); client = new MetaService.Client(protocol); diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java index e26d389b2..5c6bbf185 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java @@ -10,6 +10,7 @@ import com.google.common.collect.Maps; import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.meta.EdgeItem; @@ -47,6 +48,10 @@ private class SpaceInfo { private MetaClient metaClient; private final ReentrantReadWriteLock lock = new ReentrantReadWriteLock(); + private static final int DEFAULT_TIMEOUT_MS = 1000; + private static final int DEFAULT_CONNECTION_RETRY_SIZE = 3; + private static final int DEFAULT_EXECUTION_RETRY_SIZE = 3; + /** * init the meta info cache */ @@ -57,6 +62,18 @@ public MetaManager(List address) fillMetaInfo(); } + /** + * init the meta info cache with more config + */ + public MetaManager(List address, int timeout, int connectionRetry, + int executionRetry, boolean enableSSL, SSLParam sslParam) + throws TException, ClientServerIncompatibleException { + metaClient = new MetaClient(address, timeout, connectionRetry, executionRetry, enableSSL, + sslParam); + metaClient.connect(); + fillMetaInfo(); + } + /** * close meta client */ diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java index c1b54fc1f..8a614df79 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java @@ -11,14 +11,22 @@ import com.facebook.thrift.protocol.TProtocol; import com.facebook.thrift.transport.TSocket; import com.facebook.thrift.transport.TTransport; +import com.facebook.thrift.transport.TTransportException; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; +import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.storage.GraphStorageService; import com.vesoft.nebula.storage.ScanEdgeRequest; import com.vesoft.nebula.storage.ScanEdgeResponse; import com.vesoft.nebula.storage.ScanVertexRequest; import com.vesoft.nebula.storage.ScanVertexResponse; +import com.vesoft.nebula.util.SslUtil; +import java.io.IOException; import java.net.InetAddress; import java.net.UnknownHostException; +import javax.net.ssl.SSLSocketFactory; public class GraphStorageConnection { protected TTransport transport = null; @@ -29,15 +37,37 @@ public class GraphStorageConnection { protected GraphStorageConnection() { } - protected GraphStorageConnection open(HostAddress address, int timeout) throws Exception { + protected GraphStorageConnection open(HostAddress address, int timeout, boolean enableSSL, + SSLParam sslParam) throws Exception { this.address = address; int newTimeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; - this.transport = new TSocket( - InetAddress.getByName(address.getHost()).getHostAddress(), - address.getPort(), - newTimeout, - newTimeout); - this.transport.open(); + if (enableSSL) { + SSLSocketFactory sslSocketFactory; + if (sslParam.getSignMode() == SSLParam.SignMode.CA_SIGNED) { + sslSocketFactory = SslUtil.getSSLSocketFactoryWithCA((CASignedSSLParam) sslParam); + } else { + sslSocketFactory = + SslUtil.getSSLSocketFactoryWithoutCA((SelfSignedSSLParam) sslParam); + } + try { + transport = + new TSocket( + sslSocketFactory.createSocket( + InetAddress.getByName(address.getHost()).getHostAddress(), + address.getPort()), + newTimeout, + newTimeout); + } catch (IOException e) { + throw new TTransportException(IOErrorException.E_UNKNOWN, e); + } + } else { + this.transport = new TSocket( + InetAddress.getByName(address.getHost()).getHostAddress(), + address.getPort(), + newTimeout, + newTimeout); + this.transport.open(); + } this.protocol = new TCompactProtocol(transport); client = new GraphStorageService.Client(protocol); return this; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java index d7c9b27f8..9de258c10 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java @@ -8,6 +8,7 @@ import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; import com.vesoft.nebula.client.meta.MetaManager; import com.vesoft.nebula.client.storage.scan.PartScanInfo; import com.vesoft.nebula.client.storage.scan.ScanEdgeResultIterator; @@ -34,6 +35,11 @@ public class StorageClient { private MetaManager metaManager; private final List addresses; private int timeout = 10000; // ms + private int connectionRetry = 3; + private int executionRetry = 1; + + private boolean enableSSL = false; + private SSLParam sslParam = null; /** * Get a Nebula Storage client that executes the scan query to get NebulaGraph's data with @@ -70,16 +76,35 @@ public StorageClient(List addresses, int timeout) { this.timeout = timeout; } + /** + * Get a Nebula Storage client that executes the scan query to get NebulaGraph's data with + * multi servers' hosts, timeout and ssl config. + */ + public StorageClient(List addresses, int timeout, int connectionRetry, + int executionRetry, boolean enableSSL, SSLParam sslParam) { + this(addresses, timeout); + this.connectionRetry = connectionRetry; + this.executionRetry = executionRetry; + this.enableSSL = enableSSL; + this.sslParam = sslParam; + if (enableSSL && sslParam == null) { + throw new IllegalArgumentException("SSL is enabled, but SSLParam is nul."); + } + } + /** * Connect to Nebula Storage server. * * @return true if connect successfully. */ public boolean connect() throws Exception { - connection.open(addresses.get(0), timeout); + connection.open(addresses.get(0), timeout, enableSSL, sslParam); StoragePoolConfig config = new StoragePoolConfig(); + config.setEnableSSL(enableSSL); + config.setSslParam(sslParam); pool = new StorageConnPool(config); - metaManager = new MetaManager(addresses); + metaManager = new MetaManager(addresses, timeout, connectionRetry, executionRetry, + enableSSL, sslParam); return true; } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java index 2521d408b..88472d9fe 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java @@ -56,7 +56,11 @@ public boolean validateObject(HostAddress hostAndPort, public void activateObject(HostAddress address, PooledObject pooledObject) throws Exception { - pooledObject.getObject().open(address, config.getTimeout()); + pooledObject.getObject().open( + address, + config.getTimeout(), + config.isEnableSSL(), + config.getSslParam()); } @Override diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java b/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java index 347fda67b..82c879ea6 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java @@ -7,6 +7,8 @@ package com.vesoft.nebula.client.storage; +import com.vesoft.nebula.client.graph.data.SSLParam; + public class StoragePoolConfig { // The min connections in pool for all addresses private int minConnsSize = 0; @@ -28,6 +30,10 @@ public class StoragePoolConfig { // the max total connection in pool for each key private int maxTotalPerKey = 10; + private boolean enableSSL = false; + + private SSLParam sslParam = null; + public int getMinConnsSize() { return minConnsSize; } @@ -75,4 +81,20 @@ public int getMaxTotalPerKey() { public void setMaxTotalPerKey(int maxTotalPerKey) { this.maxTotalPerKey = maxTotalPerKey; } + + public boolean isEnableSSL() { + return enableSSL; + } + + public void setEnableSSL(boolean enableSSL) { + this.enableSSL = enableSSL; + } + + public SSLParam getSslParam() { + return sslParam; + } + + public void setSslParam(SSLParam sslParam) { + this.sslParam = sslParam; + } } diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index 0718e985c..5140f7e0c 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -555,9 +555,6 @@ public void testSelfSignedSsl() { Session sslSession = null; NebulaPool sslPool = new NebulaPool(); try { - Runtime runtime = Runtime.getRuntime(); - runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-selfsigned.yaml up -d"); NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); @@ -566,8 +563,7 @@ public void testSelfSignedSsl() { "src/test/resources/ssl/selfsigned.pem", "src/test/resources/ssl/selfsigned.key", "vesoft")); - TimeUnit.SECONDS.sleep(45); - Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), + Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 7669)), nebulaSslPoolConfig)); sslSession = sslPool.getSession("root", "nebula", true); @@ -577,9 +573,6 @@ public void testSelfSignedSsl() { .getJSONObject(0).getJSONArray("row").toJSONString(); String exp = "[1]"; Assert.assertEquals(rowData, exp); - - runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-selfsigned.yaml down").waitFor(60, TimeUnit.SECONDS); } catch (Exception e) { e.printStackTrace(); assert false; @@ -596,10 +589,6 @@ public void testCASignedSsl() { Session sslSession = null; NebulaPool sslPool = new NebulaPool(); try { - Runtime runtime = Runtime.getRuntime(); - runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-casigned.yaml up -d"); - NebulaPoolConfig nebulaSslPoolConfig = new NebulaPoolConfig(); nebulaSslPoolConfig.setMaxConnSize(100); nebulaSslPoolConfig.setEnableSsl(true); @@ -607,7 +596,6 @@ public void testCASignedSsl() { "src/test/resources/ssl/casigned.pem", "src/test/resources/ssl/casigned.crt", "src/test/resources/ssl/casigned.key")); - TimeUnit.SECONDS.sleep(45); Assert.assertTrue(sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 8669)), nebulaSslPoolConfig)); sslSession = sslPool.getSession("root", "nebula", true); @@ -619,8 +607,6 @@ public void testCASignedSsl() { String exp = "[1]"; Assert.assertEquals(rowData, exp); - runtime.exec("docker-compose -f src/test/resources/docker-compose" - + "-casigned.yaml down").waitFor(60, TimeUnit.SECONDS); } catch (Exception e) { e.printStackTrace(); assert false; diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java index 2643824e4..1e8585b6f 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java @@ -7,8 +7,10 @@ package com.vesoft.nebula.client.meta; import com.vesoft.nebula.client.graph.NebulaPoolConfig; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.AuthFailedException; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; @@ -61,6 +63,24 @@ public static String createSpace() { return exec; } + public static String createSpaceCA() { + String exec = "CREATE SPACE IF NOT EXISTS testMetaCA(partition_num=10, " + + "vid_type=fixed_string(8));" + + "USE testMetaCA;" + + "CREATE TAG IF NOT EXISTS person(name string, age int);" + + "CREATE EDGE IF NOT EXISTS friend(likeness double);"; + return exec; + } + + public static String createSpaceSelf() { + String exec = "CREATE SPACE IF NOT EXISTS testMetaSelf(partition_num=10, " + + "vid_type=fixed_string(8));" + + "USE testMetaSelf;" + + "CREATE TAG IF NOT EXISTS person(name string, age int);" + + "CREATE EDGE IF NOT EXISTS friend(likeness double);"; + return exec; + } + public static void createMultiVersionTagAndEdge() { NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); nebulaPoolConfig.setMaxConnSize(100); @@ -99,4 +119,68 @@ public static void createMultiVersionTagAndEdge() { pool.close(); } } + + public static void createSpaceWithCASSL() { + NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); + nebulaPoolConfig.setMaxConnSize(100); + nebulaPoolConfig.setEnableSsl(true); + nebulaPoolConfig.setSslParam(new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key")); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 8669)); + NebulaPool pool = new NebulaPool(); + Session session = null; + try { + pool.init(addresses, nebulaPoolConfig); + session = pool.getSession("root", "nebula", true); + + ResultSet resp = session.execute(createSpaceCA()); + if (!resp.isSucceeded()) { + LOGGER.error("create space failed, {}", resp.getErrorMessage()); + assert (false); + } + Thread.sleep(5000); + + } catch (Exception e) { + LOGGER.error("create space with CA ssl error, ", e); + assert (false); + } finally { + if (session != null) { + session.release(); + } + pool.close(); + } + } + + public static void createSpaceWithSelfSSL() { + NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); + nebulaPoolConfig.setMaxConnSize(100); + nebulaPoolConfig.setEnableSsl(true); + nebulaPoolConfig.setSslParam(new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft")); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 7669)); + NebulaPool pool = new NebulaPool(); + Session session = null; + try { + pool.init(addresses, nebulaPoolConfig); + session = pool.getSession("root", "nebula", true); + ResultSet resp = session.execute(createSpaceSelf()); + if (!resp.isSucceeded()) { + LOGGER.error("create space failed, {}", resp.getErrorMessage()); + assert (false); + } + Thread.sleep(5000); + } catch (Exception e) { + LOGGER.error("create space with Self ssl error, ", e); + assert (false); + } finally { + if (session != null) { + session.release(); + } + pool.close(); + } + } } diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java index 6a0a53660..a450883f4 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java @@ -7,12 +7,18 @@ package com.vesoft.nebula.client.meta; import com.facebook.thrift.TException; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; +import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.client.util.ProcessUtil; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.IdName; import com.vesoft.nebula.meta.TagItem; +import java.io.IOException; +import java.util.Arrays; import java.util.List; import java.util.concurrent.TimeUnit; import junit.framework.TestCase; @@ -134,4 +140,61 @@ public void testListOnlineHosts() { assert (false); } } + + public void testCASignedSSLMetaClient() { + MetaClient metaClient = null; + try { + + // mock data with CA ssl + MockNebulaGraph.createSpaceWithCASSL(); + + SSLParam sslParam = new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key"); + + metaClient = new MetaClient(Arrays.asList(new HostAddress(address, 8559)), + 3000, 1, 1, true, sslParam); + metaClient.connect(); + + List tags = metaClient.getTags("testMetaCA"); + Assert.assertTrue(tags.size() >= 1); + assert (metaClient.getTag("testMetaCA", "person") != null); + } catch (Exception e) { + LOGGER.error("test CA signed ssl meta client failed, ", e); + assert (false); + } finally { + if (metaClient != null) { + metaClient.close(); + } + } + } + + public void testSelfSignedSSLMetaClient() { + MetaClient metaClient = null; + try { + + // mock data with Self ssl + MockNebulaGraph.createSpaceWithSelfSSL(); + + SSLParam sslParam = new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft"); + metaClient = new MetaClient(Arrays.asList(new HostAddress(address, 7559)), + 3000, 1, 1, true, sslParam); + metaClient.connect(); + + List tags = metaClient.getTags("testMetaSelf"); + Assert.assertTrue(tags.size() >= 1); + assert (metaClient.getTag("testMetaSelf", "person") != null); + } catch (Exception e) { + LOGGER.error("test Self signed ssl meta client failed, ", e); + assert (false); + } finally { + if (metaClient != null) { + metaClient.close(); + } + } + } } diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java index 9782a3924..992f38c75 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java @@ -7,14 +7,21 @@ package com.vesoft.nebula.client.meta; import com.vesoft.nebula.HostAddr; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; +import com.vesoft.nebula.client.util.ProcessUtil; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; +import java.io.IOException; import java.util.Arrays; import java.util.Collections; +import java.util.List; import java.util.Objects; +import java.util.concurrent.TimeUnit; import junit.framework.TestCase; import org.junit.Assert; @@ -111,4 +118,80 @@ public void testMultiVersionSchema() throws ClientServerIncompatibleException { assert (edgeItem.getVersion() == 1); assert (edgeItem.schema.getColumns().size() == 1); } + + + public void testCASignedSSLMetaManager() { + MetaManager metaManager = null; + try { + + // mock data with CA ssl + MockNebulaGraph.createSpaceWithCASSL(); + + SSLParam sslParam = new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key"); + + metaManager = new MetaManager(Arrays.asList(new HostAddress("127.0.0.1", + 8559)), 3000, 1, 1, true, sslParam); + + + assert (metaManager.getSpaceId("testMetaCA") > 0); + SpaceItem spaceItem = metaManager.getSpace("testMetaCA"); + assert Objects.equals("testMetaCA", new String(spaceItem.properties.getSpace_name())); + Assert.assertEquals(8, spaceItem.properties.getVid_type().getType_length()); + Assert.assertEquals(10, spaceItem.properties.getPartition_num()); + + // test get not existed space + try { + metaManager.getSpace("not_existed"); + Assert.fail(); + } catch (IllegalArgumentException e) { + Assert.assertTrue("We expected here", true); + } + } catch (Exception e) { + Assert.fail(); + } finally { + if (metaManager != null) { + metaManager.close(); + } + } + } + + public void testSelfSignedSSLMetaClient() { + MetaManager metaManager = null; + try { + + // mock data with Self ssl + MockNebulaGraph.createSpaceWithSelfSSL(); + + SSLParam sslParam = new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft"); + metaManager = new MetaManager(Arrays.asList(new HostAddress("127.0.0.1", 7559)), + 3000, 1, 1, true, sslParam); + + assert (metaManager.getSpaceId("testMetaSelf") > 0); + SpaceItem spaceItem = metaManager.getSpace("testMetaSelf"); + assert Objects.equals("testMetaSelf", new String(spaceItem.properties.getSpace_name())); + Assert.assertEquals(8, spaceItem.properties.getVid_type().getType_length()); + Assert.assertEquals(10, spaceItem.properties.getPartition_num()); + + // test get not existed space + try { + metaManager.getSpace("not_existed"); + Assert.fail(); + } catch (IllegalArgumentException e) { + Assert.assertTrue("We expected here", true); + } + } catch (Exception e) { + e.printStackTrace(); + Assert.fail(); + } finally { + if (metaManager != null) { + metaManager.close(); + } + } + } } diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java index 8a376b506..f8bdfea92 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java @@ -7,8 +7,10 @@ package com.vesoft.nebula.client.storage; import com.vesoft.nebula.client.graph.NebulaPoolConfig; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.graph.exception.AuthFailedException; import com.vesoft.nebula.client.graph.exception.ClientServerIncompatibleException; import com.vesoft.nebula.client.graph.exception.IOErrorException; @@ -66,6 +68,24 @@ public static String createSpace() { return exec; } + public static String createSpaceCa() { + String exec = "CREATE SPACE IF NOT EXISTS testStorageCA(partition_num=10," + + "vid_type=fixed_string(8));" + + "USE testStorageCA;" + + "CREATE TAG IF NOT EXISTS person(name string, age int);" + + "CREATE EDGE IF NOT EXISTS friend(likeness double);"; + return exec; + } + + public static String createSpaceSelf() { + String exec = "CREATE SPACE IF NOT EXISTS testStorageSelf(partition_num=10," + + "vid_type=fixed_string(8));" + + "USE testStorageSelf;" + + "CREATE TAG IF NOT EXISTS person(name string, age int);" + + "CREATE EDGE IF NOT EXISTS friend(likeness double);"; + return exec; + } + public static String insertData() { String exec = "INSERT VERTEX person(name, age) VALUES " + "\"1\":(\"Tom\", 18), " @@ -81,4 +101,85 @@ public static String insertData() { + "\"5\" -> \"1\":(5.9);"; return exec; } + + // mock data for CA ssl nebula service + public static void mockCASslData() { + NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); + nebulaPoolConfig.setMaxConnSize(100); + nebulaPoolConfig.setEnableSsl(true); + nebulaPoolConfig.setSslParam(new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key")); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 8669)); + NebulaPool pool = new NebulaPool(); + Session session = null; + try { + pool.init(addresses, nebulaPoolConfig); + session = pool.getSession("root", "nebula", true); + + ResultSet resp = session.execute(createSpaceCa()); + try { + Thread.sleep(6000); + } catch (InterruptedException e) { + e.printStackTrace(); + } + + ResultSet insertVertexResult = session.execute(insertData()); + if (!resp.isSucceeded() || !insertVertexResult.isSucceeded()) { + LOGGER.error("create space failed, {}", resp.getErrorMessage()); + LOGGER.error("insert vertex data failed, {}", insertVertexResult.getErrorMessage()); + assert (false); + } + } catch (UnknownHostException | NotValidConnectionException + | IOErrorException | AuthFailedException | ClientServerIncompatibleException e) { + e.printStackTrace(); + } finally { + if (session != null) { + session.release(); + } + pool.close(); + } + } + + // mock data for Self ssl nebula service + public static void mockSelfSslData() { + NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); + nebulaPoolConfig.setMaxConnSize(100); + nebulaPoolConfig.setEnableSsl(true); + nebulaPoolConfig.setSslParam(new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft")); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 8669)); + NebulaPool pool = new NebulaPool(); + Session session = null; + try { + pool.init(addresses, nebulaPoolConfig); + session = pool.getSession("root", "nebula", true); + + ResultSet resp = session.execute(createSpaceSelf()); + + try { + Thread.sleep(5000); + } catch (InterruptedException e) { + e.printStackTrace(); + } + + ResultSet insertVertexResult = session.execute(insertData()); + if (!resp.isSucceeded() || !insertVertexResult.isSucceeded()) { + LOGGER.error(resp.getErrorMessage()); + LOGGER.error(insertVertexResult.getErrorMessage()); + assert (false); + } + } catch (UnknownHostException | NotValidConnectionException + | IOErrorException | AuthFailedException | ClientServerIncompatibleException e) { + e.printStackTrace(); + } finally { + if (session != null) { + session.release(); + } + pool.close(); + } + } } diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java index 0b2722ee8..22f0e16a4 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java @@ -6,7 +6,10 @@ package com.vesoft.nebula.client.storage; +import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.client.graph.data.SSLParam; +import com.vesoft.nebula.client.graph.data.SelfSignedSSLParam; import com.vesoft.nebula.client.storage.data.EdgeRow; import com.vesoft.nebula.client.storage.data.EdgeTableRow; import com.vesoft.nebula.client.storage.data.VertexRow; @@ -15,9 +18,12 @@ import com.vesoft.nebula.client.storage.scan.ScanEdgeResultIterator; import com.vesoft.nebula.client.storage.scan.ScanVertexResult; import com.vesoft.nebula.client.storage.scan.ScanVertexResultIterator; +import com.vesoft.nebula.client.util.ProcessUtil; +import java.io.IOException; import java.io.UnsupportedEncodingException; import java.util.Arrays; import java.util.List; +import java.util.concurrent.TimeUnit; import org.junit.After; import org.junit.Assert; import org.junit.Before; @@ -360,4 +366,161 @@ public void testScanEdgeWithAllCols() { assert (result.isAllSuccess()); } } + + @Test + public void testCASignedSSL() { + // start nebula service with ssl enable + List address = null; + StorageClient sslClient = null; + try { + address = Arrays.asList(new HostAddress(ip, 8559)); + + // mock graph data + MockStorageData.mockCASslData(); + + SSLParam sslParam = new CASignedSSLParam( + "src/test/resources/ssl/casigned.pem", + "src/test/resources/ssl/casigned.crt", + "src/test/resources/ssl/casigned.key"); + sslClient = new StorageClient(address, 1000, 1, 1, true, sslParam); + sslClient.connect(); + + ScanVertexResultIterator resultIterator = sslClient.scanVertex( + "testStorageCA", + "person"); + while (resultIterator.hasNext()) { + ScanVertexResult result = null; + try { + result = resultIterator.next(); + } catch (Exception e) { + e.printStackTrace(); + assert (false); + } + if (result.isEmpty()) { + continue; + } + Assert.assertEquals(1, result.getPropNames().size()); + assert (result.getPropNames().get(0).equals("_vid")); + assert (result.isAllSuccess()); + + List rows = result.getVertices(); + for (VertexRow row : rows) { + try { + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(row.getVid().asString())); + } catch (UnsupportedEncodingException e) { + e.printStackTrace(); + assert (false); + } + assert (row.getProps().size() == 0); + } + + List tableRows = result.getVertexTableRows(); + for (VertexTableRow tableRow : tableRows) { + try { + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(tableRow.getVid().asString())); + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(tableRow.getString(0))); + } catch (UnsupportedEncodingException e) { + e.printStackTrace(); + assert (false); + } + } + } + } catch (Exception e) { + e.printStackTrace(); + assert (false); + } finally { + if (sslClient != null) { + try { + sslClient.close(); + } catch (Exception e) { + e.printStackTrace(); + } + } + } + } + + + @Test + public void testSelfSignedSSL() { + // start nebula service with ssl enable + List address = null; + StorageClient sslClient = null; + Runtime runtime = Runtime.getRuntime(); + try { + + address = Arrays.asList(new HostAddress(ip, 8559)); + + // mock graph data + MockStorageData.mockSelfSslData(); + + SSLParam sslParam = new SelfSignedSSLParam( + "src/test/resources/ssl/selfsigned.pem", + "src/test/resources/ssl/selfsigned.key", + "vesoft"); + sslClient = new StorageClient(address, 1000, 1, 1, true, sslParam); + sslClient.connect(); + + ScanVertexResultIterator resultIterator = sslClient.scanVertex( + "testStorageSelf", + "person"); + assertIterator(resultIterator); + } catch (Exception e) { + e.printStackTrace(); + assert (false); + } finally { + if (sslClient != null) { + try { + sslClient.close(); + } catch (Exception e) { + e.printStackTrace(); + } + } + } + } + + private void assertIterator(ScanVertexResultIterator resultIterator) { + while (resultIterator.hasNext()) { + ScanVertexResult result = null; + try { + result = resultIterator.next(); + } catch (Exception e) { + e.printStackTrace(); + assert (false); + } + if (result.isEmpty()) { + continue; + } + Assert.assertEquals(1, result.getPropNames().size()); + assert (result.getPropNames().get(0).equals("_vid")); + assert (result.isAllSuccess()); + + List rows = result.getVertices(); + for (VertexRow row : rows) { + try { + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(row.getVid().asString())); + } catch (UnsupportedEncodingException e) { + e.printStackTrace(); + assert (false); + } + assert (row.getProps().size() == 0); + } + + List tableRows = result.getVertexTableRows(); + for (VertexTableRow tableRow : tableRows) { + try { + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(tableRow.getVid().asString())); + assert (Arrays.asList("1", "2", "3", "4", "5") + .contains(tableRow.getString(0))); + } catch (UnsupportedEncodingException e) { + e.printStackTrace(); + assert (false); + } + } + } + } } diff --git a/client/src/test/resources/docker-compose-casigned.yaml b/client/src/test/resources/docker-compose-casigned.yaml index bfdd1b96d..cf55d12fd 100644 --- a/client/src/test/resources/docker-compose-casigned.yaml +++ b/client/src/test/resources/docker-compose-casigned.yaml @@ -6,10 +6,10 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 + - --meta_server_addrs=172.29.1.1:9559 - --local_ip=172.29.1.1 - --ws_ip=172.29.1.1 - - --port=8559 + - --port=9559 - --data_path=/data/meta - --log_dir=/logs - --v=0 @@ -19,7 +19,7 @@ services: - --ws_h2_port=11000 - --cert_path=/share/resources/test.derive.crt - --key_path=/share/resources/test.derive.key - - --password_path=/share/resources/test.ca.password + - --ca_path=/share/resources/test.ca.pem - --enable_ssl=true healthcheck: test: ["CMD", "curl", "-f", "http://172.29.1.1:11000/status"] @@ -28,7 +28,7 @@ services: retries: 3 start_period: 20s ports: - - "8559:8559" + - "8559:9559" - 11000 - 11002 volumes: @@ -48,10 +48,10 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 + - --meta_server_addrs=172.29.1.1:9559 - --local_ip=172.29.2.1 - --ws_ip=172.29.2.1 - - --port=8779 + - --port=9779 - --data_path=/data/storage - --log_dir=/logs - --v=0 @@ -61,7 +61,7 @@ services: - --ws_h2_port=12000 - --cert_path=/share/resources/test.derive.crt - --key_path=/share/resources/test.derive.key - - --password_path=/share/resources/test.ca.password + - --ca_path=/share/resources/test.ca.pem - --enable_ssl=true depends_on: - metad-casigned @@ -72,7 +72,7 @@ services: retries: 3 start_period: 20s ports: - - "8779:8779" + - "8779:9779" - 12000 - 12002 volumes: @@ -92,8 +92,9 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 - - --port=8669 + - --meta_server_addrs=172.29.1.1:9559 + - --port=9669 + - --local_ip=172.29.3.1 - --ws_ip=172.29.3.1 - --log_dir=/logs - --v=0 @@ -103,7 +104,7 @@ services: - --ws_h2_port=13000 - --cert_path=/share/resources/test.derive.crt - --key_path=/share/resources/test.derive.key - - --password_path=/share/resources/test.ca.password + - --ca_path=/share/resources/test.ca.pem - --enable_ssl=true depends_on: - metad-casigned @@ -114,10 +115,11 @@ services: retries: 3 start_period: 20s ports: - - "8669:8669" + - "8669:9669" - 13000 - 13002 volumes: + - ./data/graph:/data/graph:Z - ./logs/graph:/logs:Z - ./ssl:/share/resources:Z networks: diff --git a/client/src/test/resources/docker-compose-selfsigned.yaml b/client/src/test/resources/docker-compose-selfsigned.yaml index aeac1a60a..8a5a71d84 100644 --- a/client/src/test/resources/docker-compose-selfsigned.yaml +++ b/client/src/test/resources/docker-compose-selfsigned.yaml @@ -6,10 +6,10 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 - - --local_ip=172.29.1.1 - - --ws_ip=172.29.1.1 - - --port=8559 + - --meta_server_addrs=172.30.1.1:9559 + - --local_ip=172.30.1.1 + - --ws_ip=172.30.1.1 + - --port=9559 - --data_path=/data/meta - --log_dir=/logs - --v=0 @@ -22,22 +22,22 @@ services: - --password_path=/share/resources/test.ca.password - --enable_ssl=true healthcheck: - test: ["CMD", "curl", "-f", "http://172.29.1.1:11000/status"] + test: ["CMD", "curl", "-f", "http://172.30.1.1:11000/status"] interval: 30s timeout: 10s retries: 3 start_period: 20s ports: - - "8559:8559" + - "7559:9559" - 11000 - 11002 volumes: - - ./data/meta:/data/meta:Z + - ./data/meta_self:/data/meta:Z - ./logs/meta:/logs:Z - ./ssl:/share/resources:Z networks: nebula-net-selfsigned: - ipv4_address: 172.29.1.1 + ipv4_address: 172.30.1.1 restart: on-failure cap_add: - SYS_PTRACE @@ -48,10 +48,10 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 - - --local_ip=172.29.2.1 - - --ws_ip=172.29.2.1 - - --port=8779 + - --meta_server_addrs=172.30.1.1:9559 + - --local_ip=172.30.2.1 + - --ws_ip=172.30.2.1 + - --port=9779 - --data_path=/data/storage - --log_dir=/logs - --v=0 @@ -66,22 +66,22 @@ services: depends_on: - metad-selfsigned healthcheck: - test: ["CMD", "curl", "-f", "http://172.29.2.1:12000/status"] + test: ["CMD", "curl", "-f", "http://172.30.2.1:12000/status"] interval: 30s timeout: 10s retries: 3 start_period: 20s ports: - - "8779:8779" + - "7779:9779" - 12000 - 12002 volumes: - - ./data/storage:/data/storage:Z + - ./data/storage_self:/data/storage:Z - ./logs/storage:/logs:Z - ./ssl:/share/resources:Z networks: nebula-net-selfsigned: - ipv4_address: 172.29.2.1 + ipv4_address: 172.30.2.1 restart: on-failure cap_add: - SYS_PTRACE @@ -92,9 +92,9 @@ services: USER: root TZ: "${TZ}" command: - - --meta_server_addrs=172.29.1.1:8559 - - --port=8669 - - --ws_ip=172.29.3.1 + - --meta_server_addrs=172.30.1.1:9559 + - --port=9669 + - --ws_ip=172.30.3.1 - --log_dir=/logs - --v=0 - --minloglevel=0 @@ -108,21 +108,22 @@ services: depends_on: - metad-selfsigned healthcheck: - test: ["CMD", "curl", "-f", "http://172.29.3.1:13000/status"] + test: ["CMD", "curl", "-f", "http://172.30.3.1:13000/status"] interval: 30s timeout: 10s retries: 3 start_period: 20s ports: - - "8669:8669" + - "7669:9669" - 13000 - 13002 volumes: + - ./data/graph_self:/data/graph:Z - ./logs/graph:/logs:Z - ./ssl:/share/resources:Z networks: nebula-net-selfsigned: - ipv4_address: 172.29.3.1 + ipv4_address: 172.30.3.1 restart: on-failure cap_add: - SYS_PTRACE @@ -132,4 +133,4 @@ networks: ipam: driver: default config: - - subnet: 172.29.0.0/16 + - subnet: 172.30.0.0/16 From 22277fe6fd76246c497b6466000f0e982a7b3805 Mon Sep 17 00:00:00 2001 From: Anqi Date: Wed, 10 Nov 2021 11:56:43 +0800 Subject: [PATCH 09/25] fix workflow for deploy (#384) --- .github/workflows/deploy_release.yaml | 27 +++++++++++++++++++++++++ .github/workflows/deploy_snapshot.yaml | 28 ++++++++++++++++++++++++++ 2 files changed, 55 insertions(+) diff --git a/.github/workflows/deploy_release.yaml b/.github/workflows/deploy_release.yaml index cc61bbdd9..7a1c3a147 100644 --- a/.github/workflows/deploy_release.yaml +++ b/.github/workflows/deploy_release.yaml @@ -26,6 +26,33 @@ jobs: cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d sleep 10 + docker-compose ps + popd + popd + + - name: Install nebula-graph with CA SSL + run: | + pushd tmp + mkdir ca + pushd ca + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-casigned.yaml . + docker-compose -f docker-compose-casigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-casigned.yaml ps + popd + popd + + - name: Install nebula-graph with Self SSL + run: | + pushd tmp + mkdir self + pushd self + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-selfsigned.yaml . + docker-compose -f docker-compose-selfsigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-selfsigned.yaml ps popd popd diff --git a/.github/workflows/deploy_snapshot.yaml b/.github/workflows/deploy_snapshot.yaml index 5f55ffaff..b854b97cc 100644 --- a/.github/workflows/deploy_snapshot.yaml +++ b/.github/workflows/deploy_snapshot.yaml @@ -27,8 +27,36 @@ jobs: cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d sleep 10 + docker-compose ps popd popd + + - name: Install nebula-graph with CA SSL + run: | + pushd tmp + mkdir ca + pushd ca + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-casigned.yaml . + docker-compose -f docker-compose-casigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-casigned.yaml ps + popd + popd + + - name: Install nebula-graph with Self SSL + run: | + pushd tmp + mkdir self + pushd self + cp -r ../../client/src/test/resources/ssl . + cp ../../client/src/test/resources/docker-compose-selfsigned.yaml . + docker-compose -f docker-compose-selfsigned.yaml up -d + sleep 30 + docker-compose -f docker-compose-selfsigned.yaml ps + popd + popd + - name: Deploy Snapshot to Maven package uses: samuelmeuli/action-maven-publish@v1 with: From 4b55c93f8e047cc46e61451ab27466ecd3dd4e89 Mon Sep 17 00:00:00 2001 From: Anqi Date: Wed, 10 Nov 2021 15:04:00 +0800 Subject: [PATCH 10/25] remove Common Clause License (#385) --- .travis.yml | 3 +-- LICENSES/CC-1.0.txt | 14 -------------- .../nebula/client/graph/NebulaPoolConfig.java | 3 +-- .../nebula/client/graph/SessionsManagerConfig.java | 3 +-- .../nebula/client/graph/data/BaseDataObject.java | 3 +-- .../nebula/client/graph/data/CASignedSSLParam.java | 3 +-- .../client/graph/data/CoordinateWrapper.java | 3 +-- .../nebula/client/graph/data/DateTimeWrapper.java | 3 +-- .../nebula/client/graph/data/DateWrapper.java | 3 +-- .../nebula/client/graph/data/GeographyWrapper.java | 3 +-- .../nebula/client/graph/data/HostAddress.java | 3 +-- .../client/graph/data/LineStringWrapper.java | 3 +-- .../com/vesoft/nebula/client/graph/data/Node.java | 3 +-- .../nebula/client/graph/data/PathWrapper.java | 3 +-- .../nebula/client/graph/data/PointWrapper.java | 3 +-- .../nebula/client/graph/data/PolygonWrapper.java | 3 +-- .../nebula/client/graph/data/Relationship.java | 3 +-- .../vesoft/nebula/client/graph/data/ResultSet.java | 3 +-- .../vesoft/nebula/client/graph/data/SSLParam.java | 3 +-- .../client/graph/data/SelfSignedSSLParam.java | 3 +-- .../vesoft/nebula/client/graph/data/TimeUtil.java | 3 +-- .../nebula/client/graph/data/TimeWrapper.java | 3 +-- .../nebula/client/graph/data/ValueWrapper.java | 3 +-- .../graph/exception/AuthFailedException.java | 3 +-- .../ClientServerIncompatibleException.java | 3 +-- .../client/graph/exception/IOErrorException.java | 3 +-- .../graph/exception/InvalidConfigException.java | 3 +-- .../graph/exception/InvalidSessionException.java | 3 +-- .../graph/exception/InvalidValueException.java | 3 +-- .../exception/NotValidConnectionException.java | 3 +-- .../vesoft/nebula/client/graph/net/AuthResult.java | 3 +-- .../vesoft/nebula/client/graph/net/NebulaPool.java | 3 +-- .../vesoft/nebula/client/graph/net/Session.java | 3 +-- .../nebula/client/graph/net/SessionWrapper.java | 3 +-- .../nebula/client/graph/net/SessionsManager.java | 3 +-- .../nebula/client/graph/net/SyncConnection.java | 3 +-- .../nebula/client/meta/AbstractMetaClient.java | 3 +-- .../com/vesoft/nebula/client/meta/MetaCache.java | 3 +-- .../com/vesoft/nebula/client/meta/MetaClient.java | 3 +-- .../com/vesoft/nebula/client/meta/MetaManager.java | 3 +-- .../meta/exception/ExecuteFailedException.java | 3 +-- .../client/storage/GraphStorageConnection.java | 3 +-- .../nebula/client/storage/StorageClient.java | 3 +-- .../nebula/client/storage/StorageConnPool.java | 3 +-- .../client/storage/StorageConnPoolFactory.java | 3 +-- .../nebula/client/storage/StoragePoolConfig.java | 6 ++---- .../nebula/client/storage/data/BaseTableRow.java | 3 +-- .../vesoft/nebula/client/storage/data/EdgeRow.java | 3 +-- .../nebula/client/storage/data/EdgeTableRow.java | 3 +-- .../nebula/client/storage/data/ScanStatus.java | 6 ++---- .../nebula/client/storage/data/VertexRow.java | 3 +-- .../nebula/client/storage/data/VertexTableRow.java | 3 +-- .../client/storage/processor/EdgeProcessor.java | 3 +-- .../client/storage/processor/VertexProcessor.java | 3 +-- .../nebula/client/storage/scan/PartScanInfo.java | 3 +-- .../nebula/client/storage/scan/PartScanQueue.java | 3 +-- .../nebula/client/storage/scan/ScanEdgeResult.java | 3 +-- .../storage/scan/ScanEdgeResultIterator.java | 3 +-- .../client/storage/scan/ScanResultIterator.java | 3 +-- .../client/storage/scan/ScanVertexResult.java | 3 +-- .../storage/scan/ScanVertexResultIterator.java | 3 +-- .../com/vesoft/nebula/encoder/NebulaCodec.java | 3 +-- .../com/vesoft/nebula/encoder/NebulaCodecImpl.java | 3 +-- .../java/com/vesoft/nebula/encoder/RowWriter.java | 3 +-- .../com/vesoft/nebula/encoder/RowWriterImpl.java | 3 +-- .../com/vesoft/nebula/encoder/SchemaProvider.java | 3 +-- .../vesoft/nebula/encoder/SchemaProviderImpl.java | 3 +-- .../main/java/com/vesoft/nebula/util/SslUtil.java | 3 +-- .../vesoft/nebula/client/graph/data/TestData.java | 3 +-- .../client/graph/data/TestDataFromServer.java | 3 +-- .../client/graph/net/TestConnectionPool.java | 3 +-- .../nebula/client/graph/net/TestSession.java | 3 +-- .../client/graph/net/TestSessionsManager.java | 3 +-- .../client/graph/net/TestSyncConnection.java | 3 +-- .../vesoft/nebula/client/meta/MockNebulaGraph.java | 3 +-- .../vesoft/nebula/client/meta/TestMetaClient.java | 3 +-- .../vesoft/nebula/client/meta/TestMetaManager.java | 3 +-- .../nebula/client/storage/MockStorageData.java | 3 +-- .../com/vesoft/nebula/client/storage/MockUtil.java | 3 +-- .../nebula/client/storage/StorageClientTest.java | 3 +-- .../nebula/client/storage/StorageConnPoolTest.java | 3 +-- .../storage/processor/EdgeProcessorTest.java | 3 +-- .../storage/processor/VertexProcessorTest.java | 3 +-- .../client/storage/scan/PartScanQueueTest.java | 3 +-- .../com/vesoft/nebula/client/util/ProcessUtil.java | 3 +-- .../vesoft/nebula/encoder/MetaCacheImplTest.java | 3 +-- .../com/vesoft/nebula/encoder/TestEncoder.java | 3 +-- .../vesoft/nebula/examples/GraphClientExample.java | 3 +-- .../nebula/examples/StorageClientExample.java | 3 +-- 89 files changed, 90 insertions(+), 194 deletions(-) delete mode 100644 LICENSES/CC-1.0.txt diff --git a/.travis.yml b/.travis.yml index b75f481f6..f778bf1c2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,6 @@ # Copyright (c) 2019 vesoft inc. All rights reserved. # -# This source code is licensed under Apache 2.0 License, -# attached with Common Clause Condition 1.0, found in the LICENSES directory. +# This source code is licensed under Apache 2.0 License. language: java diff --git a/LICENSES/CC-1.0.txt b/LICENSES/CC-1.0.txt deleted file mode 100644 index a1ab12658..000000000 --- a/LICENSES/CC-1.0.txt +++ /dev/null @@ -1,14 +0,0 @@ -"Commons Clause" License Condition v1.0 - -The Software is provided to you by the Licensor under the License, as defined below, subject to the following condition. - -Without limiting other conditions in the License, the grant of rights under the License will not include, and the License does not grant to you, the right to Sell the Software. - -For purposes of the foregoing, "Sell" means practicing any or all of the rights granted to you under the License to provide to third parties, for a fee or other considerationon (including without limitation fees for hosting or consulting/support services related to the Software), a product or service whose value derives, entirely or substantially, from the functionality of the Software. Any license notice or attribution required by the License must also include this Commons Clause License Condition notice. - -Software: Nebula Graph [Software in this repository] - -License: Apache 2.0 [https://www.apache.org/licenses/LICENSE-2.0.html] - -Licensor: vesoft inc. - diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java b/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java index 60bba75ea..5c064a833 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/NebulaPoolConfig.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/SessionsManagerConfig.java b/client/src/main/java/com/vesoft/nebula/client/graph/SessionsManagerConfig.java index 83bb129c8..6285cb3f4 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/SessionsManagerConfig.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/SessionsManagerConfig.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/BaseDataObject.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/BaseDataObject.java index 6c8c77d0b..1b3e83197 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/BaseDataObject.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/BaseDataObject.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java index 9667c70f9..fd320c663 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/CASignedSSLParam.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java index 2d95a84e4..8d4f236fc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/CoordinateWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/DateTimeWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/DateTimeWrapper.java index 088e00160..92ef74781 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/DateTimeWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/DateTimeWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/DateWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/DateWrapper.java index 34239eb2d..a2ea64eb1 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/DateWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/DateWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java index 7a9962af7..b7b56e279 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/GeographyWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/HostAddress.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/HostAddress.java index efcc8af92..0fa8918d2 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/HostAddress.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/HostAddress.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java index f1ca7baf0..d0091c9f2 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/LineStringWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/Node.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/Node.java index 50919da4c..c78c314c3 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/Node.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/Node.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/PathWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/PathWrapper.java index 6ad28ee4b..e582e8964 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/PathWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/PathWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java index 85fab7095..14dc85c21 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/PointWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java index ee6b2d377..83dd53a38 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/PolygonWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/Relationship.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/Relationship.java index b0404aa10..d7e11befd 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/Relationship.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/Relationship.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java index 48a6b0208..a8a8c71dc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java index 1a19ec48d..c31608d8d 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/SSLParam.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java index d10046a6d..d8fee75cd 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/SelfSignedSSLParam.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeUtil.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeUtil.java index 25ff46235..c2113c09b 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeUtil.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeUtil.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeWrapper.java index 2810e4ea4..a394f97bf 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/TimeWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java index 3e3986674..600f66e9e 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/AuthFailedException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/AuthFailedException.java index 72bf834fe..faa9832c2 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/AuthFailedException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/AuthFailedException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java index 6287a381f..d4bdf3f51 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/ClientServerIncompatibleException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/IOErrorException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/IOErrorException.java index 6231b5435..10f7aa615 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/IOErrorException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/IOErrorException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2019 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidConfigException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidConfigException.java index ac6e6e3f9..6b3d40162 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidConfigException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidConfigException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidSessionException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidSessionException.java index 194e76dc8..83c07d5c8 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidSessionException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidSessionException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidValueException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidValueException.java index a040d6a86..0b7703f14 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidValueException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/InvalidValueException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/exception/NotValidConnectionException.java b/client/src/main/java/com/vesoft/nebula/client/graph/exception/NotValidConnectionException.java index fd064db82..5501d8044 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/exception/NotValidConnectionException.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/exception/NotValidConnectionException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2019 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/AuthResult.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/AuthResult.java index 3e31b564d..8237153f1 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/AuthResult.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/AuthResult.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java index 54c0c4670..ec4d419f1 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/NebulaPool.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java index 3b216910a..940843617 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java index c514264a2..faa2cf2dd 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionWrapper.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java index 9c1aa9a88..6fe4da3dc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SessionsManager.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java index d07bf5ae1..07e625aae 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java index 2b154110d..c74e30ac3 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaCache.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaCache.java index 71cd1a453..aa3a6a0b6 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaCache.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaCache.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java index 4fe02c70e..a5cfa60b8 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java index 5c6bbf185..8416b0fd0 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/exception/ExecuteFailedException.java b/client/src/main/java/com/vesoft/nebula/client/meta/exception/ExecuteFailedException.java index a8a877e18..a371f7d36 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/exception/ExecuteFailedException.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/exception/ExecuteFailedException.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta.exception; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java index 8a614df79..a3884cea5 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java index 9de258c10..f66bb05e7 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPool.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPool.java index 988f668fb..c9ae1ed2b 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPool.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPool.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java index 88472d9fe..7bb1515ad 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageConnPoolFactory.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java b/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java index 82c879ea6..a458ce0bc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StoragePoolConfig.java @@ -1,8 +1,6 @@ -/* - * Copyright (c) 2020 vesoft inc. All rights reserved. +/* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java index 97035c495..9e30afeee 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeRow.java index 6bab5ff4f..f934cb50a 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeRow.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeTableRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeTableRow.java index ca2a776fd..834eee4f8 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeTableRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/EdgeTableRow.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/ScanStatus.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/ScanStatus.java index 912b22151..1441bd0c3 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/ScanStatus.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/ScanStatus.java @@ -1,8 +1,6 @@ -/* - * Copyright (c) 2020 vesoft inc. All rights reserved. +/* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexRow.java index 1aa0fa6fd..28e04c6eb 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexRow.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexTableRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexTableRow.java index 2c3c473a9..8c5306838 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexTableRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/VertexTableRow.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.data; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java b/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java index 1ba09c555..3fdade027 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.processor; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java b/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java index 0c7d2e029..7dbc63018 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.processor; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java index 7b81f8da8..e72f3b40d 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanQueue.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanQueue.java index 6f246d71c..676664c86 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanQueue.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanQueue.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java index 42c51d003..e2a98d461 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java index fdee8a347..2fd926391 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java index fbf6e3764..01327d38a 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java index 7d552f1f9..2bb72faf9 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java index 5b6355b82..7271a526f 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodec.java b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodec.java index 4f7247991..e5c53de3a 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodec.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodec.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java index 276bd006e..605725eef 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java index 89dcb1650..492a1986d 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java index ce21c58bc..9a0fab6b7 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java index 63897d847..9f6940134 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java index d964e0f66..6aebb6298 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/main/java/com/vesoft/nebula/util/SslUtil.java b/client/src/main/java/com/vesoft/nebula/util/SslUtil.java index e75087e10..82133e95e 100644 --- a/client/src/main/java/com/vesoft/nebula/util/SslUtil.java +++ b/client/src/main/java/com/vesoft/nebula/util/SslUtil.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.util; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java index 54af89306..b0175a7e4 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index 5140f7e0c..03bdb5615 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.data; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java index ba7a972a9..77b2bd5d6 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestConnectionPool.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java index e598d6132..35b197b74 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java index 7f1fc6704..e9aca15ff 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSessionsManager.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSyncConnection.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSyncConnection.java index 8751fb247..2cd7d8ca1 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSyncConnection.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSyncConnection.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.graph.net; diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java index 1e8585b6f..d94304ed5 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/MockNebulaGraph.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java index a450883f4..a805fcb96 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java index 992f38c75..0d6ceeb74 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.meta; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java index f8bdfea92..f75d5860e 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java index 649e73a56..284a36201 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java index 22f0e16a4..ea303400e 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/StorageConnPoolTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/StorageConnPoolTest.java index 710c595e5..25d532da7 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/StorageConnPoolTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/StorageConnPoolTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/processor/EdgeProcessorTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/processor/EdgeProcessorTest.java index bfe64b9cc..34cd08b6f 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/processor/EdgeProcessorTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/processor/EdgeProcessorTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.processor; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java index ebbdb8300..341d4f8d4 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/processor/VertexProcessorTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.processor; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java index 580ae4e1e..646f4018d 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.storage.scan; diff --git a/client/src/test/java/com/vesoft/nebula/client/util/ProcessUtil.java b/client/src/test/java/com/vesoft/nebula/client/util/ProcessUtil.java index 04f65e341..04c1863ae 100644 --- a/client/src/test/java/com/vesoft/nebula/client/util/ProcessUtil.java +++ b/client/src/test/java/com/vesoft/nebula/client/util/ProcessUtil.java @@ -1,7 +1,6 @@ /* Copyright (c) 2021 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.client.util; diff --git a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java index 09bda6469..483c73560 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.encoder; diff --git a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java index 1e976faf8..31ed6fb08 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package test.java.com.vesoft.nebula.encoder; diff --git a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java index f9e0c1ce7..3204d461c 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.examples; diff --git a/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java index 39cab78c3..bd0608878 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java @@ -1,7 +1,6 @@ /* Copyright (c) 2020 vesoft inc. All rights reserved. * - * This source code is licensed under Apache 2.0 License, - * attached with Common Clause Condition 1.0, found in the LICENSES directory. + * This source code is licensed under Apache 2.0 License. */ package com.vesoft.nebula.examples; From f29e978e66989b33deb6c84b4537143c9fcf8433 Mon Sep 17 00:00:00 2001 From: "jie.wang" <38901892+jievince@users.noreply.github.com> Date: Thu, 18 Nov 2021 10:34:40 +0800 Subject: [PATCH 11/25] support geo encoder (#380) * support geo encoder * debug * remove debug log * let WKBWriter use machine byte order * add null test for geo * debug * format code --- .gitignore | 6 + .../nebula/encoder/NebulaCodecImpl.java | 5 +- .../com/vesoft/nebula/encoder/RowWriter.java | 3 + .../vesoft/nebula/encoder/RowWriterImpl.java | 108 +++++++++++++++++- .../vesoft/nebula/encoder/SchemaProvider.java | 2 + .../nebula/encoder/SchemaProviderImpl.java | 18 ++- .../nebula/encoder/MetaCacheImplTest.java | 14 +++ .../vesoft/nebula/encoder/TestEncoder.java | 57 ++++++++- pom.xml | 10 ++ 9 files changed, 212 insertions(+), 11 deletions(-) diff --git a/.gitignore b/.gitignore index 84e7a6bca..ffbdb448d 100644 --- a/.gitignore +++ b/.gitignore @@ -29,8 +29,14 @@ target/ .idea/ .eclipse/ *.iml +.vscode/ +.settings +.project +client/.classpath spark-importer.ipr spark-importer.iws .DS_Store + +examples/ diff --git a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java index 605725eef..8e9e0345c 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/NebulaCodecImpl.java @@ -8,6 +8,7 @@ import com.vesoft.nebula.meta.ColumnDef; import com.vesoft.nebula.meta.ColumnTypeDef; import com.vesoft.nebula.meta.EdgeItem; +import com.vesoft.nebula.meta.GeoShape; import com.vesoft.nebula.meta.Schema; import com.vesoft.nebula.meta.TagItem; import java.nio.ByteBuffer; @@ -201,11 +202,13 @@ private SchemaProviderImpl genSchemaProvider(long ver, Schema schema) { boolean nullable = col.isSetNullable() && col.isNullable(); boolean hasDefault = col.isSetDefault_value(); int len = type.isSetType_length() ? type.getType_length() : 0; + GeoShape geoShape = type.isSetGeo_shape() ? type.getGeo_shape() : GeoShape.ANY; schemaProvider.addField(new String(col.getName()), type.type.getValue(), len, nullable, - hasDefault ? col.getDefault_value() : null); + hasDefault ? col.getDefault_value() : null, + geoShape.getValue()); } return schemaProvider; } diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java index 492a1986d..774e0e1a5 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriter.java @@ -7,6 +7,7 @@ import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Geography; import com.vesoft.nebula.Time; public interface RowWriter { @@ -33,5 +34,7 @@ public interface RowWriter { void write(int index, DateTime v); + void write(int index, Geography v); + byte[] encodeStr(); } diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java index 9a0fab6b7..65d8e1c6a 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java @@ -5,8 +5,13 @@ package com.vesoft.nebula.encoder; +import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Geography; +import com.vesoft.nebula.LineString; +import com.vesoft.nebula.Point; +import com.vesoft.nebula.Polygon; import com.vesoft.nebula.Time; import com.vesoft.nebula.Value; import com.vesoft.nebula.meta.PropertyType; @@ -15,6 +20,10 @@ import java.util.ArrayList; import java.util.Collections; import java.util.List; +import org.apache.commons.codec.binary.Hex; +import org.locationtech.jts.geom.GeometryFactory; +import org.locationtech.jts.io.ByteOrderValues; +import org.locationtech.jts.io.WKBWriter; public class RowWriterImpl implements RowWriter { private final SchemaProviderImpl schema; @@ -509,6 +518,7 @@ public void write(int index, byte[] v) { } int offset = headerLen + numNullBytes + field.offset(); switch (typeEnum) { + case GEOGRAPHY: case STRING: { strList.add(v); outOfSpaceStr = true; @@ -625,6 +635,31 @@ public void write(int index, DateTime v) { isSet.set(index, true); } + @Override + public void write(int index, Geography v) { + SchemaProvider.Field field = schema.field(index); + PropertyType typeEnum = PropertyType.findByValue(field.type()); + if (typeEnum == null) { + throw new RuntimeException("Incorrect field type " + field.type()); + } + if (typeEnum == PropertyType.GEOGRAPHY) { + if (field.geoShape() != 0 && field.geoShape() != v.getSetField()) { + throw new RuntimeException("Incorrect geo shape, expect " + + field.geoShape() + ", got " + + v.getSetField()); + } + } else { + throw new RuntimeException("Value: " + v + "'s type is unexpected"); + } + org.locationtech.jts.geom.Geometry jtsGeom = convertGeographyToJTSGeometry(v); + byte[] wkb = new org.locationtech.jts.io + .WKBWriter(2, this.byteOrder == ByteOrder.BIG_ENDIAN + ? ByteOrderValues.BIG_ENDIAN + : ByteOrderValues.LITTLE_ENDIAN) + .write(jtsGeom); + write(index, wkb); + } + @Override public byte[] encodeStr() { return buf.array(); @@ -666,6 +701,8 @@ public void setValue(int index, Object value) { write(index, (Date)value); } else if (value instanceof DateTime) { write(index, (DateTime)value); + } else if (value instanceof Geography) { + write(index, (Geography)value); } else { throw new RuntimeException("Unsupported value object `" + value.getClass() + "\""); } @@ -708,6 +745,9 @@ public void setValue(int index, Value value) { case Value.DTVAL: write(index, value.getDtVal()); break; + case Value.GGVAL: + write(index, value.getGgVal()); + break; default: throw new RuntimeException( "Unknown value: " + value.getFieldValue().getClass() @@ -790,6 +830,9 @@ public void checkUnsetFields() { // case Value.DTVAL: // write(i, defVal.getDtVal()); // break; + // case Value.GGVAL: + // write(i, defVal.getGgVal()); + // break; // default: // throw new RuntimeException("Unsupported default value type"); // } @@ -821,7 +864,8 @@ public ByteBuffer processOutOfSpace() { if (typeEnum == null) { throw new RuntimeException("Incorrect field type " + field.type()); } - if (typeEnum != PropertyType.STRING) { + if (typeEnum != PropertyType.STRING + && typeEnum != PropertyType.GEOGRAPHY) { continue; } int offset = headerLen + numNullBytes + field.offset(); @@ -867,4 +911,66 @@ private long getTimestamp() { long nanoTime = System.nanoTime(); return curTime + (nanoTime - nanoTime / 1000000 * 1000000) / 1000; } + + public org.locationtech.jts.geom.Geometry + convertGeographyToJTSGeometry(Geography geog) { + GeometryFactory geomFactory = new GeometryFactory(); + switch (geog.getSetField()) { + case Geography.PTVAL: { + Point point = geog.getPtVal(); + Coordinate coord = point.getCoord(); + return geomFactory.createPoint( + new org.locationtech.jts.geom.Coordinate(coord.x, coord.y)); + } + case Geography.LSVAL: { + LineString line = geog.getLsVal(); + List coordList = line.getCoordList(); + + List jtsCoordList = + new ArrayList<>(); + for (int i = 0; i < coordList.size(); ++i) { + jtsCoordList.add(new org.locationtech.jts.geom.Coordinate( + coordList.get(i).x, coordList.get(i).y)); + } + org.locationtech.jts.geom.Coordinate[] jtsCoordArray = + new org.locationtech.jts.geom.Coordinate[jtsCoordList.size()]; + return geomFactory.createLineString( + jtsCoordList.toArray(jtsCoordArray)); + } + case Geography.PGVAL: { + Polygon polygon = geog.getPgVal(); + List> coordListList = polygon.getCoordListList(); + if (coordListList.isEmpty()) { + throw new RuntimeException("Polygon must at least contain one loop"); + } + + List rings = new ArrayList<>(); + for (int i = 0; i < coordListList.size(); ++i) { + List coordList = coordListList.get(i); + List jtsCoordList = + new ArrayList<>(); + for (int j = 0; j < coordList.size(); ++j) { + jtsCoordList.add(new org.locationtech.jts.geom.Coordinate( + coordList.get(j).x, coordList.get(j).y)); + } + org.locationtech.jts.geom.Coordinate[] jtsCoordArray = + new org.locationtech.jts.geom.Coordinate[jtsCoordList.size()]; + rings.add(geomFactory.createLinearRing( + jtsCoordList.toArray(jtsCoordArray))); + } + org.locationtech.jts.geom.LinearRing shell = rings.get(0); + if (rings.size() == 1) { + return geomFactory.createPolygon(shell); + } else { + rings.remove(0); + org.locationtech.jts.geom.LinearRing[] holesArrary = + new org.locationtech.jts.geom.LinearRing[rings.size() - 1]; + return geomFactory.createPolygon(shell, rings.toArray(holesArrary)); + } + } + default: + throw new RuntimeException("Unknown geography: " + + geog.getFieldValue().getClass()); + } + } } diff --git a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java index 9f6940134..89fc2e591 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProvider.java @@ -22,6 +22,8 @@ public interface Field { public int offset(); public int nullFlagPos(); + + public int geoShape(); } public long getVersion(); diff --git a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java index 6aebb6298..114b868f5 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java @@ -26,6 +26,7 @@ static class SchemaField implements Field { private final int size; private final int offset; private final int nullFlagPos; + private final int geoShape; public SchemaField(String name, int type, @@ -34,7 +35,8 @@ public SchemaField(String name, byte[] defaultValue, int size, int offset, - int nullFlagPos) { + int nullFlagPos, + int geoShape) { this.name = name; this.type = type; this.nullable = nullable; @@ -43,6 +45,7 @@ public SchemaField(String name, this.size = size; this.offset = offset; this.nullFlagPos = nullFlagPos; + this.geoShape = geoShape; } @Override @@ -84,6 +87,11 @@ public int offset() { public int nullFlagPos() { return nullFlagPos; } + + @Override + public int geoShape() { + return geoShape; + } } public SchemaProviderImpl(long ver) { @@ -169,7 +177,8 @@ public void addField(String name, int type, int fixedStrLen, boolean nullable, - byte[] defaultValue) { + byte[] defaultValue, + int geoShape) { int size = fieldSize(type, fixedStrLen); int offset = 0; @@ -190,7 +199,8 @@ public void addField(String name, defaultValue, size, offset, - nullFlagPos)); + nullFlagPos, + geoShape)); fieldNameIndex.put(name, fields.size() - 1); } @@ -241,6 +251,8 @@ public int fieldSize(int type, int fixedStrLimit) { + Byte.BYTES // minute + Byte.BYTES // sec + Integer.BYTES; // microsec + case GEOGRAPHY: + return 8; // wkb offset + wkb length default: throw new RuntimeException("Incorrect field type " + type); } diff --git a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java index 483c73560..aec661f4f 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java @@ -11,6 +11,7 @@ import com.vesoft.nebula.meta.ColumnDef; import com.vesoft.nebula.meta.ColumnTypeDef; import com.vesoft.nebula.meta.EdgeItem; +import com.vesoft.nebula.meta.GeoShape; import com.vesoft.nebula.meta.PropertyType; import com.vesoft.nebula.meta.Schema; import com.vesoft.nebula.meta.SpaceDesc; @@ -82,6 +83,19 @@ private Schema genNoDefaultVal() { new ColumnTypeDef(PropertyType.INT32)); columnDef.setNullable(true); columns.add(columnDef); + columnDef = new ColumnDef(("Col16").getBytes(), + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.POINT)); + columns.add(columnDef); + columnDef = new ColumnDef(("Col17").getBytes(), + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.LINESTRING)); + columns.add(columnDef); + columnDef = new ColumnDef(("Col18").getBytes(), + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.POLYGON)); + columns.add(columnDef); + columnDef = new ColumnDef(("Col19").getBytes(), + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.ANY)); + columnDef.setNullable(true); + columns.add(columnDef); return new Schema(columns, null); } diff --git a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java index 31ed6fb08..0ed452b78 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java @@ -5,10 +5,15 @@ package test.java.com.vesoft.nebula.encoder; +import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Geography; import com.vesoft.nebula.HostAddr; +import com.vesoft.nebula.LineString; import com.vesoft.nebula.NullType; +import com.vesoft.nebula.Point; +import com.vesoft.nebula.Polygon; import com.vesoft.nebula.Time; import com.vesoft.nebula.Value; import com.vesoft.nebula.encoder.MetaCacheImplTest; @@ -31,14 +36,23 @@ public class TestEncoder { private final MetaCacheImplTest cacheImplTest = new MetaCacheImplTest(); private final NebulaCodecImpl codec = new NebulaCodecImpl(); - final String allTypeValueExpectResult = "090cc001081000200000004000000000000000db0f494069" - + "57148b0abf05405d0000000c0000004e6562756c61204772617068bb334e5e000000" - + "00e40702140a1e2d00000000e40702140a1e2d00000000000000000000000000000000" - + "48656c6c6f20776f726c6421"; + final String allTypeValueExpectResult = "090ce001081000200000004000000000000000" + + "db0f49406957148b0abf05407d0000000c0000004e6562756c61204772617068bb334e5e" + + "00000000e40702140a1e2d00000000e40702140a1e2d0000000000000000000000000000" + + "000089000000150000009e00000039000000d70000009100000000000000000000004865" + + "6c6c6f20776f726c6421010100000000000000006066409a999999997956400102000000" + + "030000000000000000000000000000000000f03f000000000000f03f0000000000000040" + + "00000000000008400000000000001c4001030000000200000004000000cdcccccccc2c5b" + + "c0000000000080414000000000000059c00000000000404740cdccccccccac56c0333333" + + "3333734140cdcccccccc2c5bc000000000008041400400000066666666660659c0333333" + + "3333b344409a99999999b959c0cdcccccccccc424033333333333358c00000000000c042" + + "4066666666660659c03333333333b34440"; private List getCols() { return Arrays.asList("Col01","Col02", "Col03", "Col04", "Col05", "Col06", - "Col07","Col08", "Col09", "Col10", "Col11", "Col12", "Col13", "Col14"); + "Col07","Col08", "Col09", "Col10", "Col11", "Col12", "Col13", "Col14", + // Purposely skip the col15 + "Col16", "Col17", "Col18", "Col19"); } private List getValues() { @@ -61,8 +75,39 @@ private List getValues() { dateValue.setDVal(new Date((short)2020, (byte)2, (byte)20)); final Value nullVal = new Value(); nullVal.setNVal(NullType.__NULL__); + // geograph point + // POINT(179.0 89.9) + final Value geogPointVal = new Value(); + geogPointVal.setGgVal(Geography.ptVal(new Point(new Coordinate(179.0, 89.9)))); + // geography linestring + // LINESTRING(0 1, 1 2, 3 7) + final Value geogLineStringVal = new Value(); + List line = new ArrayList<>(); + line.add(new Coordinate(0, 1)); + line.add(new Coordinate(1, 2)); + line.add(new Coordinate(3, 7)); + geogLineStringVal.setGgVal(Geography.lsVal(new LineString(line))); + // geography polygon + // POLYGON((-108.7 35.0, -100.0 46.5, -90.7 34.9, -108.7 35.0), + // (-100.1 41.4, -102.9 37.6, -96.8 37.5, -100.1 41.4)) + final Value geogPolygonVal = new Value(); + List shell = new ArrayList<>(); + shell.add(new Coordinate(-108.7, 35.0)); + shell.add(new Coordinate(-100.0, 46.5)); + shell.add(new Coordinate(-90.7, 34.9)); + shell.add(new Coordinate(-108.7, 35.0)); + List hole = new ArrayList<>(); + hole.add(new Coordinate(-100.1, 41.4)); + hole.add(new Coordinate(-102.9, 37.6)); + hole.add(new Coordinate(-96.8, 37.5)); + hole.add(new Coordinate(-100.1, 41.4)); + List> rings = new ArrayList>(); + rings.add(shell); + rings.add(hole); + geogPolygonVal.setGgVal(Geography.pgVal(new Polygon(rings))); return Arrays.asList(true, 8, 16, 32, intVal, pi, e, strVal, fixVal, - timestampVal, dateValue, timeVal, datetimeValue, nullVal); + timestampVal, dateValue, timeVal, datetimeValue, nullVal, + geogPointVal, geogLineStringVal, geogPolygonVal, nullVal); } public int getSpaceVidLen(String spaceName) throws RuntimeException { diff --git a/pom.xml b/pom.xml index 5bccb3416..5076510d8 100644 --- a/pom.xml +++ b/pom.xml @@ -9,6 +9,7 @@ UTF-8 + 1.16.1 @@ -157,4 +158,13 @@ + + + + org.locationtech.jts + jts-core + 1.16.1 + + + From 84ddbed8788fc2c3a39e116920426ccdbc2440d3 Mon Sep 17 00:00:00 2001 From: Anqi Date: Fri, 26 Nov 2021 10:26:18 +0800 Subject: [PATCH 12/25] update thrift & modify the scan interface (#386) * update thrift * update storage scan implementation according to lastest server --- .../nebula/{meta => }/PropertyType.java | 2 +- .../com/vesoft/nebula/meta/ColumnTypeDef.java | 24 +- .../com/vesoft/nebula/meta/SpaceDesc.java | 2 +- .../com/vesoft/nebula/storage/AddPartReq.java | 22 +- .../nebula/storage/ChainAddEdgesRequest.java | 66 ++-- .../storage/ChainUpdateEdgeRequest.java | 20 +- .../vesoft/nebula/storage/CheckPeersReq.java | 22 +- .../vesoft/nebula/storage/CreateCPResp.java | 22 +- .../nebula/storage/GeneralStorageService.java | 24 +- .../nebula/storage/GetLeaderPartsResp.java | 44 +-- .../nebula/storage/GraphStorageService.java | 128 +++--- .../nebula/storage/IndexColumnHint.java | 161 +++++++- .../storage/InternalStorageService.java | 16 +- .../nebula/storage/InternalTxnRequest.java | 70 ++-- .../vesoft/nebula/storage/KVGetRequest.java | 44 +-- .../vesoft/nebula/storage/KVGetResponse.java | 26 +- .../vesoft/nebula/storage/KVPutRequest.java | 46 +-- .../nebula/storage/KVRemoveRequest.java | 44 +-- .../nebula/storage/RebuildIndexRequest.java | 20 +- .../com/vesoft/nebula/storage/ScanCursor.java | 369 ++++++++++++++++++ .../nebula/storage/ScanEdgeRequest.java | 258 +++++------- .../nebula/storage/ScanEdgeResponse.java | 211 ++++------ .../nebula/storage/ScanVertexRequest.java | 303 ++++++-------- .../nebula/storage/ScanVertexResponse.java | 211 ++++------ .../nebula/storage/StorageAdminService.java | 128 +++--- .../com/vesoft/nebula/storage/TaskPara.java | 40 +- .../nebula/client/storage/StorageClient.java | 4 +- .../client/storage/scan/PartScanInfo.java | 9 +- .../storage/scan/ScanEdgeResultIterator.java | 14 +- .../scan/ScanVertexResultIterator.java | 14 +- .../vesoft/nebula/encoder/RowWriterImpl.java | 2 +- .../nebula/encoder/SchemaProviderImpl.java | 2 +- .../client/storage/StorageClientTest.java | 63 ++- .../storage/scan/PartScanQueueTest.java | 5 +- .../nebula/encoder/MetaCacheImplTest.java | 3 +- .../vesoft/nebula/encoder/TestEncoder.java | 4 +- 36 files changed, 1346 insertions(+), 1097 deletions(-) rename client/src/main/generated/com/vesoft/nebula/{meta => }/PropertyType.java (98%) create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java b/client/src/main/generated/com/vesoft/nebula/PropertyType.java similarity index 98% rename from client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java rename to client/src/main/generated/com/vesoft/nebula/PropertyType.java index fc77cc24b..9d9671e8d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java +++ b/client/src/main/generated/com/vesoft/nebula/PropertyType.java @@ -4,7 +4,7 @@ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ -package com.vesoft.nebula.meta; +package com.vesoft.nebula; import com.facebook.thrift.IntRangeSet; diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java b/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java index 48b144908..d017d7241 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ColumnTypeDef.java @@ -32,9 +32,9 @@ public class ColumnTypeDef implements TBase, java.io.Serializable, Cloneable, Co /** * - * @see PropertyType + * @see com.vesoft.nebula.PropertyType */ - public PropertyType type; + public com.vesoft.nebula.PropertyType type; public short type_length; /** * @@ -72,13 +72,13 @@ public ColumnTypeDef() { } public ColumnTypeDef( - PropertyType type) { + com.vesoft.nebula.PropertyType type) { this(); this.type = type; } public ColumnTypeDef( - PropertyType type, + com.vesoft.nebula.PropertyType type, short type_length, GeoShape geo_shape) { this(); @@ -89,7 +89,7 @@ public ColumnTypeDef( } public static class Builder { - private PropertyType type; + private com.vesoft.nebula.PropertyType type; private short type_length; private GeoShape geo_shape; @@ -98,7 +98,7 @@ public static class Builder { public Builder() { } - public Builder setType(final PropertyType type) { + public Builder setType(final com.vesoft.nebula.PropertyType type) { this.type = type; return this; } @@ -150,17 +150,17 @@ public ColumnTypeDef deepCopy() { /** * - * @see PropertyType + * @see com.vesoft.nebula.PropertyType */ - public PropertyType getType() { + public com.vesoft.nebula.PropertyType getType() { return this.type; } /** * - * @see PropertyType + * @see com.vesoft.nebula.PropertyType */ - public ColumnTypeDef setType(PropertyType type) { + public ColumnTypeDef setType(com.vesoft.nebula.PropertyType type) { this.type = type; return this; } @@ -241,7 +241,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetType(); } else { - setType((PropertyType)__value); + setType((com.vesoft.nebula.PropertyType)__value); } break; @@ -358,7 +358,7 @@ public void read(TProtocol iprot) throws TException { { case TYPE: if (__field.type == TType.I32) { - this.type = PropertyType.findByValue(iprot.readI32()); + this.type = com.vesoft.nebula.PropertyType.findByValue(iprot.readI32()); } else { TProtocolUtil.skip(iprot, __field.type); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java b/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java index 5ee972c57..3f786dacb 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java @@ -99,7 +99,7 @@ public SpaceDesc() { this.replica_factor = 0; this.vid_type = new ColumnTypeDef(); - this.vid_type.setType(com.vesoft.nebula.meta.PropertyType.FIXED_STRING); + this.vid_type.setType(com.vesoft.nebula.PropertyType.FIXED_STRING); this.vid_type.setType_length((short)8); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java b/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java index fffba1d5a..55a0410fe 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java @@ -419,16 +419,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list197 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list197.size)); - for (int _i198 = 0; - (_list197.size < 0) ? iprot.peekList() : (_i198 < _list197.size); - ++_i198) + TList _list221 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list221.size)); + for (int _i222 = 0; + (_list221.size < 0) ? iprot.peekList() : (_i222 < _list221.size); + ++_i222) { - com.vesoft.nebula.HostAddr _elem199; - _elem199 = new com.vesoft.nebula.HostAddr(); - _elem199.read(iprot); - this.peers.add(_elem199); + com.vesoft.nebula.HostAddr _elem223; + _elem223 = new com.vesoft.nebula.HostAddr(); + _elem223.read(iprot); + this.peers.add(_elem223); } iprot.readListEnd(); } @@ -466,8 +466,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter200 : this.peers) { - _iter200.write(oprot); + for (com.vesoft.nebula.HostAddr _iter224 : this.peers) { + _iter224.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java index 60e78656c..24ef64348 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java @@ -486,30 +486,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map268 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map268.size)); - for (int _i269 = 0; - (_map268.size < 0) ? iprot.peekMap() : (_i269 < _map268.size); - ++_i269) + TMap _map292 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map292.size)); + for (int _i293 = 0; + (_map292.size < 0) ? iprot.peekMap() : (_i293 < _map292.size); + ++_i293) { - int _key270; - List _val271; - _key270 = iprot.readI32(); + int _key294; + List _val295; + _key294 = iprot.readI32(); { - TList _list272 = iprot.readListBegin(); - _val271 = new ArrayList(Math.max(0, _list272.size)); - for (int _i273 = 0; - (_list272.size < 0) ? iprot.peekList() : (_i273 < _list272.size); - ++_i273) + TList _list296 = iprot.readListBegin(); + _val295 = new ArrayList(Math.max(0, _list296.size)); + for (int _i297 = 0; + (_list296.size < 0) ? iprot.peekList() : (_i297 < _list296.size); + ++_i297) { - NewEdge _elem274; - _elem274 = new NewEdge(); - _elem274.read(iprot); - _val271.add(_elem274); + NewEdge _elem298; + _elem298 = new NewEdge(); + _elem298.read(iprot); + _val295.add(_elem298); } iprot.readListEnd(); } - this.parts.put(_key270, _val271); + this.parts.put(_key294, _val295); } iprot.readMapEnd(); } @@ -520,15 +520,15 @@ public void read(TProtocol iprot) throws TException { case PROP_NAMES: if (__field.type == TType.LIST) { { - TList _list275 = iprot.readListBegin(); - this.prop_names = new ArrayList(Math.max(0, _list275.size)); - for (int _i276 = 0; - (_list275.size < 0) ? iprot.peekList() : (_i276 < _list275.size); - ++_i276) + TList _list299 = iprot.readListBegin(); + this.prop_names = new ArrayList(Math.max(0, _list299.size)); + for (int _i300 = 0; + (_list299.size < 0) ? iprot.peekList() : (_i300 < _list299.size); + ++_i300) { - byte[] _elem277; - _elem277 = iprot.readBinary(); - this.prop_names.add(_elem277); + byte[] _elem301; + _elem301 = iprot.readBinary(); + this.prop_names.add(_elem301); } iprot.readListEnd(); } @@ -584,12 +584,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter278 : this.parts.entrySet()) { - oprot.writeI32(_iter278.getKey()); + for (Map.Entry> _iter302 : this.parts.entrySet()) { + oprot.writeI32(_iter302.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter278.getValue().size())); - for (NewEdge _iter279 : _iter278.getValue()) { - _iter279.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter302.getValue().size())); + for (NewEdge _iter303 : _iter302.getValue()) { + _iter303.write(oprot); } oprot.writeListEnd(); } @@ -602,8 +602,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROP_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.prop_names.size())); - for (byte[] _iter280 : this.prop_names) { - oprot.writeBinary(_iter280); + for (byte[] _iter304 : this.prop_names) { + oprot.writeBinary(_iter304); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java index ef8fad589..a59c6066e 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java @@ -454,15 +454,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list281 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list281.size)); - for (int _i282 = 0; - (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); - ++_i282) + TList _list305 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list305.size)); + for (int _i306 = 0; + (_list305.size < 0) ? iprot.peekList() : (_i306 < _list305.size); + ++_i306) { - int _elem283; - _elem283 = iprot.readI32(); - this.parts.add(_elem283); + int _elem307; + _elem307 = iprot.readI32(); + this.parts.add(_elem307); } iprot.readListEnd(); } @@ -507,8 +507,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter284 : this.parts) { - oprot.writeI32(_iter284); + for (int _iter308 : this.parts) { + oprot.writeI32(_iter308); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java index d49344245..6f79c0c30 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java @@ -347,16 +347,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list210 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list210.size)); - for (int _i211 = 0; - (_list210.size < 0) ? iprot.peekList() : (_i211 < _list210.size); - ++_i211) + TList _list234 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list234.size)); + for (int _i235 = 0; + (_list234.size < 0) ? iprot.peekList() : (_i235 < _list234.size); + ++_i235) { - com.vesoft.nebula.HostAddr _elem212; - _elem212 = new com.vesoft.nebula.HostAddr(); - _elem212.read(iprot); - this.peers.add(_elem212); + com.vesoft.nebula.HostAddr _elem236; + _elem236 = new com.vesoft.nebula.HostAddr(); + _elem236.read(iprot); + this.peers.add(_elem236); } iprot.readListEnd(); } @@ -391,8 +391,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter213 : this.peers) { - _iter213.write(oprot); + for (com.vesoft.nebula.HostAddr _iter237 : this.peers) { + _iter237.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java index d0915204b..0a945b9b1 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java @@ -274,16 +274,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list218 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list218.size)); - for (int _i219 = 0; - (_list218.size < 0) ? iprot.peekList() : (_i219 < _list218.size); - ++_i219) + TList _list242 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list242.size)); + for (int _i243 = 0; + (_list242.size < 0) ? iprot.peekList() : (_i243 < _list242.size); + ++_i243) { - com.vesoft.nebula.CheckpointInfo _elem220; - _elem220 = new com.vesoft.nebula.CheckpointInfo(); - _elem220.read(iprot); - this.info.add(_elem220); + com.vesoft.nebula.CheckpointInfo _elem244; + _elem244 = new com.vesoft.nebula.CheckpointInfo(); + _elem244.read(iprot); + this.info.add(_elem244); } iprot.readListEnd(); } @@ -317,8 +317,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter221 : this.info) { - _iter221.write(oprot); + for (com.vesoft.nebula.CheckpointInfo _iter245 : this.info) { + _iter245.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java index 351d4458e..752c8b08e 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java @@ -231,17 +231,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void get(KVGetRequest req, AsyncMethodCallback resultHandler483) throws TException { + public void get(KVGetRequest req, AsyncMethodCallback resultHandler507) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler483, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler507, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private KVGetRequest req; - public get_call(KVGetRequest req, AsyncMethodCallback resultHandler484, TAsyncClient client480, TProtocolFactory protocolFactory481, TNonblockingTransport transport482) throws TException { - super(client480, protocolFactory481, transport482, resultHandler484, false); + public get_call(KVGetRequest req, AsyncMethodCallback resultHandler508, TAsyncClient client504, TProtocolFactory protocolFactory505, TNonblockingTransport transport506) throws TException { + super(client504, protocolFactory505, transport506, resultHandler508, false); this.req = req; } @@ -263,17 +263,17 @@ public KVGetResponse getResult() throws TException { } } - public void put(KVPutRequest req, AsyncMethodCallback resultHandler488) throws TException { + public void put(KVPutRequest req, AsyncMethodCallback resultHandler512) throws TException { checkReady(); - put_call method_call = new put_call(req, resultHandler488, this, ___protocolFactory, ___transport); + put_call method_call = new put_call(req, resultHandler512, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class put_call extends TAsyncMethodCall { private KVPutRequest req; - public put_call(KVPutRequest req, AsyncMethodCallback resultHandler489, TAsyncClient client485, TProtocolFactory protocolFactory486, TNonblockingTransport transport487) throws TException { - super(client485, protocolFactory486, transport487, resultHandler489, false); + public put_call(KVPutRequest req, AsyncMethodCallback resultHandler513, TAsyncClient client509, TProtocolFactory protocolFactory510, TNonblockingTransport transport511) throws TException { + super(client509, protocolFactory510, transport511, resultHandler513, false); this.req = req; } @@ -295,17 +295,17 @@ public ExecResponse getResult() throws TException { } } - public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler493) throws TException { + public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler517) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler493, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler517, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private KVRemoveRequest req; - public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler494, TAsyncClient client490, TProtocolFactory protocolFactory491, TNonblockingTransport transport492) throws TException { - super(client490, protocolFactory491, transport492, resultHandler494, false); + public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler518, TAsyncClient client514, TProtocolFactory protocolFactory515, TNonblockingTransport transport516) throws TException { + super(client514, protocolFactory515, transport516, resultHandler518, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java index 831072bd8..6b4bfaecd 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java @@ -276,29 +276,29 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTS: if (__field.type == TType.MAP) { { - TMap _map201 = iprot.readMapBegin(); - this.leader_parts = new HashMap>(Math.max(0, 2*_map201.size)); - for (int _i202 = 0; - (_map201.size < 0) ? iprot.peekMap() : (_i202 < _map201.size); - ++_i202) + TMap _map225 = iprot.readMapBegin(); + this.leader_parts = new HashMap>(Math.max(0, 2*_map225.size)); + for (int _i226 = 0; + (_map225.size < 0) ? iprot.peekMap() : (_i226 < _map225.size); + ++_i226) { - int _key203; - List _val204; - _key203 = iprot.readI32(); + int _key227; + List _val228; + _key227 = iprot.readI32(); { - TList _list205 = iprot.readListBegin(); - _val204 = new ArrayList(Math.max(0, _list205.size)); - for (int _i206 = 0; - (_list205.size < 0) ? iprot.peekList() : (_i206 < _list205.size); - ++_i206) + TList _list229 = iprot.readListBegin(); + _val228 = new ArrayList(Math.max(0, _list229.size)); + for (int _i230 = 0; + (_list229.size < 0) ? iprot.peekList() : (_i230 < _list229.size); + ++_i230) { - int _elem207; - _elem207 = iprot.readI32(); - _val204.add(_elem207); + int _elem231; + _elem231 = iprot.readI32(); + _val228.add(_elem231); } iprot.readListEnd(); } - this.leader_parts.put(_key203, _val204); + this.leader_parts.put(_key227, _val228); } iprot.readMapEnd(); } @@ -332,12 +332,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.leader_parts.size())); - for (Map.Entry> _iter208 : this.leader_parts.entrySet()) { - oprot.writeI32(_iter208.getKey()); + for (Map.Entry> _iter232 : this.leader_parts.entrySet()) { + oprot.writeI32(_iter232.getKey()); { - oprot.writeListBegin(new TList(TType.I32, _iter208.getValue().size())); - for (int _iter209 : _iter208.getValue()) { - oprot.writeI32(_iter209); + oprot.writeListBegin(new TList(TType.I32, _iter232.getValue().size())); + for (int _iter233 : _iter232.getValue()) { + oprot.writeI32(_iter233); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java index 99ea338d6..c5be51355 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java @@ -868,17 +868,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler304) throws TException { + public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler328) throws TException { checkReady(); - getNeighbors_call method_call = new getNeighbors_call(req, resultHandler304, this, ___protocolFactory, ___transport); + getNeighbors_call method_call = new getNeighbors_call(req, resultHandler328, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getNeighbors_call extends TAsyncMethodCall { private GetNeighborsRequest req; - public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler305, TAsyncClient client301, TProtocolFactory protocolFactory302, TNonblockingTransport transport303) throws TException { - super(client301, protocolFactory302, transport303, resultHandler305, false); + public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler329, TAsyncClient client325, TProtocolFactory protocolFactory326, TNonblockingTransport transport327) throws TException { + super(client325, protocolFactory326, transport327, resultHandler329, false); this.req = req; } @@ -900,17 +900,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler309) throws TException { + public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler333) throws TException { checkReady(); - getProps_call method_call = new getProps_call(req, resultHandler309, this, ___protocolFactory, ___transport); + getProps_call method_call = new getProps_call(req, resultHandler333, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getProps_call extends TAsyncMethodCall { private GetPropRequest req; - public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler310, TAsyncClient client306, TProtocolFactory protocolFactory307, TNonblockingTransport transport308) throws TException { - super(client306, protocolFactory307, transport308, resultHandler310, false); + public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler334, TAsyncClient client330, TProtocolFactory protocolFactory331, TNonblockingTransport transport332) throws TException { + super(client330, protocolFactory331, transport332, resultHandler334, false); this.req = req; } @@ -932,17 +932,17 @@ public GetPropResponse getResult() throws TException { } } - public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler314) throws TException { + public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler338) throws TException { checkReady(); - addVertices_call method_call = new addVertices_call(req, resultHandler314, this, ___protocolFactory, ___transport); + addVertices_call method_call = new addVertices_call(req, resultHandler338, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addVertices_call extends TAsyncMethodCall { private AddVerticesRequest req; - public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler315, TAsyncClient client311, TProtocolFactory protocolFactory312, TNonblockingTransport transport313) throws TException { - super(client311, protocolFactory312, transport313, resultHandler315, false); + public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler339, TAsyncClient client335, TProtocolFactory protocolFactory336, TNonblockingTransport transport337) throws TException { + super(client335, protocolFactory336, transport337, resultHandler339, false); this.req = req; } @@ -964,17 +964,17 @@ public ExecResponse getResult() throws TException { } } - public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler319) throws TException { + public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler343) throws TException { checkReady(); - addEdges_call method_call = new addEdges_call(req, resultHandler319, this, ___protocolFactory, ___transport); + addEdges_call method_call = new addEdges_call(req, resultHandler343, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler320, TAsyncClient client316, TProtocolFactory protocolFactory317, TNonblockingTransport transport318) throws TException { - super(client316, protocolFactory317, transport318, resultHandler320, false); + public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler344, TAsyncClient client340, TProtocolFactory protocolFactory341, TNonblockingTransport transport342) throws TException { + super(client340, protocolFactory341, transport342, resultHandler344, false); this.req = req; } @@ -996,17 +996,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler324) throws TException { + public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler348) throws TException { checkReady(); - deleteEdges_call method_call = new deleteEdges_call(req, resultHandler324, this, ___protocolFactory, ___transport); + deleteEdges_call method_call = new deleteEdges_call(req, resultHandler348, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteEdges_call extends TAsyncMethodCall { private DeleteEdgesRequest req; - public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler325, TAsyncClient client321, TProtocolFactory protocolFactory322, TNonblockingTransport transport323) throws TException { - super(client321, protocolFactory322, transport323, resultHandler325, false); + public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler349, TAsyncClient client345, TProtocolFactory protocolFactory346, TNonblockingTransport transport347) throws TException { + super(client345, protocolFactory346, transport347, resultHandler349, false); this.req = req; } @@ -1028,17 +1028,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler329) throws TException { + public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler353) throws TException { checkReady(); - deleteVertices_call method_call = new deleteVertices_call(req, resultHandler329, this, ___protocolFactory, ___transport); + deleteVertices_call method_call = new deleteVertices_call(req, resultHandler353, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteVertices_call extends TAsyncMethodCall { private DeleteVerticesRequest req; - public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler330, TAsyncClient client326, TProtocolFactory protocolFactory327, TNonblockingTransport transport328) throws TException { - super(client326, protocolFactory327, transport328, resultHandler330, false); + public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler354, TAsyncClient client350, TProtocolFactory protocolFactory351, TNonblockingTransport transport352) throws TException { + super(client350, protocolFactory351, transport352, resultHandler354, false); this.req = req; } @@ -1060,17 +1060,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler334) throws TException { + public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler358) throws TException { checkReady(); - deleteTags_call method_call = new deleteTags_call(req, resultHandler334, this, ___protocolFactory, ___transport); + deleteTags_call method_call = new deleteTags_call(req, resultHandler358, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteTags_call extends TAsyncMethodCall { private DeleteTagsRequest req; - public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler335, TAsyncClient client331, TProtocolFactory protocolFactory332, TNonblockingTransport transport333) throws TException { - super(client331, protocolFactory332, transport333, resultHandler335, false); + public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler359, TAsyncClient client355, TProtocolFactory protocolFactory356, TNonblockingTransport transport357) throws TException { + super(client355, protocolFactory356, transport357, resultHandler359, false); this.req = req; } @@ -1092,17 +1092,17 @@ public ExecResponse getResult() throws TException { } } - public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler339) throws TException { + public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler363) throws TException { checkReady(); - updateVertex_call method_call = new updateVertex_call(req, resultHandler339, this, ___protocolFactory, ___transport); + updateVertex_call method_call = new updateVertex_call(req, resultHandler363, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateVertex_call extends TAsyncMethodCall { private UpdateVertexRequest req; - public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler340, TAsyncClient client336, TProtocolFactory protocolFactory337, TNonblockingTransport transport338) throws TException { - super(client336, protocolFactory337, transport338, resultHandler340, false); + public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler364, TAsyncClient client360, TProtocolFactory protocolFactory361, TNonblockingTransport transport362) throws TException { + super(client360, protocolFactory361, transport362, resultHandler364, false); this.req = req; } @@ -1124,17 +1124,17 @@ public UpdateResponse getResult() throws TException { } } - public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler344) throws TException { + public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler368) throws TException { checkReady(); - updateEdge_call method_call = new updateEdge_call(req, resultHandler344, this, ___protocolFactory, ___transport); + updateEdge_call method_call = new updateEdge_call(req, resultHandler368, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler345, TAsyncClient client341, TProtocolFactory protocolFactory342, TNonblockingTransport transport343) throws TException { - super(client341, protocolFactory342, transport343, resultHandler345, false); + public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler369, TAsyncClient client365, TProtocolFactory protocolFactory366, TNonblockingTransport transport367) throws TException { + super(client365, protocolFactory366, transport367, resultHandler369, false); this.req = req; } @@ -1156,17 +1156,17 @@ public UpdateResponse getResult() throws TException { } } - public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler349) throws TException { + public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler373) throws TException { checkReady(); - scanVertex_call method_call = new scanVertex_call(req, resultHandler349, this, ___protocolFactory, ___transport); + scanVertex_call method_call = new scanVertex_call(req, resultHandler373, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanVertex_call extends TAsyncMethodCall { private ScanVertexRequest req; - public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler350, TAsyncClient client346, TProtocolFactory protocolFactory347, TNonblockingTransport transport348) throws TException { - super(client346, protocolFactory347, transport348, resultHandler350, false); + public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler374, TAsyncClient client370, TProtocolFactory protocolFactory371, TNonblockingTransport transport372) throws TException { + super(client370, protocolFactory371, transport372, resultHandler374, false); this.req = req; } @@ -1188,17 +1188,17 @@ public ScanVertexResponse getResult() throws TException { } } - public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler354) throws TException { + public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler378) throws TException { checkReady(); - scanEdge_call method_call = new scanEdge_call(req, resultHandler354, this, ___protocolFactory, ___transport); + scanEdge_call method_call = new scanEdge_call(req, resultHandler378, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanEdge_call extends TAsyncMethodCall { private ScanEdgeRequest req; - public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler355, TAsyncClient client351, TProtocolFactory protocolFactory352, TNonblockingTransport transport353) throws TException { - super(client351, protocolFactory352, transport353, resultHandler355, false); + public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler379, TAsyncClient client375, TProtocolFactory protocolFactory376, TNonblockingTransport transport377) throws TException { + super(client375, protocolFactory376, transport377, resultHandler379, false); this.req = req; } @@ -1220,17 +1220,17 @@ public ScanEdgeResponse getResult() throws TException { } } - public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler359) throws TException { + public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler383) throws TException { checkReady(); - getUUID_call method_call = new getUUID_call(req, resultHandler359, this, ___protocolFactory, ___transport); + getUUID_call method_call = new getUUID_call(req, resultHandler383, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUUID_call extends TAsyncMethodCall { private GetUUIDReq req; - public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler360, TAsyncClient client356, TProtocolFactory protocolFactory357, TNonblockingTransport transport358) throws TException { - super(client356, protocolFactory357, transport358, resultHandler360, false); + public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler384, TAsyncClient client380, TProtocolFactory protocolFactory381, TNonblockingTransport transport382) throws TException { + super(client380, protocolFactory381, transport382, resultHandler384, false); this.req = req; } @@ -1252,17 +1252,17 @@ public GetUUIDResp getResult() throws TException { } } - public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler364) throws TException { + public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler388) throws TException { checkReady(); - lookupIndex_call method_call = new lookupIndex_call(req, resultHandler364, this, ___protocolFactory, ___transport); + lookupIndex_call method_call = new lookupIndex_call(req, resultHandler388, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupIndex_call extends TAsyncMethodCall { private LookupIndexRequest req; - public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler365, TAsyncClient client361, TProtocolFactory protocolFactory362, TNonblockingTransport transport363) throws TException { - super(client361, protocolFactory362, transport363, resultHandler365, false); + public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler389, TAsyncClient client385, TProtocolFactory protocolFactory386, TNonblockingTransport transport387) throws TException { + super(client385, protocolFactory386, transport387, resultHandler389, false); this.req = req; } @@ -1284,17 +1284,17 @@ public LookupIndexResp getResult() throws TException { } } - public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler369) throws TException { + public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler393) throws TException { checkReady(); - lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler369, this, ___protocolFactory, ___transport); + lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler393, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupAndTraverse_call extends TAsyncMethodCall { private LookupAndTraverseRequest req; - public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler370, TAsyncClient client366, TProtocolFactory protocolFactory367, TNonblockingTransport transport368) throws TException { - super(client366, protocolFactory367, transport368, resultHandler370, false); + public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler394, TAsyncClient client390, TProtocolFactory protocolFactory391, TNonblockingTransport transport392) throws TException { + super(client390, protocolFactory391, transport392, resultHandler394, false); this.req = req; } @@ -1316,17 +1316,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler374) throws TException { + public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler398) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler374, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler398, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler375, TAsyncClient client371, TProtocolFactory protocolFactory372, TNonblockingTransport transport373) throws TException { - super(client371, protocolFactory372, transport373, resultHandler375, false); + public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler399, TAsyncClient client395, TProtocolFactory protocolFactory396, TNonblockingTransport transport397) throws TException { + super(client395, protocolFactory396, transport397, resultHandler399, false); this.req = req; } @@ -1348,17 +1348,17 @@ public UpdateResponse getResult() throws TException { } } - public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler379) throws TException { + public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler403) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler379, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler403, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler380, TAsyncClient client376, TProtocolFactory protocolFactory377, TNonblockingTransport transport378) throws TException { - super(client376, protocolFactory377, transport378, resultHandler380, false); + public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler404, TAsyncClient client400, TProtocolFactory protocolFactory401, TNonblockingTransport transport402) throws TException { + super(client400, protocolFactory401, transport402, resultHandler404, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/IndexColumnHint.java b/client/src/main/generated/com/vesoft/nebula/storage/IndexColumnHint.java index 1651adcb4..44b163ddf 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/IndexColumnHint.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/IndexColumnHint.java @@ -30,6 +30,8 @@ public class IndexColumnHint implements TBase, java.io.Serializable, Cloneable { private static final TField SCAN_TYPE_FIELD_DESC = new TField("scan_type", TType.I32, (short)2); private static final TField BEGIN_VALUE_FIELD_DESC = new TField("begin_value", TType.STRUCT, (short)3); private static final TField END_VALUE_FIELD_DESC = new TField("end_value", TType.STRUCT, (short)4); + private static final TField INCLUDE_BEGIN_FIELD_DESC = new TField("include_begin", TType.BOOL, (short)5); + private static final TField INCLUDE_END_FIELD_DESC = new TField("include_end", TType.BOOL, (short)6); public byte[] column_name; /** @@ -39,12 +41,19 @@ public class IndexColumnHint implements TBase, java.io.Serializable, Cloneable { public ScanType scan_type; public com.vesoft.nebula.Value begin_value; public com.vesoft.nebula.Value end_value; + public boolean include_begin; + public boolean include_end; public static final int COLUMN_NAME = 1; public static final int SCAN_TYPE = 2; public static final int BEGIN_VALUE = 3; public static final int END_VALUE = 4; + public static final int INCLUDE_BEGIN = 5; + public static final int INCLUDE_END = 6; // isset id assignments + private static final int __INCLUDE_BEGIN_ISSET_ID = 0; + private static final int __INCLUDE_END_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); public static final Map metaDataMap; @@ -58,6 +67,10 @@ public class IndexColumnHint implements TBase, java.io.Serializable, Cloneable { new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class))); tmpMetaDataMap.put(END_VALUE, new FieldMetaData("end_value", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class))); + tmpMetaDataMap.put(INCLUDE_BEGIN, new FieldMetaData("include_begin", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(INCLUDE_END, new FieldMetaData("include_end", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -66,18 +79,28 @@ public class IndexColumnHint implements TBase, java.io.Serializable, Cloneable { } public IndexColumnHint() { + this.include_begin = true; + + this.include_end = false; + } public IndexColumnHint( byte[] column_name, ScanType scan_type, com.vesoft.nebula.Value begin_value, - com.vesoft.nebula.Value end_value) { + com.vesoft.nebula.Value end_value, + boolean include_begin, + boolean include_end) { this(); this.column_name = column_name; this.scan_type = scan_type; this.begin_value = begin_value; this.end_value = end_value; + this.include_begin = include_begin; + setInclude_beginIsSet(true); + this.include_end = include_end; + setInclude_endIsSet(true); } public static class Builder { @@ -85,6 +108,10 @@ public static class Builder { private ScanType scan_type; private com.vesoft.nebula.Value begin_value; private com.vesoft.nebula.Value end_value; + private boolean include_begin; + private boolean include_end; + + BitSet __optional_isset = new BitSet(2); public Builder() { } @@ -109,12 +136,30 @@ public Builder setEnd_value(final com.vesoft.nebula.Value end_value) { return this; } + public Builder setInclude_begin(final boolean include_begin) { + this.include_begin = include_begin; + __optional_isset.set(__INCLUDE_BEGIN_ISSET_ID, true); + return this; + } + + public Builder setInclude_end(final boolean include_end) { + this.include_end = include_end; + __optional_isset.set(__INCLUDE_END_ISSET_ID, true); + return this; + } + public IndexColumnHint build() { IndexColumnHint result = new IndexColumnHint(); result.setColumn_name(this.column_name); result.setScan_type(this.scan_type); result.setBegin_value(this.begin_value); result.setEnd_value(this.end_value); + if (__optional_isset.get(__INCLUDE_BEGIN_ISSET_ID)) { + result.setInclude_begin(this.include_begin); + } + if (__optional_isset.get(__INCLUDE_END_ISSET_ID)) { + result.setInclude_end(this.include_end); + } return result; } } @@ -127,6 +172,8 @@ public static Builder builder() { * Performs a deep copy on other. */ public IndexColumnHint(IndexColumnHint other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); if (other.isSetColumn_name()) { this.column_name = TBaseHelper.deepCopy(other.column_name); } @@ -139,6 +186,8 @@ public IndexColumnHint(IndexColumnHint other) { if (other.isSetEnd_value()) { this.end_value = TBaseHelper.deepCopy(other.end_value); } + this.include_begin = TBaseHelper.deepCopy(other.include_begin); + this.include_end = TBaseHelper.deepCopy(other.include_end); } public IndexColumnHint deepCopy() { @@ -249,6 +298,52 @@ public void setEnd_valueIsSet(boolean __value) { } } + public boolean isInclude_begin() { + return this.include_begin; + } + + public IndexColumnHint setInclude_begin(boolean include_begin) { + this.include_begin = include_begin; + setInclude_beginIsSet(true); + return this; + } + + public void unsetInclude_begin() { + __isset_bit_vector.clear(__INCLUDE_BEGIN_ISSET_ID); + } + + // Returns true if field include_begin is set (has been assigned a value) and false otherwise + public boolean isSetInclude_begin() { + return __isset_bit_vector.get(__INCLUDE_BEGIN_ISSET_ID); + } + + public void setInclude_beginIsSet(boolean __value) { + __isset_bit_vector.set(__INCLUDE_BEGIN_ISSET_ID, __value); + } + + public boolean isInclude_end() { + return this.include_end; + } + + public IndexColumnHint setInclude_end(boolean include_end) { + this.include_end = include_end; + setInclude_endIsSet(true); + return this; + } + + public void unsetInclude_end() { + __isset_bit_vector.clear(__INCLUDE_END_ISSET_ID); + } + + // Returns true if field include_end is set (has been assigned a value) and false otherwise + public boolean isSetInclude_end() { + return __isset_bit_vector.get(__INCLUDE_END_ISSET_ID); + } + + public void setInclude_endIsSet(boolean __value) { + __isset_bit_vector.set(__INCLUDE_END_ISSET_ID, __value); + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case COLUMN_NAME: @@ -283,6 +378,22 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case INCLUDE_BEGIN: + if (__value == null) { + unsetInclude_begin(); + } else { + setInclude_begin((Boolean)__value); + } + break; + + case INCLUDE_END: + if (__value == null) { + unsetInclude_end(); + } else { + setInclude_end((Boolean)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -302,6 +413,12 @@ public Object getFieldValue(int fieldID) { case END_VALUE: return getEnd_value(); + case INCLUDE_BEGIN: + return new Boolean(isInclude_begin()); + + case INCLUDE_END: + return new Boolean(isInclude_end()); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -325,12 +442,16 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetEnd_value(), that.isSetEnd_value(), this.end_value, that.end_value)) { return false; } + if (!TBaseHelper.equalsNobinary(this.include_begin, that.include_begin)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.include_end, that.include_end)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {column_name, scan_type, begin_value, end_value}); + return Arrays.deepHashCode(new Object[] {column_name, scan_type, begin_value, end_value, include_begin, include_end}); } public void read(TProtocol iprot) throws TException { @@ -374,6 +495,22 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case INCLUDE_BEGIN: + if (__field.type == TType.BOOL) { + this.include_begin = iprot.readBool(); + setInclude_beginIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case INCLUDE_END: + if (__field.type == TType.BOOL) { + this.include_end = iprot.readBool(); + setInclude_endIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -411,6 +548,12 @@ public void write(TProtocol oprot) throws TException { this.end_value.write(oprot); oprot.writeFieldEnd(); } + oprot.writeFieldBegin(INCLUDE_BEGIN_FIELD_DESC); + oprot.writeBool(this.include_begin); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(INCLUDE_END_FIELD_DESC); + oprot.writeBool(this.include_end); + oprot.writeFieldEnd(); oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -487,6 +630,20 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getEnd_value(), indent + 1, prettyPrint)); } first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("include_begin"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isInclude_begin(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("include_end"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isInclude_end(), indent + 1, prettyPrint)); + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java index dc8f229b4..ae3ee00b2 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java @@ -182,17 +182,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler500) throws TException { + public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler524) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler500, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler524, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private ChainAddEdgesRequest req; - public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler501, TAsyncClient client497, TProtocolFactory protocolFactory498, TNonblockingTransport transport499) throws TException { - super(client497, protocolFactory498, transport499, resultHandler501, false); + public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler525, TAsyncClient client521, TProtocolFactory protocolFactory522, TNonblockingTransport transport523) throws TException { + super(client521, protocolFactory522, transport523, resultHandler525, false); this.req = req; } @@ -214,17 +214,17 @@ public ExecResponse getResult() throws TException { } } - public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler505) throws TException { + public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler529) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler505, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler529, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private ChainUpdateEdgeRequest req; - public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler506, TAsyncClient client502, TProtocolFactory protocolFactory503, TNonblockingTransport transport504) throws TException { - super(client502, protocolFactory503, transport504, resultHandler506, false); + public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler530, TAsyncClient client526, TProtocolFactory protocolFactory527, TNonblockingTransport transport528) throws TException { + super(client526, protocolFactory527, transport528, resultHandler530, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java index 1fc752175..357a6fe2b 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java @@ -419,17 +419,17 @@ public void read(TProtocol iprot) throws TException { case TERM_OF_PARTS: if (__field.type == TType.MAP) { { - TMap _map254 = iprot.readMapBegin(); - this.term_of_parts = new HashMap(Math.max(0, 2*_map254.size)); - for (int _i255 = 0; - (_map254.size < 0) ? iprot.peekMap() : (_i255 < _map254.size); - ++_i255) + TMap _map278 = iprot.readMapBegin(); + this.term_of_parts = new HashMap(Math.max(0, 2*_map278.size)); + for (int _i279 = 0; + (_map278.size < 0) ? iprot.peekMap() : (_i279 < _map278.size); + ++_i279) { - int _key256; - long _val257; - _key256 = iprot.readI32(); - _val257 = iprot.readI64(); - this.term_of_parts.put(_key256, _val257); + int _key280; + long _val281; + _key280 = iprot.readI32(); + _val281 = iprot.readI64(); + this.term_of_parts.put(_key280, _val281); } iprot.readMapEnd(); } @@ -456,29 +456,29 @@ public void read(TProtocol iprot) throws TException { case EDGE_VER: if (__field.type == TType.MAP) { { - TMap _map258 = iprot.readMapBegin(); - this.edge_ver = new HashMap>(Math.max(0, 2*_map258.size)); - for (int _i259 = 0; - (_map258.size < 0) ? iprot.peekMap() : (_i259 < _map258.size); - ++_i259) + TMap _map282 = iprot.readMapBegin(); + this.edge_ver = new HashMap>(Math.max(0, 2*_map282.size)); + for (int _i283 = 0; + (_map282.size < 0) ? iprot.peekMap() : (_i283 < _map282.size); + ++_i283) { - int _key260; - List _val261; - _key260 = iprot.readI32(); + int _key284; + List _val285; + _key284 = iprot.readI32(); { - TList _list262 = iprot.readListBegin(); - _val261 = new ArrayList(Math.max(0, _list262.size)); - for (int _i263 = 0; - (_list262.size < 0) ? iprot.peekList() : (_i263 < _list262.size); - ++_i263) + TList _list286 = iprot.readListBegin(); + _val285 = new ArrayList(Math.max(0, _list286.size)); + for (int _i287 = 0; + (_list286.size < 0) ? iprot.peekList() : (_i287 < _list286.size); + ++_i287) { - long _elem264; - _elem264 = iprot.readI64(); - _val261.add(_elem264); + long _elem288; + _elem288 = iprot.readI64(); + _val285.add(_elem288); } iprot.readListEnd(); } - this.edge_ver.put(_key260, _val261); + this.edge_ver.put(_key284, _val285); } iprot.readMapEnd(); } @@ -510,9 +510,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TERM_OF_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.I64, this.term_of_parts.size())); - for (Map.Entry _iter265 : this.term_of_parts.entrySet()) { - oprot.writeI32(_iter265.getKey()); - oprot.writeI64(_iter265.getValue()); + for (Map.Entry _iter289 : this.term_of_parts.entrySet()) { + oprot.writeI32(_iter289.getKey()); + oprot.writeI64(_iter289.getValue()); } oprot.writeMapEnd(); } @@ -537,12 +537,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGE_VER_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.edge_ver.size())); - for (Map.Entry> _iter266 : this.edge_ver.entrySet()) { - oprot.writeI32(_iter266.getKey()); + for (Map.Entry> _iter290 : this.edge_ver.entrySet()) { + oprot.writeI32(_iter290.getKey()); { - oprot.writeListBegin(new TList(TType.I64, _iter266.getValue().size())); - for (long _iter267 : _iter266.getValue()) { - oprot.writeI64(_iter267); + oprot.writeListBegin(new TList(TType.I64, _iter290.getValue().size())); + for (long _iter291 : _iter290.getValue()) { + oprot.writeI64(_iter291); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java index a02c3ec93..641b74622 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java @@ -341,29 +341,29 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map222 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map222.size)); - for (int _i223 = 0; - (_map222.size < 0) ? iprot.peekMap() : (_i223 < _map222.size); - ++_i223) + TMap _map246 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map246.size)); + for (int _i247 = 0; + (_map246.size < 0) ? iprot.peekMap() : (_i247 < _map246.size); + ++_i247) { - int _key224; - List _val225; - _key224 = iprot.readI32(); + int _key248; + List _val249; + _key248 = iprot.readI32(); { - TList _list226 = iprot.readListBegin(); - _val225 = new ArrayList(Math.max(0, _list226.size)); - for (int _i227 = 0; - (_list226.size < 0) ? iprot.peekList() : (_i227 < _list226.size); - ++_i227) + TList _list250 = iprot.readListBegin(); + _val249 = new ArrayList(Math.max(0, _list250.size)); + for (int _i251 = 0; + (_list250.size < 0) ? iprot.peekList() : (_i251 < _list250.size); + ++_i251) { - byte[] _elem228; - _elem228 = iprot.readBinary(); - _val225.add(_elem228); + byte[] _elem252; + _elem252 = iprot.readBinary(); + _val249.add(_elem252); } iprot.readListEnd(); } - this.parts.put(_key224, _val225); + this.parts.put(_key248, _val249); } iprot.readMapEnd(); } @@ -403,12 +403,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter229 : this.parts.entrySet()) { - oprot.writeI32(_iter229.getKey()); + for (Map.Entry> _iter253 : this.parts.entrySet()) { + oprot.writeI32(_iter253.getKey()); { - oprot.writeListBegin(new TList(TType.STRING, _iter229.getValue().size())); - for (byte[] _iter230 : _iter229.getValue()) { - oprot.writeBinary(_iter230); + oprot.writeListBegin(new TList(TType.STRING, _iter253.getValue().size())); + for (byte[] _iter254 : _iter253.getValue()) { + oprot.writeBinary(_iter254); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java index 0a5f6ede2..34849519a 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java @@ -275,17 +275,17 @@ public void read(TProtocol iprot) throws TException { case KEY_VALUES: if (__field.type == TType.MAP) { { - TMap _map231 = iprot.readMapBegin(); - this.key_values = new HashMap(Math.max(0, 2*_map231.size)); - for (int _i232 = 0; - (_map231.size < 0) ? iprot.peekMap() : (_i232 < _map231.size); - ++_i232) + TMap _map255 = iprot.readMapBegin(); + this.key_values = new HashMap(Math.max(0, 2*_map255.size)); + for (int _i256 = 0; + (_map255.size < 0) ? iprot.peekMap() : (_i256 < _map255.size); + ++_i256) { - byte[] _key233; - byte[] _val234; - _key233 = iprot.readBinary(); - _val234 = iprot.readBinary(); - this.key_values.put(_key233, _val234); + byte[] _key257; + byte[] _val258; + _key257 = iprot.readBinary(); + _val258 = iprot.readBinary(); + this.key_values.put(_key257, _val258); } iprot.readMapEnd(); } @@ -319,9 +319,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KEY_VALUES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.key_values.size())); - for (Map.Entry _iter235 : this.key_values.entrySet()) { - oprot.writeBinary(_iter235.getKey()); - oprot.writeBinary(_iter235.getValue()); + for (Map.Entry _iter259 : this.key_values.entrySet()) { + oprot.writeBinary(_iter259.getKey()); + oprot.writeBinary(_iter259.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java index 74f10c522..17ebf8c94 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java @@ -277,30 +277,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map236 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map236.size)); - for (int _i237 = 0; - (_map236.size < 0) ? iprot.peekMap() : (_i237 < _map236.size); - ++_i237) + TMap _map260 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map260.size)); + for (int _i261 = 0; + (_map260.size < 0) ? iprot.peekMap() : (_i261 < _map260.size); + ++_i261) { - int _key238; - List _val239; - _key238 = iprot.readI32(); + int _key262; + List _val263; + _key262 = iprot.readI32(); { - TList _list240 = iprot.readListBegin(); - _val239 = new ArrayList(Math.max(0, _list240.size)); - for (int _i241 = 0; - (_list240.size < 0) ? iprot.peekList() : (_i241 < _list240.size); - ++_i241) + TList _list264 = iprot.readListBegin(); + _val263 = new ArrayList(Math.max(0, _list264.size)); + for (int _i265 = 0; + (_list264.size < 0) ? iprot.peekList() : (_i265 < _list264.size); + ++_i265) { - com.vesoft.nebula.KeyValue _elem242; - _elem242 = new com.vesoft.nebula.KeyValue(); - _elem242.read(iprot); - _val239.add(_elem242); + com.vesoft.nebula.KeyValue _elem266; + _elem266 = new com.vesoft.nebula.KeyValue(); + _elem266.read(iprot); + _val263.add(_elem266); } iprot.readListEnd(); } - this.parts.put(_key238, _val239); + this.parts.put(_key262, _val263); } iprot.readMapEnd(); } @@ -332,12 +332,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter243 : this.parts.entrySet()) { - oprot.writeI32(_iter243.getKey()); + for (Map.Entry> _iter267 : this.parts.entrySet()) { + oprot.writeI32(_iter267.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter243.getValue().size())); - for (com.vesoft.nebula.KeyValue _iter244 : _iter243.getValue()) { - _iter244.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter267.getValue().size())); + for (com.vesoft.nebula.KeyValue _iter268 : _iter267.getValue()) { + _iter268.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java index 7e8a38843..3fb9d63f8 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java @@ -277,29 +277,29 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map245 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map245.size)); - for (int _i246 = 0; - (_map245.size < 0) ? iprot.peekMap() : (_i246 < _map245.size); - ++_i246) + TMap _map269 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map269.size)); + for (int _i270 = 0; + (_map269.size < 0) ? iprot.peekMap() : (_i270 < _map269.size); + ++_i270) { - int _key247; - List _val248; - _key247 = iprot.readI32(); + int _key271; + List _val272; + _key271 = iprot.readI32(); { - TList _list249 = iprot.readListBegin(); - _val248 = new ArrayList(Math.max(0, _list249.size)); - for (int _i250 = 0; - (_list249.size < 0) ? iprot.peekList() : (_i250 < _list249.size); - ++_i250) + TList _list273 = iprot.readListBegin(); + _val272 = new ArrayList(Math.max(0, _list273.size)); + for (int _i274 = 0; + (_list273.size < 0) ? iprot.peekList() : (_i274 < _list273.size); + ++_i274) { - byte[] _elem251; - _elem251 = iprot.readBinary(); - _val248.add(_elem251); + byte[] _elem275; + _elem275 = iprot.readBinary(); + _val272.add(_elem275); } iprot.readListEnd(); } - this.parts.put(_key247, _val248); + this.parts.put(_key271, _val272); } iprot.readMapEnd(); } @@ -331,12 +331,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter252 : this.parts.entrySet()) { - oprot.writeI32(_iter252.getKey()); + for (Map.Entry> _iter276 : this.parts.entrySet()) { + oprot.writeI32(_iter276.getKey()); { - oprot.writeListBegin(new TList(TType.STRING, _iter252.getValue().size())); - for (byte[] _iter253 : _iter252.getValue()) { - oprot.writeBinary(_iter253); + oprot.writeListBegin(new TList(TType.STRING, _iter276.getValue().size())); + for (byte[] _iter277 : _iter276.getValue()) { + oprot.writeBinary(_iter277); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java index 905ce8be5..f715bcaa8 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java @@ -339,15 +339,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list214 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list214.size)); - for (int _i215 = 0; - (_list214.size < 0) ? iprot.peekList() : (_i215 < _list214.size); - ++_i215) + TList _list238 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list238.size)); + for (int _i239 = 0; + (_list238.size < 0) ? iprot.peekList() : (_i239 < _list238.size); + ++_i239) { - int _elem216; - _elem216 = iprot.readI32(); - this.parts.add(_elem216); + int _elem240; + _elem240 = iprot.readI32(); + this.parts.add(_elem240); } iprot.readListEnd(); } @@ -387,8 +387,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter217 : this.parts) { - oprot.writeI32(_iter217); + for (int _iter241 : this.parts) { + oprot.writeI32(_iter241); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java new file mode 100644 index 000000000..abb83cebe --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java @@ -0,0 +1,369 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ScanCursor implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("ScanCursor"); + private static final TField HAS_NEXT_FIELD_DESC = new TField("has_next", TType.BOOL, (short)3); + private static final TField NEXT_CURSOR_FIELD_DESC = new TField("next_cursor", TType.STRING, (short)4); + + public boolean has_next; + public byte[] next_cursor; + public static final int HAS_NEXT = 3; + public static final int NEXT_CURSOR = 4; + + // isset id assignments + private static final int __HAS_NEXT_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(HAS_NEXT, new FieldMetaData("has_next", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(NEXT_CURSOR, new FieldMetaData("next_cursor", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ScanCursor.class, metaDataMap); + } + + public ScanCursor() { + } + + public ScanCursor( + boolean has_next) { + this(); + this.has_next = has_next; + setHas_nextIsSet(true); + } + + public ScanCursor( + boolean has_next, + byte[] next_cursor) { + this(); + this.has_next = has_next; + setHas_nextIsSet(true); + this.next_cursor = next_cursor; + } + + public static class Builder { + private boolean has_next; + private byte[] next_cursor; + + BitSet __optional_isset = new BitSet(1); + + public Builder() { + } + + public Builder setHas_next(final boolean has_next) { + this.has_next = has_next; + __optional_isset.set(__HAS_NEXT_ISSET_ID, true); + return this; + } + + public Builder setNext_cursor(final byte[] next_cursor) { + this.next_cursor = next_cursor; + return this; + } + + public ScanCursor build() { + ScanCursor result = new ScanCursor(); + if (__optional_isset.get(__HAS_NEXT_ISSET_ID)) { + result.setHas_next(this.has_next); + } + result.setNext_cursor(this.next_cursor); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ScanCursor(ScanCursor other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.has_next = TBaseHelper.deepCopy(other.has_next); + if (other.isSetNext_cursor()) { + this.next_cursor = TBaseHelper.deepCopy(other.next_cursor); + } + } + + public ScanCursor deepCopy() { + return new ScanCursor(this); + } + + public boolean isHas_next() { + return this.has_next; + } + + public ScanCursor setHas_next(boolean has_next) { + this.has_next = has_next; + setHas_nextIsSet(true); + return this; + } + + public void unsetHas_next() { + __isset_bit_vector.clear(__HAS_NEXT_ISSET_ID); + } + + // Returns true if field has_next is set (has been assigned a value) and false otherwise + public boolean isSetHas_next() { + return __isset_bit_vector.get(__HAS_NEXT_ISSET_ID); + } + + public void setHas_nextIsSet(boolean __value) { + __isset_bit_vector.set(__HAS_NEXT_ISSET_ID, __value); + } + + public byte[] getNext_cursor() { + return this.next_cursor; + } + + public ScanCursor setNext_cursor(byte[] next_cursor) { + this.next_cursor = next_cursor; + return this; + } + + public void unsetNext_cursor() { + this.next_cursor = null; + } + + // Returns true if field next_cursor is set (has been assigned a value) and false otherwise + public boolean isSetNext_cursor() { + return this.next_cursor != null; + } + + public void setNext_cursorIsSet(boolean __value) { + if (!__value) { + this.next_cursor = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case HAS_NEXT: + if (__value == null) { + unsetHas_next(); + } else { + setHas_next((Boolean)__value); + } + break; + + case NEXT_CURSOR: + if (__value == null) { + unsetNext_cursor(); + } else { + setNext_cursor((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case HAS_NEXT: + return new Boolean(isHas_next()); + + case NEXT_CURSOR: + return getNext_cursor(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ScanCursor)) + return false; + ScanCursor that = (ScanCursor)_that; + + if (!TBaseHelper.equalsNobinary(this.has_next, that.has_next)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetNext_cursor(), that.isSetNext_cursor(), this.next_cursor, that.next_cursor)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {has_next, next_cursor}); + } + + @Override + public int compareTo(ScanCursor other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetHas_next()).compareTo(other.isSetHas_next()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(has_next, other.has_next); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetNext_cursor()).compareTo(other.isSetNext_cursor()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(next_cursor, other.next_cursor); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case HAS_NEXT: + if (__field.type == TType.BOOL) { + this.has_next = iprot.readBool(); + setHas_nextIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case NEXT_CURSOR: + if (__field.type == TType.STRING) { + this.next_cursor = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(HAS_NEXT_FIELD_DESC); + oprot.writeBool(this.has_next); + oprot.writeFieldEnd(); + if (this.next_cursor != null) { + if (isSetNext_cursor()) { + oprot.writeFieldBegin(NEXT_CURSOR_FIELD_DESC); + oprot.writeBinary(this.next_cursor); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ScanCursor"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("has_next"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isHas_next(), indent + 1, prettyPrint)); + first = false; + if (isSetNext_cursor()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("next_cursor"); + sb.append(space); + sb.append(":").append(space); + if (this.getNext_cursor() == null) { + sb.append("null"); + } else { + int __next_cursor_size = Math.min(this.getNext_cursor().length, 128); + for (int i = 0; i < __next_cursor_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getNext_cursor()[i]).length() > 1 ? Integer.toHexString(this.getNext_cursor()[i]).substring(Integer.toHexString(this.getNext_cursor()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getNext_cursor()[i]).toUpperCase()); + } + if (this.getNext_cursor().length > 128) sb.append(" ..."); + } + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java index 39bb5df67..163c33195 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java @@ -27,20 +27,18 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("ScanEdgeRequest"); private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)2); - private static final TField CURSOR_FIELD_DESC = new TField("cursor", TType.STRING, (short)3); - private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.STRUCT, (short)4); - private static final TField LIMIT_FIELD_DESC = new TField("limit", TType.I64, (short)5); - private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)6); - private static final TField END_TIME_FIELD_DESC = new TField("end_time", TType.I64, (short)7); - private static final TField FILTER_FIELD_DESC = new TField("filter", TType.STRING, (short)8); - private static final TField ONLY_LATEST_VERSION_FIELD_DESC = new TField("only_latest_version", TType.BOOL, (short)9); - private static final TField ENABLE_READ_FROM_FOLLOWER_FIELD_DESC = new TField("enable_read_from_follower", TType.BOOL, (short)10); - private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)11); + private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); + private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.STRUCT, (short)3); + private static final TField LIMIT_FIELD_DESC = new TField("limit", TType.I64, (short)4); + private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)5); + private static final TField END_TIME_FIELD_DESC = new TField("end_time", TType.I64, (short)6); + private static final TField FILTER_FIELD_DESC = new TField("filter", TType.STRING, (short)7); + private static final TField ONLY_LATEST_VERSION_FIELD_DESC = new TField("only_latest_version", TType.BOOL, (short)8); + private static final TField ENABLE_READ_FROM_FOLLOWER_FIELD_DESC = new TField("enable_read_from_follower", TType.BOOL, (short)9); + private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)10); public int space_id; - public int part_id; - public byte[] cursor; + public Map parts; public EdgeProp return_columns; public long limit; public long start_time; @@ -50,26 +48,24 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, public boolean enable_read_from_follower; public RequestCommon common; public static final int SPACE_ID = 1; - public static final int PART_ID = 2; - public static final int CURSOR = 3; - public static final int RETURN_COLUMNS = 4; - public static final int LIMIT = 5; - public static final int START_TIME = 6; - public static final int END_TIME = 7; - public static final int FILTER = 8; - public static final int ONLY_LATEST_VERSION = 9; - public static final int ENABLE_READ_FROM_FOLLOWER = 10; - public static final int COMMON = 11; + public static final int PARTS = 2; + public static final int RETURN_COLUMNS = 3; + public static final int LIMIT = 4; + public static final int START_TIME = 5; + public static final int END_TIME = 6; + public static final int FILTER = 7; + public static final int ONLY_LATEST_VERSION = 8; + public static final int ENABLE_READ_FROM_FOLLOWER = 9; + public static final int COMMON = 10; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; - private static final int __PART_ID_ISSET_ID = 1; - private static final int __LIMIT_ISSET_ID = 2; - private static final int __START_TIME_ISSET_ID = 3; - private static final int __END_TIME_ISSET_ID = 4; - private static final int __ONLY_LATEST_VERSION_ISSET_ID = 5; - private static final int __ENABLE_READ_FROM_FOLLOWER_ISSET_ID = 6; - private BitSet __isset_bit_vector = new BitSet(7); + private static final int __LIMIT_ISSET_ID = 1; + private static final int __START_TIME_ISSET_ID = 2; + private static final int __END_TIME_ISSET_ID = 3; + private static final int __ONLY_LATEST_VERSION_ISSET_ID = 4; + private static final int __ENABLE_READ_FROM_FOLLOWER_ISSET_ID = 5; + private BitSet __isset_bit_vector = new BitSet(6); public static final Map metaDataMap; @@ -77,10 +73,10 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(CURSOR, new FieldMetaData("cursor", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, ScanCursor.class)))); tmpMetaDataMap.put(RETURN_COLUMNS, new FieldMetaData("return_columns", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, EdgeProp.class))); tmpMetaDataMap.put(LIMIT, new FieldMetaData("limit", TFieldRequirementType.DEFAULT, @@ -113,7 +109,7 @@ public ScanEdgeRequest() { public ScanEdgeRequest( int space_id, - int part_id, + Map parts, EdgeProp return_columns, long limit, boolean only_latest_version, @@ -121,8 +117,7 @@ public ScanEdgeRequest( this(); this.space_id = space_id; setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); + this.parts = parts; this.return_columns = return_columns; this.limit = limit; setLimitIsSet(true); @@ -134,8 +129,7 @@ public ScanEdgeRequest( public ScanEdgeRequest( int space_id, - int part_id, - byte[] cursor, + Map parts, EdgeProp return_columns, long limit, long start_time, @@ -147,9 +141,7 @@ public ScanEdgeRequest( this(); this.space_id = space_id; setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); - this.cursor = cursor; + this.parts = parts; this.return_columns = return_columns; this.limit = limit; setLimitIsSet(true); @@ -167,8 +159,7 @@ public ScanEdgeRequest( public static class Builder { private int space_id; - private int part_id; - private byte[] cursor; + private Map parts; private EdgeProp return_columns; private long limit; private long start_time; @@ -178,7 +169,7 @@ public static class Builder { private boolean enable_read_from_follower; private RequestCommon common; - BitSet __optional_isset = new BitSet(7); + BitSet __optional_isset = new BitSet(6); public Builder() { } @@ -189,14 +180,8 @@ public Builder setSpace_id(final int space_id) { return this; } - public Builder setPart_id(final int part_id) { - this.part_id = part_id; - __optional_isset.set(__PART_ID_ISSET_ID, true); - return this; - } - - public Builder setCursor(final byte[] cursor) { - this.cursor = cursor; + public Builder setParts(final Map parts) { + this.parts = parts; return this; } @@ -250,10 +235,7 @@ public ScanEdgeRequest build() { if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { result.setSpace_id(this.space_id); } - if (__optional_isset.get(__PART_ID_ISSET_ID)) { - result.setPart_id(this.part_id); - } - result.setCursor(this.cursor); + result.setParts(this.parts); result.setReturn_columns(this.return_columns); if (__optional_isset.get(__LIMIT_ISSET_ID)) { result.setLimit(this.limit); @@ -287,9 +269,8 @@ public ScanEdgeRequest(ScanEdgeRequest other) { __isset_bit_vector.clear(); __isset_bit_vector.or(other.__isset_bit_vector); this.space_id = TBaseHelper.deepCopy(other.space_id); - this.part_id = TBaseHelper.deepCopy(other.part_id); - if (other.isSetCursor()) { - this.cursor = TBaseHelper.deepCopy(other.cursor); + if (other.isSetParts()) { + this.parts = TBaseHelper.deepCopy(other.parts); } if (other.isSetReturn_columns()) { this.return_columns = TBaseHelper.deepCopy(other.return_columns); @@ -334,50 +315,27 @@ public void setSpace_idIsSet(boolean __value) { __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); } - public int getPart_id() { - return this.part_id; - } - - public ScanEdgeRequest setPart_id(int part_id) { - this.part_id = part_id; - setPart_idIsSet(true); - return this; - } - - public void unsetPart_id() { - __isset_bit_vector.clear(__PART_ID_ISSET_ID); - } - - // Returns true if field part_id is set (has been assigned a value) and false otherwise - public boolean isSetPart_id() { - return __isset_bit_vector.get(__PART_ID_ISSET_ID); - } - - public void setPart_idIsSet(boolean __value) { - __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); - } - - public byte[] getCursor() { - return this.cursor; + public Map getParts() { + return this.parts; } - public ScanEdgeRequest setCursor(byte[] cursor) { - this.cursor = cursor; + public ScanEdgeRequest setParts(Map parts) { + this.parts = parts; return this; } - public void unsetCursor() { - this.cursor = null; + public void unsetParts() { + this.parts = null; } - // Returns true if field cursor is set (has been assigned a value) and false otherwise - public boolean isSetCursor() { - return this.cursor != null; + // Returns true if field parts is set (has been assigned a value) and false otherwise + public boolean isSetParts() { + return this.parts != null; } - public void setCursorIsSet(boolean __value) { + public void setPartsIsSet(boolean __value) { if (!__value) { - this.cursor = null; + this.parts = null; } } @@ -568,6 +526,7 @@ public void setCommonIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SPACE_ID: @@ -578,19 +537,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case PART_ID: - if (__value == null) { - unsetPart_id(); - } else { - setPart_id((Integer)__value); - } - break; - - case CURSOR: + case PARTS: if (__value == null) { - unsetCursor(); + unsetParts(); } else { - setCursor((byte[])__value); + setParts((Map)__value); } break; @@ -668,11 +619,8 @@ public Object getFieldValue(int fieldID) { case SPACE_ID: return new Integer(getSpace_id()); - case PART_ID: - return new Integer(getPart_id()); - - case CURSOR: - return getCursor(); + case PARTS: + return getParts(); case RETURN_COLUMNS: return getReturn_columns(); @@ -715,9 +663,7 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } - if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetCursor(), that.isSetCursor(), this.cursor, that.cursor)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetReturn_columns(), that.isSetReturn_columns(), this.return_columns, that.return_columns)) { return false; } @@ -740,7 +686,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, part_id, cursor, return_columns, limit, start_time, end_time, filter, only_latest_version, enable_read_from_follower, common}); + return Arrays.deepHashCode(new Object[] {space_id, parts, return_columns, limit, start_time, end_time, filter, only_latest_version, enable_read_from_follower, common}); } @Override @@ -763,19 +709,11 @@ public int compareTo(ScanEdgeRequest other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); + lastComparison = Boolean.valueOf(isSetParts()).compareTo(other.isSetParts()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(part_id, other.part_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetCursor()).compareTo(other.isSetCursor()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(cursor, other.cursor); + lastComparison = TBaseHelper.compareTo(parts, other.parts); if (lastComparison != 0) { return lastComparison; } @@ -865,17 +803,24 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case PART_ID: - if (__field.type == TType.I32) { - this.part_id = iprot.readI32(); - setPart_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CURSOR: - if (__field.type == TType.STRING) { - this.cursor = iprot.readBinary(); + case PARTS: + if (__field.type == TType.MAP) { + { + TMap _map203 = iprot.readMapBegin(); + this.parts = new HashMap(Math.max(0, 2*_map203.size)); + for (int _i204 = 0; + (_map203.size < 0) ? iprot.peekMap() : (_i204 < _map203.size); + ++_i204) + { + int _key205; + ScanCursor _val206; + _key205 = iprot.readI32(); + _val206 = new ScanCursor(); + _val206.read(iprot); + this.parts.put(_key205, _val206); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -963,15 +908,17 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); oprot.writeI32(this.space_id); oprot.writeFieldEnd(); - oprot.writeFieldBegin(PART_ID_FIELD_DESC); - oprot.writeI32(this.part_id); - oprot.writeFieldEnd(); - if (this.cursor != null) { - if (isSetCursor()) { - oprot.writeFieldBegin(CURSOR_FIELD_DESC); - oprot.writeBinary(this.cursor); - oprot.writeFieldEnd(); + if (this.parts != null) { + oprot.writeFieldBegin(PARTS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.parts.size())); + for (Map.Entry _iter207 : this.parts.entrySet()) { + oprot.writeI32(_iter207.getKey()); + _iter207.getValue().write(oprot); + } + oprot.writeMapEnd(); } + oprot.writeFieldEnd(); } if (this.return_columns != null) { oprot.writeFieldBegin(RETURN_COLUMNS_FIELD_DESC); @@ -1039,30 +986,15 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("part_id"); + sb.append("parts"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); - first = false; - if (isSetCursor()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("cursor"); - sb.append(space); - sb.append(":").append(space); - if (this.getCursor() == null) { - sb.append("null"); - } else { - int __cursor_size = Math.min(this.getCursor().length, 128); - for (int i = 0; i < __cursor_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getCursor()[i]).length() > 1 ? Integer.toHexString(this.getCursor()[i]).substring(Integer.toHexString(this.getCursor()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getCursor()[i]).toUpperCase()); - } - if (this.getCursor().length > 128) sb.append(" ..."); - } - first = false; + if (this.getParts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParts(), indent + 1, prettyPrint)); } + first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); sb.append("return_columns"); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java index 6b2b56fb4..36a6c53df 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java @@ -28,21 +28,16 @@ public class ScanEdgeResponse implements TBase, java.io.Serializable, Cloneable private static final TStruct STRUCT_DESC = new TStruct("ScanEdgeResponse"); private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); private static final TField EDGE_DATA_FIELD_DESC = new TField("edge_data", TType.STRUCT, (short)2); - private static final TField HAS_NEXT_FIELD_DESC = new TField("has_next", TType.BOOL, (short)3); - private static final TField NEXT_CURSOR_FIELD_DESC = new TField("next_cursor", TType.STRING, (short)4); + private static final TField CURSORS_FIELD_DESC = new TField("cursors", TType.MAP, (short)3); public ResponseCommon result; public com.vesoft.nebula.DataSet edge_data; - public boolean has_next; - public byte[] next_cursor; + public Map cursors; public static final int RESULT = 1; public static final int EDGE_DATA = 2; - public static final int HAS_NEXT = 3; - public static final int NEXT_CURSOR = 4; + public static final int CURSORS = 3; // isset id assignments - private static final int __HAS_NEXT_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; @@ -52,10 +47,10 @@ public class ScanEdgeResponse implements TBase, java.io.Serializable, Cloneable new StructMetaData(TType.STRUCT, ResponseCommon.class))); tmpMetaDataMap.put(EDGE_DATA, new FieldMetaData("edge_data", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); - tmpMetaDataMap.put(HAS_NEXT, new FieldMetaData("has_next", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.BOOL))); - tmpMetaDataMap.put(NEXT_CURSOR, new FieldMetaData("next_cursor", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(CURSORS, new FieldMetaData("cursors", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, ScanCursor.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -75,34 +70,17 @@ public ScanEdgeResponse( public ScanEdgeResponse( ResponseCommon result, com.vesoft.nebula.DataSet edge_data, - boolean has_next) { + Map cursors) { this(); this.result = result; this.edge_data = edge_data; - this.has_next = has_next; - setHas_nextIsSet(true); - } - - public ScanEdgeResponse( - ResponseCommon result, - com.vesoft.nebula.DataSet edge_data, - boolean has_next, - byte[] next_cursor) { - this(); - this.result = result; - this.edge_data = edge_data; - this.has_next = has_next; - setHas_nextIsSet(true); - this.next_cursor = next_cursor; + this.cursors = cursors; } public static class Builder { private ResponseCommon result; private com.vesoft.nebula.DataSet edge_data; - private boolean has_next; - private byte[] next_cursor; - - BitSet __optional_isset = new BitSet(1); + private Map cursors; public Builder() { } @@ -117,14 +95,8 @@ public Builder setEdge_data(final com.vesoft.nebula.DataSet edge_data) { return this; } - public Builder setHas_next(final boolean has_next) { - this.has_next = has_next; - __optional_isset.set(__HAS_NEXT_ISSET_ID, true); - return this; - } - - public Builder setNext_cursor(final byte[] next_cursor) { - this.next_cursor = next_cursor; + public Builder setCursors(final Map cursors) { + this.cursors = cursors; return this; } @@ -132,10 +104,7 @@ public ScanEdgeResponse build() { ScanEdgeResponse result = new ScanEdgeResponse(); result.setResult(this.result); result.setEdge_data(this.edge_data); - if (__optional_isset.get(__HAS_NEXT_ISSET_ID)) { - result.setHas_next(this.has_next); - } - result.setNext_cursor(this.next_cursor); + result.setCursors(this.cursors); return result; } } @@ -148,17 +117,14 @@ public static Builder builder() { * Performs a deep copy on other. */ public ScanEdgeResponse(ScanEdgeResponse other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); if (other.isSetResult()) { this.result = TBaseHelper.deepCopy(other.result); } if (other.isSetEdge_data()) { this.edge_data = TBaseHelper.deepCopy(other.edge_data); } - this.has_next = TBaseHelper.deepCopy(other.has_next); - if (other.isSetNext_cursor()) { - this.next_cursor = TBaseHelper.deepCopy(other.next_cursor); + if (other.isSetCursors()) { + this.cursors = TBaseHelper.deepCopy(other.cursors); } } @@ -214,53 +180,31 @@ public void setEdge_dataIsSet(boolean __value) { } } - public boolean isHas_next() { - return this.has_next; + public Map getCursors() { + return this.cursors; } - public ScanEdgeResponse setHas_next(boolean has_next) { - this.has_next = has_next; - setHas_nextIsSet(true); + public ScanEdgeResponse setCursors(Map cursors) { + this.cursors = cursors; return this; } - public void unsetHas_next() { - __isset_bit_vector.clear(__HAS_NEXT_ISSET_ID); - } - - // Returns true if field has_next is set (has been assigned a value) and false otherwise - public boolean isSetHas_next() { - return __isset_bit_vector.get(__HAS_NEXT_ISSET_ID); + public void unsetCursors() { + this.cursors = null; } - public void setHas_nextIsSet(boolean __value) { - __isset_bit_vector.set(__HAS_NEXT_ISSET_ID, __value); + // Returns true if field cursors is set (has been assigned a value) and false otherwise + public boolean isSetCursors() { + return this.cursors != null; } - public byte[] getNext_cursor() { - return this.next_cursor; - } - - public ScanEdgeResponse setNext_cursor(byte[] next_cursor) { - this.next_cursor = next_cursor; - return this; - } - - public void unsetNext_cursor() { - this.next_cursor = null; - } - - // Returns true if field next_cursor is set (has been assigned a value) and false otherwise - public boolean isSetNext_cursor() { - return this.next_cursor != null; - } - - public void setNext_cursorIsSet(boolean __value) { + public void setCursorsIsSet(boolean __value) { if (!__value) { - this.next_cursor = null; + this.cursors = null; } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case RESULT: @@ -279,19 +223,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case HAS_NEXT: - if (__value == null) { - unsetHas_next(); - } else { - setHas_next((Boolean)__value); - } - break; - - case NEXT_CURSOR: + case CURSORS: if (__value == null) { - unsetNext_cursor(); + unsetCursors(); } else { - setNext_cursor((byte[])__value); + setCursors((Map)__value); } break; @@ -308,11 +244,8 @@ public Object getFieldValue(int fieldID) { case EDGE_DATA: return getEdge_data(); - case HAS_NEXT: - return new Boolean(isHas_next()); - - case NEXT_CURSOR: - return getNext_cursor(); + case CURSORS: + return getCursors(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -333,16 +266,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetEdge_data(), that.isSetEdge_data(), this.edge_data, that.edge_data)) { return false; } - if (!TBaseHelper.equalsNobinary(this.has_next, that.has_next)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetNext_cursor(), that.isSetNext_cursor(), this.next_cursor, that.next_cursor)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetCursors(), that.isSetCursors(), this.cursors, that.cursors)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, edge_data, has_next, next_cursor}); + return Arrays.deepHashCode(new Object[] {result, edge_data, cursors}); } public void read(TProtocol iprot) throws TException { @@ -372,17 +303,24 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case HAS_NEXT: - if (__field.type == TType.BOOL) { - this.has_next = iprot.readBool(); - setHas_nextIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case NEXT_CURSOR: - if (__field.type == TType.STRING) { - this.next_cursor = iprot.readBinary(); + case CURSORS: + if (__field.type == TType.MAP) { + { + TMap _map208 = iprot.readMapBegin(); + this.cursors = new HashMap(Math.max(0, 2*_map208.size)); + for (int _i209 = 0; + (_map208.size < 0) ? iprot.peekMap() : (_i209 < _map208.size); + ++_i209) + { + int _key210; + ScanCursor _val211; + _key210 = iprot.readI32(); + _val211 = new ScanCursor(); + _val211.read(iprot); + this.cursors.put(_key210, _val211); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -414,15 +352,17 @@ public void write(TProtocol oprot) throws TException { this.edge_data.write(oprot); oprot.writeFieldEnd(); } - oprot.writeFieldBegin(HAS_NEXT_FIELD_DESC); - oprot.writeBool(this.has_next); - oprot.writeFieldEnd(); - if (this.next_cursor != null) { - if (isSetNext_cursor()) { - oprot.writeFieldBegin(NEXT_CURSOR_FIELD_DESC); - oprot.writeBinary(this.next_cursor); - oprot.writeFieldEnd(); + if (this.cursors != null) { + oprot.writeFieldBegin(CURSORS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.cursors.size())); + for (Map.Entry _iter212 : this.cursors.entrySet()) { + oprot.writeI32(_iter212.getKey()); + _iter212.getValue().write(oprot); + } + oprot.writeMapEnd(); } + oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); @@ -467,30 +407,15 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("has_next"); + sb.append("cursors"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isHas_next(), indent + 1, prettyPrint)); - first = false; - if (isSetNext_cursor()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("next_cursor"); - sb.append(space); - sb.append(":").append(space); - if (this.getNext_cursor() == null) { - sb.append("null"); - } else { - int __next_cursor_size = Math.min(this.getNext_cursor().length, 128); - for (int i = 0; i < __next_cursor_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getNext_cursor()[i]).length() > 1 ? Integer.toHexString(this.getNext_cursor()[i]).substring(Integer.toHexString(this.getNext_cursor()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getNext_cursor()[i]).toUpperCase()); - } - if (this.getNext_cursor().length > 128) sb.append(" ..."); - } - first = false; + if (this.getCursors() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCursors(), indent + 1, prettyPrint)); } + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexRequest.java index 73fb4532b..204fbdf50 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexRequest.java @@ -27,21 +27,19 @@ public class ScanVertexRequest implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("ScanVertexRequest"); private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)2); - private static final TField CURSOR_FIELD_DESC = new TField("cursor", TType.STRING, (short)3); - private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.STRUCT, (short)4); - private static final TField LIMIT_FIELD_DESC = new TField("limit", TType.I64, (short)5); - private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)6); - private static final TField END_TIME_FIELD_DESC = new TField("end_time", TType.I64, (short)7); - private static final TField FILTER_FIELD_DESC = new TField("filter", TType.STRING, (short)8); - private static final TField ONLY_LATEST_VERSION_FIELD_DESC = new TField("only_latest_version", TType.BOOL, (short)9); - private static final TField ENABLE_READ_FROM_FOLLOWER_FIELD_DESC = new TField("enable_read_from_follower", TType.BOOL, (short)10); - private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)11); + private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); + private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.LIST, (short)3); + private static final TField LIMIT_FIELD_DESC = new TField("limit", TType.I64, (short)4); + private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)5); + private static final TField END_TIME_FIELD_DESC = new TField("end_time", TType.I64, (short)6); + private static final TField FILTER_FIELD_DESC = new TField("filter", TType.STRING, (short)7); + private static final TField ONLY_LATEST_VERSION_FIELD_DESC = new TField("only_latest_version", TType.BOOL, (short)8); + private static final TField ENABLE_READ_FROM_FOLLOWER_FIELD_DESC = new TField("enable_read_from_follower", TType.BOOL, (short)9); + private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)10); public int space_id; - public int part_id; - public byte[] cursor; - public VertexProp return_columns; + public Map parts; + public List return_columns; public long limit; public long start_time; public long end_time; @@ -50,26 +48,24 @@ public class ScanVertexRequest implements TBase, java.io.Serializable, Cloneable public boolean enable_read_from_follower; public RequestCommon common; public static final int SPACE_ID = 1; - public static final int PART_ID = 2; - public static final int CURSOR = 3; - public static final int RETURN_COLUMNS = 4; - public static final int LIMIT = 5; - public static final int START_TIME = 6; - public static final int END_TIME = 7; - public static final int FILTER = 8; - public static final int ONLY_LATEST_VERSION = 9; - public static final int ENABLE_READ_FROM_FOLLOWER = 10; - public static final int COMMON = 11; + public static final int PARTS = 2; + public static final int RETURN_COLUMNS = 3; + public static final int LIMIT = 4; + public static final int START_TIME = 5; + public static final int END_TIME = 6; + public static final int FILTER = 7; + public static final int ONLY_LATEST_VERSION = 8; + public static final int ENABLE_READ_FROM_FOLLOWER = 9; + public static final int COMMON = 10; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; - private static final int __PART_ID_ISSET_ID = 1; - private static final int __LIMIT_ISSET_ID = 2; - private static final int __START_TIME_ISSET_ID = 3; - private static final int __END_TIME_ISSET_ID = 4; - private static final int __ONLY_LATEST_VERSION_ISSET_ID = 5; - private static final int __ENABLE_READ_FROM_FOLLOWER_ISSET_ID = 6; - private BitSet __isset_bit_vector = new BitSet(7); + private static final int __LIMIT_ISSET_ID = 1; + private static final int __START_TIME_ISSET_ID = 2; + private static final int __END_TIME_ISSET_ID = 3; + private static final int __ONLY_LATEST_VERSION_ISSET_ID = 4; + private static final int __ENABLE_READ_FROM_FOLLOWER_ISSET_ID = 5; + private BitSet __isset_bit_vector = new BitSet(6); public static final Map metaDataMap; @@ -77,12 +73,13 @@ public class ScanVertexRequest implements TBase, java.io.Serializable, Cloneable Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(CURSOR, new FieldMetaData("cursor", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, ScanCursor.class)))); tmpMetaDataMap.put(RETURN_COLUMNS, new FieldMetaData("return_columns", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, VertexProp.class))); + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, VertexProp.class)))); tmpMetaDataMap.put(LIMIT, new FieldMetaData("limit", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(START_TIME, new FieldMetaData("start_time", TFieldRequirementType.OPTIONAL, @@ -113,16 +110,15 @@ public ScanVertexRequest() { public ScanVertexRequest( int space_id, - int part_id, - VertexProp return_columns, + Map parts, + List return_columns, long limit, boolean only_latest_version, boolean enable_read_from_follower) { this(); this.space_id = space_id; setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); + this.parts = parts; this.return_columns = return_columns; this.limit = limit; setLimitIsSet(true); @@ -134,9 +130,8 @@ public ScanVertexRequest( public ScanVertexRequest( int space_id, - int part_id, - byte[] cursor, - VertexProp return_columns, + Map parts, + List return_columns, long limit, long start_time, long end_time, @@ -147,9 +142,7 @@ public ScanVertexRequest( this(); this.space_id = space_id; setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); - this.cursor = cursor; + this.parts = parts; this.return_columns = return_columns; this.limit = limit; setLimitIsSet(true); @@ -167,9 +160,8 @@ public ScanVertexRequest( public static class Builder { private int space_id; - private int part_id; - private byte[] cursor; - private VertexProp return_columns; + private Map parts; + private List return_columns; private long limit; private long start_time; private long end_time; @@ -178,7 +170,7 @@ public static class Builder { private boolean enable_read_from_follower; private RequestCommon common; - BitSet __optional_isset = new BitSet(7); + BitSet __optional_isset = new BitSet(6); public Builder() { } @@ -189,18 +181,12 @@ public Builder setSpace_id(final int space_id) { return this; } - public Builder setPart_id(final int part_id) { - this.part_id = part_id; - __optional_isset.set(__PART_ID_ISSET_ID, true); - return this; - } - - public Builder setCursor(final byte[] cursor) { - this.cursor = cursor; + public Builder setParts(final Map parts) { + this.parts = parts; return this; } - public Builder setReturn_columns(final VertexProp return_columns) { + public Builder setReturn_columns(final List return_columns) { this.return_columns = return_columns; return this; } @@ -250,10 +236,7 @@ public ScanVertexRequest build() { if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { result.setSpace_id(this.space_id); } - if (__optional_isset.get(__PART_ID_ISSET_ID)) { - result.setPart_id(this.part_id); - } - result.setCursor(this.cursor); + result.setParts(this.parts); result.setReturn_columns(this.return_columns); if (__optional_isset.get(__LIMIT_ISSET_ID)) { result.setLimit(this.limit); @@ -287,9 +270,8 @@ public ScanVertexRequest(ScanVertexRequest other) { __isset_bit_vector.clear(); __isset_bit_vector.or(other.__isset_bit_vector); this.space_id = TBaseHelper.deepCopy(other.space_id); - this.part_id = TBaseHelper.deepCopy(other.part_id); - if (other.isSetCursor()) { - this.cursor = TBaseHelper.deepCopy(other.cursor); + if (other.isSetParts()) { + this.parts = TBaseHelper.deepCopy(other.parts); } if (other.isSetReturn_columns()) { this.return_columns = TBaseHelper.deepCopy(other.return_columns); @@ -334,58 +316,35 @@ public void setSpace_idIsSet(boolean __value) { __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); } - public int getPart_id() { - return this.part_id; + public Map getParts() { + return this.parts; } - public ScanVertexRequest setPart_id(int part_id) { - this.part_id = part_id; - setPart_idIsSet(true); + public ScanVertexRequest setParts(Map parts) { + this.parts = parts; return this; } - public void unsetPart_id() { - __isset_bit_vector.clear(__PART_ID_ISSET_ID); - } - - // Returns true if field part_id is set (has been assigned a value) and false otherwise - public boolean isSetPart_id() { - return __isset_bit_vector.get(__PART_ID_ISSET_ID); - } - - public void setPart_idIsSet(boolean __value) { - __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); - } - - public byte[] getCursor() { - return this.cursor; - } - - public ScanVertexRequest setCursor(byte[] cursor) { - this.cursor = cursor; - return this; + public void unsetParts() { + this.parts = null; } - public void unsetCursor() { - this.cursor = null; + // Returns true if field parts is set (has been assigned a value) and false otherwise + public boolean isSetParts() { + return this.parts != null; } - // Returns true if field cursor is set (has been assigned a value) and false otherwise - public boolean isSetCursor() { - return this.cursor != null; - } - - public void setCursorIsSet(boolean __value) { + public void setPartsIsSet(boolean __value) { if (!__value) { - this.cursor = null; + this.parts = null; } } - public VertexProp getReturn_columns() { + public List getReturn_columns() { return this.return_columns; } - public ScanVertexRequest setReturn_columns(VertexProp return_columns) { + public ScanVertexRequest setReturn_columns(List return_columns) { this.return_columns = return_columns; return this; } @@ -568,6 +527,7 @@ public void setCommonIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SPACE_ID: @@ -578,19 +538,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case PART_ID: - if (__value == null) { - unsetPart_id(); - } else { - setPart_id((Integer)__value); - } - break; - - case CURSOR: + case PARTS: if (__value == null) { - unsetCursor(); + unsetParts(); } else { - setCursor((byte[])__value); + setParts((Map)__value); } break; @@ -598,7 +550,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReturn_columns(); } else { - setReturn_columns((VertexProp)__value); + setReturn_columns((List)__value); } break; @@ -668,11 +620,8 @@ public Object getFieldValue(int fieldID) { case SPACE_ID: return new Integer(getSpace_id()); - case PART_ID: - return new Integer(getPart_id()); - - case CURSOR: - return getCursor(); + case PARTS: + return getParts(); case RETURN_COLUMNS: return getReturn_columns(); @@ -715,9 +664,7 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } - if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetCursor(), that.isSetCursor(), this.cursor, that.cursor)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetReturn_columns(), that.isSetReturn_columns(), this.return_columns, that.return_columns)) { return false; } @@ -740,7 +687,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, part_id, cursor, return_columns, limit, start_time, end_time, filter, only_latest_version, enable_read_from_follower, common}); + return Arrays.deepHashCode(new Object[] {space_id, parts, return_columns, limit, start_time, end_time, filter, only_latest_version, enable_read_from_follower, common}); } @Override @@ -763,19 +710,11 @@ public int compareTo(ScanVertexRequest other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(part_id, other.part_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetCursor()).compareTo(other.isSetCursor()); + lastComparison = Boolean.valueOf(isSetParts()).compareTo(other.isSetParts()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(cursor, other.cursor); + lastComparison = TBaseHelper.compareTo(parts, other.parts); if (lastComparison != 0) { return lastComparison; } @@ -865,25 +804,44 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case PART_ID: - if (__field.type == TType.I32) { - this.part_id = iprot.readI32(); - setPart_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CURSOR: - if (__field.type == TType.STRING) { - this.cursor = iprot.readBinary(); + case PARTS: + if (__field.type == TType.MAP) { + { + TMap _map189 = iprot.readMapBegin(); + this.parts = new HashMap(Math.max(0, 2*_map189.size)); + for (int _i190 = 0; + (_map189.size < 0) ? iprot.peekMap() : (_i190 < _map189.size); + ++_i190) + { + int _key191; + ScanCursor _val192; + _key191 = iprot.readI32(); + _val192 = new ScanCursor(); + _val192.read(iprot); + this.parts.put(_key191, _val192); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } break; case RETURN_COLUMNS: - if (__field.type == TType.STRUCT) { - this.return_columns = new VertexProp(); - this.return_columns.read(iprot); + if (__field.type == TType.LIST) { + { + TList _list193 = iprot.readListBegin(); + this.return_columns = new ArrayList(Math.max(0, _list193.size)); + for (int _i194 = 0; + (_list193.size < 0) ? iprot.peekList() : (_i194 < _list193.size); + ++_i194) + { + VertexProp _elem195; + _elem195 = new VertexProp(); + _elem195.read(iprot); + this.return_columns.add(_elem195); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -963,19 +921,27 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); oprot.writeI32(this.space_id); oprot.writeFieldEnd(); - oprot.writeFieldBegin(PART_ID_FIELD_DESC); - oprot.writeI32(this.part_id); - oprot.writeFieldEnd(); - if (this.cursor != null) { - if (isSetCursor()) { - oprot.writeFieldBegin(CURSOR_FIELD_DESC); - oprot.writeBinary(this.cursor); - oprot.writeFieldEnd(); + if (this.parts != null) { + oprot.writeFieldBegin(PARTS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.parts.size())); + for (Map.Entry _iter196 : this.parts.entrySet()) { + oprot.writeI32(_iter196.getKey()); + _iter196.getValue().write(oprot); + } + oprot.writeMapEnd(); } + oprot.writeFieldEnd(); } if (this.return_columns != null) { oprot.writeFieldBegin(RETURN_COLUMNS_FIELD_DESC); - this.return_columns.write(oprot); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.return_columns.size())); + for (VertexProp _iter197 : this.return_columns) { + _iter197.write(oprot); + } + oprot.writeListEnd(); + } oprot.writeFieldEnd(); } oprot.writeFieldBegin(LIMIT_FIELD_DESC); @@ -1039,30 +1005,15 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("part_id"); + sb.append("parts"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); - first = false; - if (isSetCursor()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("cursor"); - sb.append(space); - sb.append(":").append(space); - if (this.getCursor() == null) { - sb.append("null"); - } else { - int __cursor_size = Math.min(this.getCursor().length, 128); - for (int i = 0; i < __cursor_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getCursor()[i]).length() > 1 ? Integer.toHexString(this.getCursor()[i]).substring(Integer.toHexString(this.getCursor()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getCursor()[i]).toUpperCase()); - } - if (this.getCursor().length > 128) sb.append(" ..."); - } - first = false; + if (this.getParts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParts(), indent + 1, prettyPrint)); } + first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); sb.append("return_columns"); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java index 5f1713209..377ff3c26 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java @@ -28,21 +28,16 @@ public class ScanVertexResponse implements TBase, java.io.Serializable, Cloneabl private static final TStruct STRUCT_DESC = new TStruct("ScanVertexResponse"); private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); private static final TField VERTEX_DATA_FIELD_DESC = new TField("vertex_data", TType.STRUCT, (short)2); - private static final TField HAS_NEXT_FIELD_DESC = new TField("has_next", TType.BOOL, (short)3); - private static final TField NEXT_CURSOR_FIELD_DESC = new TField("next_cursor", TType.STRING, (short)4); + private static final TField CURSORS_FIELD_DESC = new TField("cursors", TType.MAP, (short)3); public ResponseCommon result; public com.vesoft.nebula.DataSet vertex_data; - public boolean has_next; - public byte[] next_cursor; + public Map cursors; public static final int RESULT = 1; public static final int VERTEX_DATA = 2; - public static final int HAS_NEXT = 3; - public static final int NEXT_CURSOR = 4; + public static final int CURSORS = 3; // isset id assignments - private static final int __HAS_NEXT_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; @@ -52,10 +47,10 @@ public class ScanVertexResponse implements TBase, java.io.Serializable, Cloneabl new StructMetaData(TType.STRUCT, ResponseCommon.class))); tmpMetaDataMap.put(VERTEX_DATA, new FieldMetaData("vertex_data", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); - tmpMetaDataMap.put(HAS_NEXT, new FieldMetaData("has_next", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.BOOL))); - tmpMetaDataMap.put(NEXT_CURSOR, new FieldMetaData("next_cursor", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(CURSORS, new FieldMetaData("cursors", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, ScanCursor.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -75,34 +70,17 @@ public ScanVertexResponse( public ScanVertexResponse( ResponseCommon result, com.vesoft.nebula.DataSet vertex_data, - boolean has_next) { + Map cursors) { this(); this.result = result; this.vertex_data = vertex_data; - this.has_next = has_next; - setHas_nextIsSet(true); - } - - public ScanVertexResponse( - ResponseCommon result, - com.vesoft.nebula.DataSet vertex_data, - boolean has_next, - byte[] next_cursor) { - this(); - this.result = result; - this.vertex_data = vertex_data; - this.has_next = has_next; - setHas_nextIsSet(true); - this.next_cursor = next_cursor; + this.cursors = cursors; } public static class Builder { private ResponseCommon result; private com.vesoft.nebula.DataSet vertex_data; - private boolean has_next; - private byte[] next_cursor; - - BitSet __optional_isset = new BitSet(1); + private Map cursors; public Builder() { } @@ -117,14 +95,8 @@ public Builder setVertex_data(final com.vesoft.nebula.DataSet vertex_data) { return this; } - public Builder setHas_next(final boolean has_next) { - this.has_next = has_next; - __optional_isset.set(__HAS_NEXT_ISSET_ID, true); - return this; - } - - public Builder setNext_cursor(final byte[] next_cursor) { - this.next_cursor = next_cursor; + public Builder setCursors(final Map cursors) { + this.cursors = cursors; return this; } @@ -132,10 +104,7 @@ public ScanVertexResponse build() { ScanVertexResponse result = new ScanVertexResponse(); result.setResult(this.result); result.setVertex_data(this.vertex_data); - if (__optional_isset.get(__HAS_NEXT_ISSET_ID)) { - result.setHas_next(this.has_next); - } - result.setNext_cursor(this.next_cursor); + result.setCursors(this.cursors); return result; } } @@ -148,17 +117,14 @@ public static Builder builder() { * Performs a deep copy on other. */ public ScanVertexResponse(ScanVertexResponse other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); if (other.isSetResult()) { this.result = TBaseHelper.deepCopy(other.result); } if (other.isSetVertex_data()) { this.vertex_data = TBaseHelper.deepCopy(other.vertex_data); } - this.has_next = TBaseHelper.deepCopy(other.has_next); - if (other.isSetNext_cursor()) { - this.next_cursor = TBaseHelper.deepCopy(other.next_cursor); + if (other.isSetCursors()) { + this.cursors = TBaseHelper.deepCopy(other.cursors); } } @@ -214,53 +180,31 @@ public void setVertex_dataIsSet(boolean __value) { } } - public boolean isHas_next() { - return this.has_next; + public Map getCursors() { + return this.cursors; } - public ScanVertexResponse setHas_next(boolean has_next) { - this.has_next = has_next; - setHas_nextIsSet(true); + public ScanVertexResponse setCursors(Map cursors) { + this.cursors = cursors; return this; } - public void unsetHas_next() { - __isset_bit_vector.clear(__HAS_NEXT_ISSET_ID); - } - - // Returns true if field has_next is set (has been assigned a value) and false otherwise - public boolean isSetHas_next() { - return __isset_bit_vector.get(__HAS_NEXT_ISSET_ID); + public void unsetCursors() { + this.cursors = null; } - public void setHas_nextIsSet(boolean __value) { - __isset_bit_vector.set(__HAS_NEXT_ISSET_ID, __value); + // Returns true if field cursors is set (has been assigned a value) and false otherwise + public boolean isSetCursors() { + return this.cursors != null; } - public byte[] getNext_cursor() { - return this.next_cursor; - } - - public ScanVertexResponse setNext_cursor(byte[] next_cursor) { - this.next_cursor = next_cursor; - return this; - } - - public void unsetNext_cursor() { - this.next_cursor = null; - } - - // Returns true if field next_cursor is set (has been assigned a value) and false otherwise - public boolean isSetNext_cursor() { - return this.next_cursor != null; - } - - public void setNext_cursorIsSet(boolean __value) { + public void setCursorsIsSet(boolean __value) { if (!__value) { - this.next_cursor = null; + this.cursors = null; } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case RESULT: @@ -279,19 +223,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case HAS_NEXT: - if (__value == null) { - unsetHas_next(); - } else { - setHas_next((Boolean)__value); - } - break; - - case NEXT_CURSOR: + case CURSORS: if (__value == null) { - unsetNext_cursor(); + unsetCursors(); } else { - setNext_cursor((byte[])__value); + setCursors((Map)__value); } break; @@ -308,11 +244,8 @@ public Object getFieldValue(int fieldID) { case VERTEX_DATA: return getVertex_data(); - case HAS_NEXT: - return new Boolean(isHas_next()); - - case NEXT_CURSOR: - return getNext_cursor(); + case CURSORS: + return getCursors(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -333,16 +266,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetVertex_data(), that.isSetVertex_data(), this.vertex_data, that.vertex_data)) { return false; } - if (!TBaseHelper.equalsNobinary(this.has_next, that.has_next)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetNext_cursor(), that.isSetNext_cursor(), this.next_cursor, that.next_cursor)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetCursors(), that.isSetCursors(), this.cursors, that.cursors)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, vertex_data, has_next, next_cursor}); + return Arrays.deepHashCode(new Object[] {result, vertex_data, cursors}); } public void read(TProtocol iprot) throws TException { @@ -372,17 +303,24 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case HAS_NEXT: - if (__field.type == TType.BOOL) { - this.has_next = iprot.readBool(); - setHas_nextIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case NEXT_CURSOR: - if (__field.type == TType.STRING) { - this.next_cursor = iprot.readBinary(); + case CURSORS: + if (__field.type == TType.MAP) { + { + TMap _map198 = iprot.readMapBegin(); + this.cursors = new HashMap(Math.max(0, 2*_map198.size)); + for (int _i199 = 0; + (_map198.size < 0) ? iprot.peekMap() : (_i199 < _map198.size); + ++_i199) + { + int _key200; + ScanCursor _val201; + _key200 = iprot.readI32(); + _val201 = new ScanCursor(); + _val201.read(iprot); + this.cursors.put(_key200, _val201); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -414,15 +352,17 @@ public void write(TProtocol oprot) throws TException { this.vertex_data.write(oprot); oprot.writeFieldEnd(); } - oprot.writeFieldBegin(HAS_NEXT_FIELD_DESC); - oprot.writeBool(this.has_next); - oprot.writeFieldEnd(); - if (this.next_cursor != null) { - if (isSetNext_cursor()) { - oprot.writeFieldBegin(NEXT_CURSOR_FIELD_DESC); - oprot.writeBinary(this.next_cursor); - oprot.writeFieldEnd(); + if (this.cursors != null) { + oprot.writeFieldBegin(CURSORS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.cursors.size())); + for (Map.Entry _iter202 : this.cursors.entrySet()) { + oprot.writeI32(_iter202.getKey()); + _iter202.getValue().write(oprot); + } + oprot.writeMapEnd(); } + oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); @@ -467,30 +407,15 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("has_next"); + sb.append("cursors"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isHas_next(), indent + 1, prettyPrint)); - first = false; - if (isSetNext_cursor()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("next_cursor"); - sb.append(space); - sb.append(":").append(space); - if (this.getNext_cursor() == null) { - sb.append("null"); - } else { - int __next_cursor_size = Math.min(this.getNext_cursor().length, 128); - for (int i = 0; i < __next_cursor_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getNext_cursor()[i]).length() > 1 ? Integer.toHexString(this.getNext_cursor()[i]).substring(Integer.toHexString(this.getNext_cursor()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getNext_cursor()[i]).toUpperCase()); - } - if (this.getNext_cursor().length > 128) sb.append(" ..."); - } - first = false; + if (this.getCursors() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCursors(), indent + 1, prettyPrint)); } + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java index 04627c6a4..026a16de0 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java @@ -868,17 +868,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler400) throws TException { + public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler424) throws TException { checkReady(); - transLeader_call method_call = new transLeader_call(req, resultHandler400, this, ___protocolFactory, ___transport); + transLeader_call method_call = new transLeader_call(req, resultHandler424, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class transLeader_call extends TAsyncMethodCall { private TransLeaderReq req; - public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler401, TAsyncClient client397, TProtocolFactory protocolFactory398, TNonblockingTransport transport399) throws TException { - super(client397, protocolFactory398, transport399, resultHandler401, false); + public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler425, TAsyncClient client421, TProtocolFactory protocolFactory422, TNonblockingTransport transport423) throws TException { + super(client421, protocolFactory422, transport423, resultHandler425, false); this.req = req; } @@ -900,17 +900,17 @@ public AdminExecResp getResult() throws TException { } } - public void addPart(AddPartReq req, AsyncMethodCallback resultHandler405) throws TException { + public void addPart(AddPartReq req, AsyncMethodCallback resultHandler429) throws TException { checkReady(); - addPart_call method_call = new addPart_call(req, resultHandler405, this, ___protocolFactory, ___transport); + addPart_call method_call = new addPart_call(req, resultHandler429, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addPart_call extends TAsyncMethodCall { private AddPartReq req; - public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler406, TAsyncClient client402, TProtocolFactory protocolFactory403, TNonblockingTransport transport404) throws TException { - super(client402, protocolFactory403, transport404, resultHandler406, false); + public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler430, TAsyncClient client426, TProtocolFactory protocolFactory427, TNonblockingTransport transport428) throws TException { + super(client426, protocolFactory427, transport428, resultHandler430, false); this.req = req; } @@ -932,17 +932,17 @@ public AdminExecResp getResult() throws TException { } } - public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler410) throws TException { + public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler434) throws TException { checkReady(); - addLearner_call method_call = new addLearner_call(req, resultHandler410, this, ___protocolFactory, ___transport); + addLearner_call method_call = new addLearner_call(req, resultHandler434, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addLearner_call extends TAsyncMethodCall { private AddLearnerReq req; - public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler411, TAsyncClient client407, TProtocolFactory protocolFactory408, TNonblockingTransport transport409) throws TException { - super(client407, protocolFactory408, transport409, resultHandler411, false); + public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler435, TAsyncClient client431, TProtocolFactory protocolFactory432, TNonblockingTransport transport433) throws TException { + super(client431, protocolFactory432, transport433, resultHandler435, false); this.req = req; } @@ -964,17 +964,17 @@ public AdminExecResp getResult() throws TException { } } - public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler415) throws TException { + public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler439) throws TException { checkReady(); - removePart_call method_call = new removePart_call(req, resultHandler415, this, ___protocolFactory, ___transport); + removePart_call method_call = new removePart_call(req, resultHandler439, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removePart_call extends TAsyncMethodCall { private RemovePartReq req; - public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler416, TAsyncClient client412, TProtocolFactory protocolFactory413, TNonblockingTransport transport414) throws TException { - super(client412, protocolFactory413, transport414, resultHandler416, false); + public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler440, TAsyncClient client436, TProtocolFactory protocolFactory437, TNonblockingTransport transport438) throws TException { + super(client436, protocolFactory437, transport438, resultHandler440, false); this.req = req; } @@ -996,17 +996,17 @@ public AdminExecResp getResult() throws TException { } } - public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler420) throws TException { + public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler444) throws TException { checkReady(); - memberChange_call method_call = new memberChange_call(req, resultHandler420, this, ___protocolFactory, ___transport); + memberChange_call method_call = new memberChange_call(req, resultHandler444, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class memberChange_call extends TAsyncMethodCall { private MemberChangeReq req; - public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler421, TAsyncClient client417, TProtocolFactory protocolFactory418, TNonblockingTransport transport419) throws TException { - super(client417, protocolFactory418, transport419, resultHandler421, false); + public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler445, TAsyncClient client441, TProtocolFactory protocolFactory442, TNonblockingTransport transport443) throws TException { + super(client441, protocolFactory442, transport443, resultHandler445, false); this.req = req; } @@ -1028,17 +1028,17 @@ public AdminExecResp getResult() throws TException { } } - public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler425) throws TException { + public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler449) throws TException { checkReady(); - waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler425, this, ___protocolFactory, ___transport); + waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler449, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class waitingForCatchUpData_call extends TAsyncMethodCall { private CatchUpDataReq req; - public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler426, TAsyncClient client422, TProtocolFactory protocolFactory423, TNonblockingTransport transport424) throws TException { - super(client422, protocolFactory423, transport424, resultHandler426, false); + public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler450, TAsyncClient client446, TProtocolFactory protocolFactory447, TNonblockingTransport transport448) throws TException { + super(client446, protocolFactory447, transport448, resultHandler450, false); this.req = req; } @@ -1060,17 +1060,17 @@ public AdminExecResp getResult() throws TException { } } - public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler430) throws TException { + public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler454) throws TException { checkReady(); - createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler430, this, ___protocolFactory, ___transport); + createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler454, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createCheckpoint_call extends TAsyncMethodCall { private CreateCPRequest req; - public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler431, TAsyncClient client427, TProtocolFactory protocolFactory428, TNonblockingTransport transport429) throws TException { - super(client427, protocolFactory428, transport429, resultHandler431, false); + public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler455, TAsyncClient client451, TProtocolFactory protocolFactory452, TNonblockingTransport transport453) throws TException { + super(client451, protocolFactory452, transport453, resultHandler455, false); this.req = req; } @@ -1092,17 +1092,17 @@ public CreateCPResp getResult() throws TException { } } - public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler435) throws TException { + public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler459) throws TException { checkReady(); - dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler435, this, ___protocolFactory, ___transport); + dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler459, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropCheckpoint_call extends TAsyncMethodCall { private DropCPRequest req; - public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler436, TAsyncClient client432, TProtocolFactory protocolFactory433, TNonblockingTransport transport434) throws TException { - super(client432, protocolFactory433, transport434, resultHandler436, false); + public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler460, TAsyncClient client456, TProtocolFactory protocolFactory457, TNonblockingTransport transport458) throws TException { + super(client456, protocolFactory457, transport458, resultHandler460, false); this.req = req; } @@ -1124,17 +1124,17 @@ public AdminExecResp getResult() throws TException { } } - public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler440) throws TException { + public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler464) throws TException { checkReady(); - blockingWrites_call method_call = new blockingWrites_call(req, resultHandler440, this, ___protocolFactory, ___transport); + blockingWrites_call method_call = new blockingWrites_call(req, resultHandler464, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class blockingWrites_call extends TAsyncMethodCall { private BlockingSignRequest req; - public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler441, TAsyncClient client437, TProtocolFactory protocolFactory438, TNonblockingTransport transport439) throws TException { - super(client437, protocolFactory438, transport439, resultHandler441, false); + public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler465, TAsyncClient client461, TProtocolFactory protocolFactory462, TNonblockingTransport transport463) throws TException { + super(client461, protocolFactory462, transport463, resultHandler465, false); this.req = req; } @@ -1156,17 +1156,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler445) throws TException { + public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler469) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler445, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler469, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler446, TAsyncClient client442, TProtocolFactory protocolFactory443, TNonblockingTransport transport444) throws TException { - super(client442, protocolFactory443, transport444, resultHandler446, false); + public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler470, TAsyncClient client466, TProtocolFactory protocolFactory467, TNonblockingTransport transport468) throws TException { + super(client466, protocolFactory467, transport468, resultHandler470, false); this.req = req; } @@ -1188,17 +1188,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler450) throws TException { + public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler474) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler450, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler474, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler451, TAsyncClient client447, TProtocolFactory protocolFactory448, TNonblockingTransport transport449) throws TException { - super(client447, protocolFactory448, transport449, resultHandler451, false); + public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler475, TAsyncClient client471, TProtocolFactory protocolFactory472, TNonblockingTransport transport473) throws TException { + super(client471, protocolFactory472, transport473, resultHandler475, false); this.req = req; } @@ -1220,17 +1220,17 @@ public AdminExecResp getResult() throws TException { } } - public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler455) throws TException { + public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler479) throws TException { checkReady(); - getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler455, this, ___protocolFactory, ___transport); + getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler479, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getLeaderParts_call extends TAsyncMethodCall { private GetLeaderReq req; - public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler456, TAsyncClient client452, TProtocolFactory protocolFactory453, TNonblockingTransport transport454) throws TException { - super(client452, protocolFactory453, transport454, resultHandler456, false); + public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler480, TAsyncClient client476, TProtocolFactory protocolFactory477, TNonblockingTransport transport478) throws TException { + super(client476, protocolFactory477, transport478, resultHandler480, false); this.req = req; } @@ -1252,17 +1252,17 @@ public GetLeaderPartsResp getResult() throws TException { } } - public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler460) throws TException { + public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler484) throws TException { checkReady(); - checkPeers_call method_call = new checkPeers_call(req, resultHandler460, this, ___protocolFactory, ___transport); + checkPeers_call method_call = new checkPeers_call(req, resultHandler484, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class checkPeers_call extends TAsyncMethodCall { private CheckPeersReq req; - public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler461, TAsyncClient client457, TProtocolFactory protocolFactory458, TNonblockingTransport transport459) throws TException { - super(client457, protocolFactory458, transport459, resultHandler461, false); + public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler485, TAsyncClient client481, TProtocolFactory protocolFactory482, TNonblockingTransport transport483) throws TException { + super(client481, protocolFactory482, transport483, resultHandler485, false); this.req = req; } @@ -1284,17 +1284,17 @@ public AdminExecResp getResult() throws TException { } } - public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler465) throws TException { + public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler489) throws TException { checkReady(); - addAdminTask_call method_call = new addAdminTask_call(req, resultHandler465, this, ___protocolFactory, ___transport); + addAdminTask_call method_call = new addAdminTask_call(req, resultHandler489, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addAdminTask_call extends TAsyncMethodCall { private AddAdminTaskRequest req; - public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler466, TAsyncClient client462, TProtocolFactory protocolFactory463, TNonblockingTransport transport464) throws TException { - super(client462, protocolFactory463, transport464, resultHandler466, false); + public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler490, TAsyncClient client486, TProtocolFactory protocolFactory487, TNonblockingTransport transport488) throws TException { + super(client486, protocolFactory487, transport488, resultHandler490, false); this.req = req; } @@ -1316,17 +1316,17 @@ public AdminExecResp getResult() throws TException { } } - public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler470) throws TException { + public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler494) throws TException { checkReady(); - stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler470, this, ___protocolFactory, ___transport); + stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler494, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class stopAdminTask_call extends TAsyncMethodCall { private StopAdminTaskRequest req; - public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler471, TAsyncClient client467, TProtocolFactory protocolFactory468, TNonblockingTransport transport469) throws TException { - super(client467, protocolFactory468, transport469, resultHandler471, false); + public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler495, TAsyncClient client491, TProtocolFactory protocolFactory492, TNonblockingTransport transport493) throws TException { + super(client491, protocolFactory492, transport493, resultHandler495, false); this.req = req; } @@ -1348,17 +1348,17 @@ public AdminExecResp getResult() throws TException { } } - public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler475) throws TException { + public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler499) throws TException { checkReady(); - listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler475, this, ___protocolFactory, ___transport); + listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler499, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listClusterInfo_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler476, TAsyncClient client472, TProtocolFactory protocolFactory473, TNonblockingTransport transport474) throws TException { - super(client472, protocolFactory473, transport474, resultHandler476, false); + public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler500, TAsyncClient client496, TProtocolFactory protocolFactory497, TNonblockingTransport transport498) throws TException { + super(client496, protocolFactory497, transport498, resultHandler500, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java b/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java index e7366d6bd..7ba6a574d 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java @@ -345,15 +345,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list189 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list189.size)); - for (int _i190 = 0; - (_list189.size < 0) ? iprot.peekList() : (_i190 < _list189.size); - ++_i190) + TList _list213 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list213.size)); + for (int _i214 = 0; + (_list213.size < 0) ? iprot.peekList() : (_i214 < _list213.size); + ++_i214) { - int _elem191; - _elem191 = iprot.readI32(); - this.parts.add(_elem191); + int _elem215; + _elem215 = iprot.readI32(); + this.parts.add(_elem215); } iprot.readListEnd(); } @@ -364,15 +364,15 @@ public void read(TProtocol iprot) throws TException { case TASK_SPECFIC_PARAS: if (__field.type == TType.LIST) { { - TList _list192 = iprot.readListBegin(); - this.task_specfic_paras = new ArrayList(Math.max(0, _list192.size)); - for (int _i193 = 0; - (_list192.size < 0) ? iprot.peekList() : (_i193 < _list192.size); - ++_i193) + TList _list216 = iprot.readListBegin(); + this.task_specfic_paras = new ArrayList(Math.max(0, _list216.size)); + for (int _i217 = 0; + (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); + ++_i217) { - byte[] _elem194; - _elem194 = iprot.readBinary(); - this.task_specfic_paras.add(_elem194); + byte[] _elem218; + _elem218 = iprot.readBinary(); + this.task_specfic_paras.add(_elem218); } iprot.readListEnd(); } @@ -405,8 +405,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter195 : this.parts) { - oprot.writeI32(_iter195); + for (int _iter219 : this.parts) { + oprot.writeI32(_iter219); } oprot.writeListEnd(); } @@ -418,8 +418,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TASK_SPECFIC_PARAS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.task_specfic_paras.size())); - for (byte[] _iter196 : this.task_specfic_paras) { - oprot.writeBinary(_iter196); + for (byte[] _iter220 : this.task_specfic_paras) { + oprot.writeBinary(_iter220); } oprot.writeListEnd(); } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java index f66bb05e7..d4444f6f1 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java @@ -574,11 +574,11 @@ private ScanVertexResultIterator scanVertex(String spaceName, } } VertexProp vertexCols = new VertexProp((int) tag, props); - + List vertexProps = Arrays.asList(vertexCols); ScanVertexRequest request = new ScanVertexRequest(); request .setSpace_id(getSpaceId(spaceName)) - .setReturn_columns(vertexCols) + .setReturn_columns(vertexProps) .setLimit(limit) .setStart_time(startTime) .setEnd_time(endTime) diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java index e72f3b40d..4d6f5f7d8 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java @@ -6,6 +6,7 @@ package com.vesoft.nebula.client.storage.scan; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.storage.ScanCursor; import java.io.Serializable; public class PartScanInfo implements Serializable { @@ -14,7 +15,7 @@ public class PartScanInfo implements Serializable { private int part; private HostAddress leader; - private byte[] cursor = null; + private ScanCursor cursor = null; public PartScanInfo(int part, HostAddress leader) { this.part = part; @@ -37,11 +38,11 @@ public void setLeader(HostAddress leader) { this.leader = leader; } - public byte[] getCursor() { + public ScanCursor getCursor() { return cursor; } - public void setCursor(byte[] cursor) { + public void setCursor(ScanCursor cursor) { this.cursor = cursor; } @@ -50,7 +51,7 @@ public String toString() { return "PartScanInfo{" + "part=" + part + ", leader=" + leader - + ", cursor=" + new String(cursor) + + ", cursor=" + new String(cursor.next_cursor) + '}'; } } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java index 2fd926391..7c6d5c935 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java @@ -14,11 +14,14 @@ import com.vesoft.nebula.client.storage.StorageConnPool; import com.vesoft.nebula.client.storage.data.ScanStatus; import com.vesoft.nebula.storage.PartitionResult; +import com.vesoft.nebula.storage.ScanCursor; import com.vesoft.nebula.storage.ScanEdgeRequest; import com.vesoft.nebula.storage.ScanEdgeResponse; import java.util.ArrayList; import java.util.Collections; +import java.util.HashMap; import java.util.List; +import java.util.Map; import java.util.Set; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ExecutorService; @@ -70,7 +73,6 @@ public ScanEdgeResult next() throws Exception { threadPool = Executors.newFixedThreadPool(addresses.size()); for (HostAddress addr : addresses) { threadPool.submit(() -> { - ScanEdgeRequest partRequest = new ScanEdgeRequest(request); ScanEdgeResponse response; PartScanInfo partInfo = partScanQueue.getPart(addr); // no part need to scan @@ -91,8 +93,10 @@ public ScanEdgeResult next() throws Exception { return; } - partRequest.setPart_id(partInfo.getPart()); - partRequest.setCursor(partInfo.getCursor()); + Map cursorMap = new HashMap<>(); + cursorMap.put(partInfo.getPart(), partInfo.getCursor()); + ScanEdgeRequest partRequest = new ScanEdgeRequest(request); + partRequest.setParts(cursorMap); try { response = connection.scanEdge(partRequest); } catch (TException e) { @@ -162,10 +166,10 @@ private boolean isSuccessful(ScanEdgeResponse response) { private void handleSucceedResult(AtomicInteger existSuccess, ScanEdgeResponse response, PartScanInfo partInfo) { existSuccess.addAndGet(1); - if (!response.has_next) { + if (!response.getCursors().get(partInfo.getPart()).has_next) { partScanQueue.dropPart(partInfo); } else { - partInfo.setCursor(response.getNext_cursor()); + partInfo.setCursor(response.getCursors().get(partInfo.getPart())); } } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java index 7271a526f..1444b1785 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java @@ -14,11 +14,14 @@ import com.vesoft.nebula.client.storage.StorageConnPool; import com.vesoft.nebula.client.storage.data.ScanStatus; import com.vesoft.nebula.storage.PartitionResult; +import com.vesoft.nebula.storage.ScanCursor; import com.vesoft.nebula.storage.ScanVertexRequest; import com.vesoft.nebula.storage.ScanVertexResponse; import java.util.ArrayList; import java.util.Collections; +import java.util.HashMap; import java.util.List; +import java.util.Map; import java.util.Set; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ExecutorService; @@ -73,7 +76,6 @@ public ScanVertexResult next() throws Exception { for (HostAddress addr : addresses) { threadPool.submit(() -> { - ScanVertexRequest partRequest = new ScanVertexRequest(request); ScanVertexResponse response; PartScanInfo partInfo = partScanQueue.getPart(addr); // no part need to scan @@ -93,8 +95,10 @@ public ScanVertexResult next() throws Exception { return; } - partRequest.setPart_id(partInfo.getPart()); - partRequest.setCursor(partInfo.getCursor()); + Map cursorMap = new HashMap<>(); + cursorMap.put(partInfo.getPart(), partInfo.getCursor()); + ScanVertexRequest partRequest = new ScanVertexRequest(request); + partRequest.setParts(cursorMap); try { response = connection.scanVertex(partRequest); } catch (TException e) { @@ -163,10 +167,10 @@ private boolean isSuccessful(ScanVertexResponse response) { private void handleSucceedResult(AtomicInteger existSuccess, ScanVertexResponse response, PartScanInfo partInfo) { existSuccess.addAndGet(1); - if (!response.has_next) { + if (!response.getCursors().get(partInfo.getPart()).has_next) { partScanQueue.dropPart(partInfo); } else { - partInfo.setCursor(response.getNext_cursor()); + partInfo.setCursor(response.getCursors().get(partInfo.getPart())); } } diff --git a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java index 65d8e1c6a..c995c1766 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/RowWriterImpl.java @@ -12,9 +12,9 @@ import com.vesoft.nebula.LineString; import com.vesoft.nebula.Point; import com.vesoft.nebula.Polygon; +import com.vesoft.nebula.PropertyType; import com.vesoft.nebula.Time; import com.vesoft.nebula.Value; -import com.vesoft.nebula.meta.PropertyType; import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.util.ArrayList; diff --git a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java index 114b868f5..d3b256d43 100644 --- a/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java +++ b/client/src/main/java/com/vesoft/nebula/encoder/SchemaProviderImpl.java @@ -5,7 +5,7 @@ package com.vesoft.nebula.encoder; -import com.vesoft.nebula.meta.PropertyType; +import com.vesoft.nebula.PropertyType; import java.util.ArrayList; import java.util.HashMap; import java.util.List; diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java index ea303400e..a527daa82 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java @@ -64,6 +64,7 @@ public void testScanVertexWithNoCol() { ScanVertexResultIterator resultIterator = client.scanVertex( "testStorage", "person"); + int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -75,6 +76,7 @@ public void testScanVertexWithNoCol() { if (result.isEmpty()) { continue; } + count += result.getVertices().size(); Assert.assertEquals(1, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (result.isAllSuccess()); @@ -104,6 +106,7 @@ public void testScanVertexWithNoCol() { } } } + assert (count == 5); } @Test @@ -118,6 +121,7 @@ public void testScanVertexWithCols() { "testStorage", "person", Arrays.asList("name", "age")); + int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -129,13 +133,13 @@ public void testScanVertexWithCols() { if (result.isEmpty()) { continue; } + count += result.getVertices().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (result.getPropNames().get(1).equals("name")); assert (result.getPropNames().get(2).equals("age")); assert (result.isAllSuccess()); - List rows = result.getVertices(); for (VertexRow row : rows) { try { @@ -168,6 +172,7 @@ public void testScanVertexWithCols() { assert (Arrays.asList(18L, 20L, 23L, 15L, 25L).contains(tableRow.getLong(2))); } } + assert (count == 5); } @Test @@ -182,6 +187,7 @@ public void testScanVertexWithAllCol() { "testStorage", "person", Arrays.asList()); + int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -193,12 +199,14 @@ public void testScanVertexWithAllCol() { if (result.isEmpty()) { continue; } + count += result.getVertices().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (Arrays.asList("name", "age").contains(result.getPropNames().get(1))); assert (Arrays.asList("name", "age").contains(result.getPropNames().get(2))); assert (result.isAllSuccess()); } + assert (count == 5); } @Test @@ -212,6 +220,7 @@ public void testScanEdgeWithoutCol() { ScanEdgeResultIterator resultIterator = client.scanEdge( "testStorage", "friend"); + int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -223,6 +232,7 @@ public void testScanEdgeWithoutCol() { if (result.isEmpty()) { continue; } + count += result.getEdges().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_src")); assert (result.getPropNames().get(1).equals("_dst")); @@ -260,6 +270,7 @@ public void testScanEdgeWithoutCol() { } } } + assert (count == 5); } @Test @@ -274,6 +285,7 @@ public void testScanEdgeWithCols() { "testStorage", "friend", Arrays.asList("likeness")); + int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -285,6 +297,7 @@ public void testScanEdgeWithCols() { if (result.isEmpty()) { continue; } + count += result.getEdges().size(); Assert.assertEquals(4, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_src")); assert (result.getPropNames().get(1).equals("_dst")); @@ -328,6 +341,7 @@ public void testScanEdgeWithCols() { assert (Arrays.asList(1.0, 2.1, 3.2, 4.5, 5.9).contains(tableRow.getDouble(3))); } } + assert (count == 5); } @Test @@ -342,6 +356,7 @@ public void testScanEdgeWithAllCols() { "testStorage", "friend", Arrays.asList()); + int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -353,6 +368,7 @@ public void testScanEdgeWithAllCols() { if (result.isEmpty()) { continue; } + count += result.getEdges().size(); Assert.assertEquals(4, result.getPropNames().size()); assert (Arrays.asList("_src", "_dst", "_rank", "likeness") .contains(result.getPropNames().get(0))); @@ -364,6 +380,7 @@ public void testScanEdgeWithAllCols() { .contains(result.getPropNames().get(3))); assert (result.isAllSuccess()); } + assert (count == 5); } @Test @@ -387,46 +404,7 @@ public void testCASignedSSL() { ScanVertexResultIterator resultIterator = sslClient.scanVertex( "testStorageCA", "person"); - while (resultIterator.hasNext()) { - ScanVertexResult result = null; - try { - result = resultIterator.next(); - } catch (Exception e) { - e.printStackTrace(); - assert (false); - } - if (result.isEmpty()) { - continue; - } - Assert.assertEquals(1, result.getPropNames().size()); - assert (result.getPropNames().get(0).equals("_vid")); - assert (result.isAllSuccess()); - - List rows = result.getVertices(); - for (VertexRow row : rows) { - try { - assert (Arrays.asList("1", "2", "3", "4", "5") - .contains(row.getVid().asString())); - } catch (UnsupportedEncodingException e) { - e.printStackTrace(); - assert (false); - } - assert (row.getProps().size() == 0); - } - - List tableRows = result.getVertexTableRows(); - for (VertexTableRow tableRow : tableRows) { - try { - assert (Arrays.asList("1", "2", "3", "4", "5") - .contains(tableRow.getVid().asString())); - assert (Arrays.asList("1", "2", "3", "4", "5") - .contains(tableRow.getString(0))); - } catch (UnsupportedEncodingException e) { - e.printStackTrace(); - assert (false); - } - } - } + assertIterator(resultIterator); } catch (Exception e) { e.printStackTrace(); assert (false); @@ -481,6 +459,7 @@ public void testSelfSignedSSL() { } private void assertIterator(ScanVertexResultIterator resultIterator) { + int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -492,6 +471,7 @@ private void assertIterator(ScanVertexResultIterator resultIterator) { if (result.isEmpty()) { continue; } + count += result.getVertices().size(); Assert.assertEquals(1, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (result.isAllSuccess()); @@ -521,5 +501,6 @@ private void assertIterator(ScanVertexResultIterator resultIterator) { } } } + assert (count == 5); } } diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java index 646f4018d..c96faa6d2 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java @@ -6,6 +6,7 @@ package com.vesoft.nebula.client.storage.scan; import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.storage.ScanCursor; import java.util.HashSet; import java.util.Set; import org.junit.Before; @@ -35,7 +36,7 @@ public void testGetPart() { // test cursor HostAddress addr = new HostAddress("127.0.0.1", 3); assert (queue.getPart(addr).getLeader().getPort() == 3); - assert (new String(queue.getPart(addr).getCursor()).equals("cursor")); + assert (new String(queue.getPart(addr).getCursor().next_cursor).equals("cursor")); } @Test @@ -60,7 +61,7 @@ private Set mockPartScanInfo() { partScanInfoSet.add(new PartScanInfo(4, new HostAddress("127.0.0.1", 2))); PartScanInfo partScanInfo = new PartScanInfo(5, new HostAddress("127.0.0.1", 3)); - partScanInfo.setCursor("cursor".getBytes()); + partScanInfo.setCursor(new ScanCursor(true, "cursor".getBytes())); partScanInfoSet.add(partScanInfo); return partScanInfoSet; } diff --git a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java index aec661f4f..f5be0c716 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java @@ -6,13 +6,12 @@ package com.vesoft.nebula.encoder; import com.vesoft.nebula.HostAddr; -import com.vesoft.nebula.client.graph.data.HostAddress; +import com.vesoft.nebula.PropertyType; import com.vesoft.nebula.client.meta.MetaCache; import com.vesoft.nebula.meta.ColumnDef; import com.vesoft.nebula.meta.ColumnTypeDef; import com.vesoft.nebula.meta.EdgeItem; import com.vesoft.nebula.meta.GeoShape; -import com.vesoft.nebula.meta.PropertyType; import com.vesoft.nebula.meta.Schema; import com.vesoft.nebula.meta.SpaceDesc; import com.vesoft.nebula.meta.SpaceItem; diff --git a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java index 0ed452b78..7a0012781 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/TestEncoder.java @@ -3,7 +3,7 @@ * This source code is licensed under Apache 2.0 License. */ -package test.java.com.vesoft.nebula.encoder; +package com.vesoft.nebula.encoder; import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.Date; @@ -14,12 +14,12 @@ import com.vesoft.nebula.NullType; import com.vesoft.nebula.Point; import com.vesoft.nebula.Polygon; +import com.vesoft.nebula.PropertyType; import com.vesoft.nebula.Time; import com.vesoft.nebula.Value; import com.vesoft.nebula.encoder.MetaCacheImplTest; import com.vesoft.nebula.encoder.NebulaCodecImpl; import com.vesoft.nebula.meta.EdgeItem; -import com.vesoft.nebula.meta.PropertyType; import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; import java.util.ArrayList; From 453064dc22161ee47a14b2e30868dc2121eb3a27 Mon Sep 17 00:00:00 2001 From: Anqi Date: Mon, 13 Dec 2021 16:41:35 +0800 Subject: [PATCH 13/25] update thrift & add config for scan cursor (#398) * update thrift * add config for scan cursor * large the sleep time waiting nebula server * update thrift * sync scan with server * large sleep time makesure graph get the latest schema * update result process for scan * update example * update sleep time * update ut --- .github/workflows/deploy_release.yaml | 2 +- .github/workflows/deploy_snapshot.yaml | 2 +- .github/workflows/maven.yml | 2 +- .../src/main/generated/AppendLogRequest.java | 112 +- .../src/main/generated/AskForVoteRequest.java | 90 +- client/src/main/generated/ErrorCode.java | 76 +- .../src/main/generated/GetStateRequest.java | 347 + .../src/main/generated/GetStateResponse.java | 908 +++ client/src/main/generated/RaftexService.java | 570 +- client/src/main/generated/Role.java | 50 + client/src/main/generated/Status.java | 50 + .../com/vesoft/nebula/ErrorCode.java | 2 +- .../generated/com/vesoft/nebula/LogEntry.java | 357 + .../nebula/graph/ExecutionResponse.java | 28 +- .../com/vesoft/nebula/meta/AddGroupReq.java | 20 +- .../vesoft/nebula/meta/AddListenerReq.java | 22 +- .../com/vesoft/nebula/meta/AddZoneReq.java | 22 +- .../com/vesoft/nebula/meta/AdminCmd.java | 3 + .../com/vesoft/nebula/meta/BackupInfo.java | 22 +- .../com/vesoft/nebula/meta/BackupMeta.java | 48 +- .../com/vesoft/nebula/meta/BalanceTask.java | 267 +- .../vesoft/nebula/meta/CreateBackupReq.java | 20 +- .../nebula/meta/CreateEdgeIndexReq.java | 22 +- .../vesoft/nebula/meta/CreateTagIndexReq.java | 22 +- .../com/vesoft/nebula/meta/FTClient.java | 99 +- .../com/vesoft/nebula/meta/FTIndex.java | 20 +- .../com/vesoft/nebula/meta/GetConfigResp.java | 22 +- .../com/vesoft/nebula/meta/GetGroupResp.java | 20 +- .../com/vesoft/nebula/meta/GetZoneResp.java | 22 +- .../com/vesoft/nebula/meta/Group.java | 20 +- .../com/vesoft/nebula/meta/HBReq.java | 186 +- .../com/vesoft/nebula/meta/IndexParams.java | 454 ++ .../com/vesoft/nebula/meta/KillQueryReq.java | 44 +- .../nebula/meta/ListClusterInfoResp.java | 44 +- .../vesoft/nebula/meta/ListConfigsResp.java | 22 +- .../nebula/meta/ListEdgeIndexesResp.java | 22 +- .../vesoft/nebula/meta/ListFTClientsResp.java | 22 +- .../vesoft/nebula/meta/ListFTIndexesResp.java | 28 +- .../vesoft/nebula/meta/ListGroupsResp.java | 22 +- .../nebula/meta/ListIndexStatusResp.java | 22 +- .../vesoft/nebula/meta/ListListenerResp.java | 22 +- .../com/vesoft/nebula/meta/ListRolesResp.java | 22 +- .../vesoft/nebula/meta/ListSessionsResp.java | 22 +- .../vesoft/nebula/meta/ListSnapshotsResp.java | 22 +- .../nebula/meta/ListTagIndexesResp.java | 22 +- .../com/vesoft/nebula/meta/ListUsersResp.java | 26 +- .../com/vesoft/nebula/meta/ListZonesResp.java | 22 +- .../com/vesoft/nebula/meta/MetaService.java | 6098 +++-------------- .../com/vesoft/nebula/meta/PartitionList.java | 285 + .../com/vesoft/nebula/meta/RegConfigReq.java | 22 +- .../vesoft/nebula/meta/RestoreMetaReq.java | 42 +- .../com/vesoft/nebula/meta/Session.java | 56 +- .../nebula/meta/SignInFTServiceReq.java | 22 +- .../vesoft/nebula/meta/SpaceBackupInfo.java | 22 +- .../vesoft/nebula/meta/UpdateSessionsReq.java | 22 +- .../nebula/meta/UpdateSessionsResp.java | 52 +- .../nebula/meta/VerifyClientVersionReq.java | 94 +- .../com/vesoft/nebula/meta/Zone.java | 22 +- .../com/vesoft/nebula/storage/AddPartReq.java | 22 +- .../nebula/storage/ChainAddEdgesRequest.java | 66 +- .../storage/ChainUpdateEdgeRequest.java | 20 +- .../vesoft/nebula/storage/CheckPeersReq.java | 22 +- .../vesoft/nebula/storage/CreateCPResp.java | 22 +- .../nebula/storage/GetLeaderPartsResp.java | 44 +- .../nebula/storage/GraphStorageService.java | 1786 ++++- .../storage/InternalStorageService.java | 16 +- .../nebula/storage/InternalTxnRequest.java | 70 +- .../vesoft/nebula/storage/KVGetRequest.java | 44 +- .../vesoft/nebula/storage/KVGetResponse.java | 26 +- .../vesoft/nebula/storage/KVPutRequest.java | 46 +- .../nebula/storage/KVRemoveRequest.java | 44 +- .../nebula/storage/RebuildIndexRequest.java | 20 +- .../vesoft/nebula/storage/ResponseCommon.java | 28 +- .../nebula/storage/ScanEdgeRequest.java | 75 +- .../vesoft/nebula/storage/ScanResponse.java | 445 ++ .../nebula/storage/StorageAdminService.java | 128 +- .../com/vesoft/nebula/storage/TaskPara.java | 122 +- .../nebula/client/graph/data/ResultSet.java | 2 +- .../storage/GraphStorageConnection.java | 5 +- .../nebula/client/storage/StorageClient.java | 3 +- .../storage/processor/EdgeProcessor.java | 24 +- .../storage/processor/VertexProcessor.java | 19 +- .../client/storage/scan/PartScanInfo.java | 3 +- .../client/storage/scan/ScanEdgeResult.java | 7 +- .../storage/scan/ScanEdgeResultIterator.java | 35 +- .../storage/scan/ScanResultIterator.java | 33 + .../client/storage/scan/ScanVertexResult.java | 7 +- .../scan/ScanVertexResultIterator.java | 33 +- .../client/graph/data/TestDataFromServer.java | 9 +- .../client/storage/MockStorageData.java | 8 +- .../nebula/client/storage/MockUtil.java | 4 +- .../client/storage/StorageClientTest.java | 19 +- .../storage/scan/PartScanQueueTest.java | 2 +- .../nebula/examples/GraphClientExample.java | 45 +- .../nebula/examples/StorageClientExample.java | 31 +- 95 files changed, 7811 insertions(+), 6552 deletions(-) create mode 100644 client/src/main/generated/GetStateRequest.java create mode 100644 client/src/main/generated/GetStateResponse.java create mode 100644 client/src/main/generated/Role.java create mode 100644 client/src/main/generated/Status.java create mode 100644 client/src/main/generated/com/vesoft/nebula/LogEntry.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ScanResponse.java diff --git a/.github/workflows/deploy_release.yaml b/.github/workflows/deploy_release.yaml index 7a1c3a147..b382f05c8 100644 --- a/.github/workflows/deploy_release.yaml +++ b/.github/workflows/deploy_release.yaml @@ -25,7 +25,7 @@ jobs: pushd nebula-docker-compose/ cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d - sleep 10 + sleep 30 docker-compose ps popd popd diff --git a/.github/workflows/deploy_snapshot.yaml b/.github/workflows/deploy_snapshot.yaml index b854b97cc..7887cd161 100644 --- a/.github/workflows/deploy_snapshot.yaml +++ b/.github/workflows/deploy_snapshot.yaml @@ -26,7 +26,7 @@ jobs: pushd nebula-docker-compose/ cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d - sleep 10 + sleep 30 docker-compose ps popd popd diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index d6270e2da..6eb6c565b 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -40,7 +40,7 @@ jobs: pushd nebula-docker-compose/ cp ../../client/src/test/resources/docker-compose.yaml . docker-compose up -d - sleep 10 + sleep 30 docker-compose ps popd popd diff --git a/client/src/main/generated/AppendLogRequest.java b/client/src/main/generated/AppendLogRequest.java index fd8a542f2..693fce6c0 100644 --- a/client/src/main/generated/AppendLogRequest.java +++ b/client/src/main/generated/AppendLogRequest.java @@ -35,7 +35,6 @@ public class AppendLogRequest implements TBase, java.io.Serializable, Cloneable, private static final TField LAST_LOG_ID_SENT_FIELD_DESC = new TField("last_log_id_sent", TType.I64, (short)9); private static final TField LOG_TERM_FIELD_DESC = new TField("log_term", TType.I64, (short)10); private static final TField LOG_STR_LIST_FIELD_DESC = new TField("log_str_list", TType.LIST, (short)11); - private static final TField SENDING_SNAPSHOT_FIELD_DESC = new TField("sending_snapshot", TType.BOOL, (short)12); public int space; public int part; @@ -47,8 +46,7 @@ public class AppendLogRequest implements TBase, java.io.Serializable, Cloneable, public long last_log_term_sent; public long last_log_id_sent; public long log_term; - public List log_str_list; - public boolean sending_snapshot; + public List log_str_list; public static final int SPACE = 1; public static final int PART = 2; public static final int CURRENT_TERM = 3; @@ -60,7 +58,6 @@ public class AppendLogRequest implements TBase, java.io.Serializable, Cloneable, public static final int LAST_LOG_ID_SENT = 9; public static final int LOG_TERM = 10; public static final int LOG_STR_LIST = 11; - public static final int SENDING_SNAPSHOT = 12; // isset id assignments private static final int __SPACE_ISSET_ID = 0; @@ -72,8 +69,7 @@ public class AppendLogRequest implements TBase, java.io.Serializable, Cloneable, private static final int __LAST_LOG_TERM_SENT_ISSET_ID = 6; private static final int __LAST_LOG_ID_SENT_ISSET_ID = 7; private static final int __LOG_TERM_ISSET_ID = 8; - private static final int __SENDING_SNAPSHOT_ISSET_ID = 9; - private BitSet __isset_bit_vector = new BitSet(10); + private BitSet __isset_bit_vector = new BitSet(9); public static final Map metaDataMap; @@ -101,9 +97,7 @@ public class AppendLogRequest implements TBase, java.io.Serializable, Cloneable, new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(LOG_STR_LIST, new FieldMetaData("log_str_list", TFieldRequirementType.DEFAULT, new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, LogEntry.class)))); - tmpMetaDataMap.put(SENDING_SNAPSHOT, new FieldMetaData("sending_snapshot", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.BOOL))); + new StructMetaData(TType.STRUCT, com.vesoft.nebula.LogEntry.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -125,8 +119,7 @@ public AppendLogRequest( long last_log_term_sent, long last_log_id_sent, long log_term, - List log_str_list, - boolean sending_snapshot) { + List log_str_list) { this(); this.space = space; setSpaceIsSet(true); @@ -148,8 +141,6 @@ public AppendLogRequest( this.log_term = log_term; setLog_termIsSet(true); this.log_str_list = log_str_list; - this.sending_snapshot = sending_snapshot; - setSending_snapshotIsSet(true); } public static class Builder { @@ -163,10 +154,9 @@ public static class Builder { private long last_log_term_sent; private long last_log_id_sent; private long log_term; - private List log_str_list; - private boolean sending_snapshot; + private List log_str_list; - BitSet __optional_isset = new BitSet(10); + BitSet __optional_isset = new BitSet(9); public Builder() { } @@ -230,17 +220,11 @@ public Builder setLog_term(final long log_term) { return this; } - public Builder setLog_str_list(final List log_str_list) { + public Builder setLog_str_list(final List log_str_list) { this.log_str_list = log_str_list; return this; } - public Builder setSending_snapshot(final boolean sending_snapshot) { - this.sending_snapshot = sending_snapshot; - __optional_isset.set(__SENDING_SNAPSHOT_ISSET_ID, true); - return this; - } - public AppendLogRequest build() { AppendLogRequest result = new AppendLogRequest(); if (__optional_isset.get(__SPACE_ISSET_ID)) { @@ -272,9 +256,6 @@ public AppendLogRequest build() { result.setLog_term(this.log_term); } result.setLog_str_list(this.log_str_list); - if (__optional_isset.get(__SENDING_SNAPSHOT_ISSET_ID)) { - result.setSending_snapshot(this.sending_snapshot); - } return result; } } @@ -304,7 +285,6 @@ public AppendLogRequest(AppendLogRequest other) { if (other.isSetLog_str_list()) { this.log_str_list = TBaseHelper.deepCopy(other.log_str_list); } - this.sending_snapshot = TBaseHelper.deepCopy(other.sending_snapshot); } public AppendLogRequest deepCopy() { @@ -542,11 +522,11 @@ public void setLog_termIsSet(boolean __value) { __isset_bit_vector.set(__LOG_TERM_ISSET_ID, __value); } - public List getLog_str_list() { + public List getLog_str_list() { return this.log_str_list; } - public AppendLogRequest setLog_str_list(List log_str_list) { + public AppendLogRequest setLog_str_list(List log_str_list) { this.log_str_list = log_str_list; return this; } @@ -566,29 +546,6 @@ public void setLog_str_listIsSet(boolean __value) { } } - public boolean isSending_snapshot() { - return this.sending_snapshot; - } - - public AppendLogRequest setSending_snapshot(boolean sending_snapshot) { - this.sending_snapshot = sending_snapshot; - setSending_snapshotIsSet(true); - return this; - } - - public void unsetSending_snapshot() { - __isset_bit_vector.clear(__SENDING_SNAPSHOT_ISSET_ID); - } - - // Returns true if field sending_snapshot is set (has been assigned a value) and false otherwise - public boolean isSetSending_snapshot() { - return __isset_bit_vector.get(__SENDING_SNAPSHOT_ISSET_ID); - } - - public void setSending_snapshotIsSet(boolean __value) { - __isset_bit_vector.set(__SENDING_SNAPSHOT_ISSET_ID, __value); - } - @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { @@ -676,15 +633,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetLog_str_list(); } else { - setLog_str_list((List)__value); - } - break; - - case SENDING_SNAPSHOT: - if (__value == null) { - unsetSending_snapshot(); - } else { - setSending_snapshot((Boolean)__value); + setLog_str_list((List)__value); } break; @@ -728,9 +677,6 @@ public Object getFieldValue(int fieldID) { case LOG_STR_LIST: return getLog_str_list(); - case SENDING_SNAPSHOT: - return new Boolean(isSending_snapshot()); - default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -768,14 +714,12 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetLog_str_list(), that.isSetLog_str_list(), this.log_str_list, that.log_str_list)) { return false; } - if (!TBaseHelper.equalsNobinary(this.sending_snapshot, that.sending_snapshot)) { return false; } - return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space, part, current_term, last_log_id, committed_log_id, leader_addr, leader_port, last_log_term_sent, last_log_id_sent, log_term, log_str_list, sending_snapshot}); + return Arrays.deepHashCode(new Object[] {space, part, current_term, last_log_id, committed_log_id, leader_addr, leader_port, last_log_term_sent, last_log_id_sent, log_term, log_str_list}); } @Override @@ -878,14 +822,6 @@ public int compareTo(AppendLogRequest other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetSending_snapshot()).compareTo(other.isSetSending_snapshot()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(sending_snapshot, other.sending_snapshot); - if (lastComparison != 0) { - return lastComparison; - } return 0; } @@ -983,13 +919,13 @@ public void read(TProtocol iprot) throws TException { if (__field.type == TType.LIST) { { TList _list0 = iprot.readListBegin(); - this.log_str_list = new ArrayList(Math.max(0, _list0.size)); + this.log_str_list = new ArrayList(Math.max(0, _list0.size)); for (int _i1 = 0; (_list0.size < 0) ? iprot.peekList() : (_i1 < _list0.size); ++_i1) { - LogEntry _elem2; - _elem2 = new LogEntry(); + com.vesoft.nebula.LogEntry _elem2; + _elem2 = new com.vesoft.nebula.LogEntry(); _elem2.read(iprot); this.log_str_list.add(_elem2); } @@ -999,14 +935,6 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case SENDING_SNAPSHOT: - if (__field.type == TType.BOOL) { - this.sending_snapshot = iprot.readBool(); - setSending_snapshotIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -1060,16 +988,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LOG_STR_LIST_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.log_str_list.size())); - for (LogEntry _iter3 : this.log_str_list) { + for (com.vesoft.nebula.LogEntry _iter3 : this.log_str_list) { _iter3.write(oprot); } oprot.writeListEnd(); } oprot.writeFieldEnd(); } - oprot.writeFieldBegin(SENDING_SNAPSHOT_FIELD_DESC); - oprot.writeBool(this.sending_snapshot); - oprot.writeFieldEnd(); oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -1174,13 +1099,6 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getLog_str_list(), indent + 1, prettyPrint)); } first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("sending_snapshot"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isSending_snapshot(), indent + 1, prettyPrint)); - first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/AskForVoteRequest.java b/client/src/main/generated/AskForVoteRequest.java index 9922613b9..e74f97922 100644 --- a/client/src/main/generated/AskForVoteRequest.java +++ b/client/src/main/generated/AskForVoteRequest.java @@ -31,6 +31,7 @@ public class AskForVoteRequest implements TBase, java.io.Serializable, Cloneable private static final TField TERM_FIELD_DESC = new TField("term", TType.I64, (short)5); private static final TField LAST_LOG_ID_FIELD_DESC = new TField("last_log_id", TType.I64, (short)6); private static final TField LAST_LOG_TERM_FIELD_DESC = new TField("last_log_term", TType.I64, (short)7); + private static final TField IS_PRE_VOTE_FIELD_DESC = new TField("is_pre_vote", TType.BOOL, (short)8); public int space; public int part; @@ -39,6 +40,7 @@ public class AskForVoteRequest implements TBase, java.io.Serializable, Cloneable public long term; public long last_log_id; public long last_log_term; + public boolean is_pre_vote; public static final int SPACE = 1; public static final int PART = 2; public static final int CANDIDATE_ADDR = 3; @@ -46,6 +48,7 @@ public class AskForVoteRequest implements TBase, java.io.Serializable, Cloneable public static final int TERM = 5; public static final int LAST_LOG_ID = 6; public static final int LAST_LOG_TERM = 7; + public static final int IS_PRE_VOTE = 8; // isset id assignments private static final int __SPACE_ISSET_ID = 0; @@ -54,7 +57,8 @@ public class AskForVoteRequest implements TBase, java.io.Serializable, Cloneable private static final int __TERM_ISSET_ID = 3; private static final int __LAST_LOG_ID_ISSET_ID = 4; private static final int __LAST_LOG_TERM_ISSET_ID = 5; - private BitSet __isset_bit_vector = new BitSet(6); + private static final int __IS_PRE_VOTE_ISSET_ID = 6; + private BitSet __isset_bit_vector = new BitSet(7); public static final Map metaDataMap; @@ -74,6 +78,8 @@ public class AskForVoteRequest implements TBase, java.io.Serializable, Cloneable new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(LAST_LOG_TERM, new FieldMetaData("last_log_term", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(IS_PRE_VOTE, new FieldMetaData("is_pre_vote", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -91,7 +97,8 @@ public AskForVoteRequest( int candidate_port, long term, long last_log_id, - long last_log_term) { + long last_log_term, + boolean is_pre_vote) { this(); this.space = space; setSpaceIsSet(true); @@ -106,6 +113,8 @@ public AskForVoteRequest( setLast_log_idIsSet(true); this.last_log_term = last_log_term; setLast_log_termIsSet(true); + this.is_pre_vote = is_pre_vote; + setIs_pre_voteIsSet(true); } public static class Builder { @@ -116,8 +125,9 @@ public static class Builder { private long term; private long last_log_id; private long last_log_term; + private boolean is_pre_vote; - BitSet __optional_isset = new BitSet(6); + BitSet __optional_isset = new BitSet(7); public Builder() { } @@ -163,6 +173,12 @@ public Builder setLast_log_term(final long last_log_term) { return this; } + public Builder setIs_pre_vote(final boolean is_pre_vote) { + this.is_pre_vote = is_pre_vote; + __optional_isset.set(__IS_PRE_VOTE_ISSET_ID, true); + return this; + } + public AskForVoteRequest build() { AskForVoteRequest result = new AskForVoteRequest(); if (__optional_isset.get(__SPACE_ISSET_ID)) { @@ -184,6 +200,9 @@ public AskForVoteRequest build() { if (__optional_isset.get(__LAST_LOG_TERM_ISSET_ID)) { result.setLast_log_term(this.last_log_term); } + if (__optional_isset.get(__IS_PRE_VOTE_ISSET_ID)) { + result.setIs_pre_vote(this.is_pre_vote); + } return result; } } @@ -207,6 +226,7 @@ public AskForVoteRequest(AskForVoteRequest other) { this.term = TBaseHelper.deepCopy(other.term); this.last_log_id = TBaseHelper.deepCopy(other.last_log_id); this.last_log_term = TBaseHelper.deepCopy(other.last_log_term); + this.is_pre_vote = TBaseHelper.deepCopy(other.is_pre_vote); } public AskForVoteRequest deepCopy() { @@ -375,6 +395,29 @@ public void setLast_log_termIsSet(boolean __value) { __isset_bit_vector.set(__LAST_LOG_TERM_ISSET_ID, __value); } + public boolean isIs_pre_vote() { + return this.is_pre_vote; + } + + public AskForVoteRequest setIs_pre_vote(boolean is_pre_vote) { + this.is_pre_vote = is_pre_vote; + setIs_pre_voteIsSet(true); + return this; + } + + public void unsetIs_pre_vote() { + __isset_bit_vector.clear(__IS_PRE_VOTE_ISSET_ID); + } + + // Returns true if field is_pre_vote is set (has been assigned a value) and false otherwise + public boolean isSetIs_pre_vote() { + return __isset_bit_vector.get(__IS_PRE_VOTE_ISSET_ID); + } + + public void setIs_pre_voteIsSet(boolean __value) { + __isset_bit_vector.set(__IS_PRE_VOTE_ISSET_ID, __value); + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SPACE: @@ -433,6 +476,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case IS_PRE_VOTE: + if (__value == null) { + unsetIs_pre_vote(); + } else { + setIs_pre_vote((Boolean)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -461,6 +512,9 @@ public Object getFieldValue(int fieldID) { case LAST_LOG_TERM: return new Long(getLast_log_term()); + case IS_PRE_VOTE: + return new Boolean(isIs_pre_vote()); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -490,12 +544,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.last_log_term, that.last_log_term)) { return false; } + if (!TBaseHelper.equalsNobinary(this.is_pre_vote, that.is_pre_vote)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space, part, candidate_addr, candidate_port, term, last_log_id, last_log_term}); + return Arrays.deepHashCode(new Object[] {space, part, candidate_addr, candidate_port, term, last_log_id, last_log_term, is_pre_vote}); } @Override @@ -566,6 +622,14 @@ public int compareTo(AskForVoteRequest other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetIs_pre_vote()).compareTo(other.isSetIs_pre_vote()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(is_pre_vote, other.is_pre_vote); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -635,6 +699,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case IS_PRE_VOTE: + if (__field.type == TType.BOOL) { + this.is_pre_vote = iprot.readBool(); + setIs_pre_voteIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -675,6 +747,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LAST_LOG_TERM_FIELD_DESC); oprot.writeI64(this.last_log_term); oprot.writeFieldEnd(); + oprot.writeFieldBegin(IS_PRE_VOTE_FIELD_DESC); + oprot.writeBool(this.is_pre_vote); + oprot.writeFieldEnd(); oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -747,6 +822,13 @@ public String toString(int indent, boolean prettyPrint) { sb.append(":").append(space); sb.append(TBaseHelper.toString(this.getLast_log_term(), indent + 1, prettyPrint)); first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("is_pre_vote"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIs_pre_vote(), indent + 1, prettyPrint)); + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/ErrorCode.java b/client/src/main/generated/ErrorCode.java index f2d9a87db..c3e2942b9 100644 --- a/client/src/main/generated/ErrorCode.java +++ b/client/src/main/generated/ErrorCode.java @@ -12,32 +12,21 @@ @SuppressWarnings({ "unused" }) public enum ErrorCode implements com.facebook.thrift.TEnum { SUCCEEDED(0), - E_LOG_GAP(-1), - E_LOG_STALE(-2), - E_MISSING_COMMIT(-3), - E_WAITING_SNAPSHOT(-4), - E_UNKNOWN_PART(-5), - E_TERM_OUT_OF_DATE(-6), - E_LAST_LOG_TERM_TOO_OLD(-7), - E_BAD_STATE(-8), - E_WRONG_LEADER(-9), + E_UNKNOWN_PART(-1), + E_LOG_GAP(-2), + E_LOG_STALE(-3), + E_TERM_OUT_OF_DATE(-4), + E_WAITING_SNAPSHOT(-5), + E_BAD_STATE(-6), + E_WRONG_LEADER(-7), + E_NOT_READY(-8), + E_BAD_ROLE(-9), E_WAL_FAIL(-10), - E_NOT_READY(-11), - E_HOST_STOPPED(-12), - E_NOT_A_LEADER(-13), - E_HOST_DISCONNECTED(-14), - E_TOO_MANY_REQUESTS(-15), - E_PERSIST_SNAPSHOT_FAILED(-16), - E_BAD_ROLE(-17), - E_EXCEPTION(-20); - - private static final Map INDEXED_VALUES = new HashMap(); - - static { - for (ErrorCode e: values()) { - INDEXED_VALUES.put(e.getValue(), e); - } - } + E_HOST_STOPPED(-11), + E_TOO_MANY_REQUESTS(-12), + E_PERSIST_SNAPSHOT_FAILED(-13), + E_RPC_EXCEPTION(-14), + E_NO_WAL_FOUND(-15); private final int value; @@ -57,6 +46,41 @@ public int getValue() { * @return null if the value is not found. */ public static ErrorCode findByValue(int value) { - return INDEXED_VALUES.get(value); + switch (value) { + case 0: + return SUCCEEDED; + case -1: + return E_UNKNOWN_PART; + case -2: + return E_LOG_GAP; + case -3: + return E_LOG_STALE; + case -4: + return E_TERM_OUT_OF_DATE; + case -5: + return E_WAITING_SNAPSHOT; + case -6: + return E_BAD_STATE; + case -7: + return E_WRONG_LEADER; + case -8: + return E_NOT_READY; + case -9: + return E_BAD_ROLE; + case -10: + return E_WAL_FAIL; + case -11: + return E_HOST_STOPPED; + case -12: + return E_TOO_MANY_REQUESTS; + case -13: + return E_PERSIST_SNAPSHOT_FAILED; + case -14: + return E_RPC_EXCEPTION; + case -15: + return E_NO_WAL_FOUND; + default: + return null; + } } } diff --git a/client/src/main/generated/GetStateRequest.java b/client/src/main/generated/GetStateRequest.java new file mode 100644 index 000000000..0272de286 --- /dev/null +++ b/client/src/main/generated/GetStateRequest.java @@ -0,0 +1,347 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetStateRequest implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetStateRequest"); + private static final TField SPACE_FIELD_DESC = new TField("space", TType.I32, (short)1); + private static final TField PART_FIELD_DESC = new TField("part", TType.I32, (short)2); + + public int space; + public int part; + public static final int SPACE = 1; + public static final int PART = 2; + + // isset id assignments + private static final int __SPACE_ISSET_ID = 0; + private static final int __PART_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SPACE, new FieldMetaData("space", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(PART, new FieldMetaData("part", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetStateRequest.class, metaDataMap); + } + + public GetStateRequest() { + } + + public GetStateRequest( + int space, + int part) { + this(); + this.space = space; + setSpaceIsSet(true); + this.part = part; + setPartIsSet(true); + } + + public static class Builder { + private int space; + private int part; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setSpace(final int space) { + this.space = space; + __optional_isset.set(__SPACE_ISSET_ID, true); + return this; + } + + public Builder setPart(final int part) { + this.part = part; + __optional_isset.set(__PART_ISSET_ID, true); + return this; + } + + public GetStateRequest build() { + GetStateRequest result = new GetStateRequest(); + if (__optional_isset.get(__SPACE_ISSET_ID)) { + result.setSpace(this.space); + } + if (__optional_isset.get(__PART_ISSET_ID)) { + result.setPart(this.part); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetStateRequest(GetStateRequest other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.space = TBaseHelper.deepCopy(other.space); + this.part = TBaseHelper.deepCopy(other.part); + } + + public GetStateRequest deepCopy() { + return new GetStateRequest(this); + } + + public int getSpace() { + return this.space; + } + + public GetStateRequest setSpace(int space) { + this.space = space; + setSpaceIsSet(true); + return this; + } + + public void unsetSpace() { + __isset_bit_vector.clear(__SPACE_ISSET_ID); + } + + // Returns true if field space is set (has been assigned a value) and false otherwise + public boolean isSetSpace() { + return __isset_bit_vector.get(__SPACE_ISSET_ID); + } + + public void setSpaceIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ISSET_ID, __value); + } + + public int getPart() { + return this.part; + } + + public GetStateRequest setPart(int part) { + this.part = part; + setPartIsSet(true); + return this; + } + + public void unsetPart() { + __isset_bit_vector.clear(__PART_ISSET_ID); + } + + // Returns true if field part is set (has been assigned a value) and false otherwise + public boolean isSetPart() { + return __isset_bit_vector.get(__PART_ISSET_ID); + } + + public void setPartIsSet(boolean __value) { + __isset_bit_vector.set(__PART_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SPACE: + if (__value == null) { + unsetSpace(); + } else { + setSpace((Integer)__value); + } + break; + + case PART: + if (__value == null) { + unsetPart(); + } else { + setPart((Integer)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SPACE: + return new Integer(getSpace()); + + case PART: + return new Integer(getPart()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetStateRequest)) + return false; + GetStateRequest that = (GetStateRequest)_that; + + if (!TBaseHelper.equalsNobinary(this.space, that.space)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.part, that.part)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {space, part}); + } + + @Override + public int compareTo(GetStateRequest other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSpace()).compareTo(other.isSetSpace()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space, other.space); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetPart()).compareTo(other.isSetPart()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(part, other.part); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SPACE: + if (__field.type == TType.I32) { + this.space = iprot.readI32(); + setSpaceIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PART: + if (__field.type == TType.I32) { + this.part = iprot.readI32(); + setPartIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SPACE_FIELD_DESC); + oprot.writeI32(this.space); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(PART_FIELD_DESC); + oprot.writeI32(this.part); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetStateRequest"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("space"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("part"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getPart(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/GetStateResponse.java b/client/src/main/generated/GetStateResponse.java new file mode 100644 index 000000000..f20c7a739 --- /dev/null +++ b/client/src/main/generated/GetStateResponse.java @@ -0,0 +1,908 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetStateResponse implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetStateResponse"); + private static final TField ERROR_CODE_FIELD_DESC = new TField("error_code", TType.I32, (short)1); + private static final TField ROLE_FIELD_DESC = new TField("role", TType.I32, (short)2); + private static final TField TERM_FIELD_DESC = new TField("term", TType.I64, (short)3); + private static final TField IS_LEADER_FIELD_DESC = new TField("is_leader", TType.BOOL, (short)4); + private static final TField COMMITTED_LOG_ID_FIELD_DESC = new TField("committed_log_id", TType.I64, (short)5); + private static final TField LAST_LOG_ID_FIELD_DESC = new TField("last_log_id", TType.I64, (short)6); + private static final TField LAST_LOG_TERM_FIELD_DESC = new TField("last_log_term", TType.I64, (short)7); + private static final TField STATUS_FIELD_DESC = new TField("status", TType.I32, (short)8); + + /** + * + * @see ErrorCode + */ + public ErrorCode error_code; + /** + * + * @see Role + */ + public Role role; + public long term; + public boolean is_leader; + public long committed_log_id; + public long last_log_id; + public long last_log_term; + /** + * + * @see Status + */ + public Status status; + public static final int ERROR_CODE = 1; + public static final int ROLE = 2; + public static final int TERM = 3; + public static final int IS_LEADER = 4; + public static final int COMMITTED_LOG_ID = 5; + public static final int LAST_LOG_ID = 6; + public static final int LAST_LOG_TERM = 7; + public static final int STATUS = 8; + + // isset id assignments + private static final int __TERM_ISSET_ID = 0; + private static final int __IS_LEADER_ISSET_ID = 1; + private static final int __COMMITTED_LOG_ID_ISSET_ID = 2; + private static final int __LAST_LOG_ID_ISSET_ID = 3; + private static final int __LAST_LOG_TERM_ISSET_ID = 4; + private BitSet __isset_bit_vector = new BitSet(5); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(ERROR_CODE, new FieldMetaData("error_code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(ROLE, new FieldMetaData("role", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(TERM, new FieldMetaData("term", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(IS_LEADER, new FieldMetaData("is_leader", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(COMMITTED_LOG_ID, new FieldMetaData("committed_log_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(LAST_LOG_ID, new FieldMetaData("last_log_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(LAST_LOG_TERM, new FieldMetaData("last_log_term", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(STATUS, new FieldMetaData("status", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetStateResponse.class, metaDataMap); + } + + public GetStateResponse() { + } + + public GetStateResponse( + ErrorCode error_code, + Role role, + long term, + boolean is_leader, + long committed_log_id, + long last_log_id, + long last_log_term, + Status status) { + this(); + this.error_code = error_code; + this.role = role; + this.term = term; + setTermIsSet(true); + this.is_leader = is_leader; + setIs_leaderIsSet(true); + this.committed_log_id = committed_log_id; + setCommitted_log_idIsSet(true); + this.last_log_id = last_log_id; + setLast_log_idIsSet(true); + this.last_log_term = last_log_term; + setLast_log_termIsSet(true); + this.status = status; + } + + public static class Builder { + private ErrorCode error_code; + private Role role; + private long term; + private boolean is_leader; + private long committed_log_id; + private long last_log_id; + private long last_log_term; + private Status status; + + BitSet __optional_isset = new BitSet(5); + + public Builder() { + } + + public Builder setError_code(final ErrorCode error_code) { + this.error_code = error_code; + return this; + } + + public Builder setRole(final Role role) { + this.role = role; + return this; + } + + public Builder setTerm(final long term) { + this.term = term; + __optional_isset.set(__TERM_ISSET_ID, true); + return this; + } + + public Builder setIs_leader(final boolean is_leader) { + this.is_leader = is_leader; + __optional_isset.set(__IS_LEADER_ISSET_ID, true); + return this; + } + + public Builder setCommitted_log_id(final long committed_log_id) { + this.committed_log_id = committed_log_id; + __optional_isset.set(__COMMITTED_LOG_ID_ISSET_ID, true); + return this; + } + + public Builder setLast_log_id(final long last_log_id) { + this.last_log_id = last_log_id; + __optional_isset.set(__LAST_LOG_ID_ISSET_ID, true); + return this; + } + + public Builder setLast_log_term(final long last_log_term) { + this.last_log_term = last_log_term; + __optional_isset.set(__LAST_LOG_TERM_ISSET_ID, true); + return this; + } + + public Builder setStatus(final Status status) { + this.status = status; + return this; + } + + public GetStateResponse build() { + GetStateResponse result = new GetStateResponse(); + result.setError_code(this.error_code); + result.setRole(this.role); + if (__optional_isset.get(__TERM_ISSET_ID)) { + result.setTerm(this.term); + } + if (__optional_isset.get(__IS_LEADER_ISSET_ID)) { + result.setIs_leader(this.is_leader); + } + if (__optional_isset.get(__COMMITTED_LOG_ID_ISSET_ID)) { + result.setCommitted_log_id(this.committed_log_id); + } + if (__optional_isset.get(__LAST_LOG_ID_ISSET_ID)) { + result.setLast_log_id(this.last_log_id); + } + if (__optional_isset.get(__LAST_LOG_TERM_ISSET_ID)) { + result.setLast_log_term(this.last_log_term); + } + result.setStatus(this.status); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetStateResponse(GetStateResponse other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + if (other.isSetError_code()) { + this.error_code = TBaseHelper.deepCopy(other.error_code); + } + if (other.isSetRole()) { + this.role = TBaseHelper.deepCopy(other.role); + } + this.term = TBaseHelper.deepCopy(other.term); + this.is_leader = TBaseHelper.deepCopy(other.is_leader); + this.committed_log_id = TBaseHelper.deepCopy(other.committed_log_id); + this.last_log_id = TBaseHelper.deepCopy(other.last_log_id); + this.last_log_term = TBaseHelper.deepCopy(other.last_log_term); + if (other.isSetStatus()) { + this.status = TBaseHelper.deepCopy(other.status); + } + } + + public GetStateResponse deepCopy() { + return new GetStateResponse(this); + } + + /** + * + * @see ErrorCode + */ + public ErrorCode getError_code() { + return this.error_code; + } + + /** + * + * @see ErrorCode + */ + public GetStateResponse setError_code(ErrorCode error_code) { + this.error_code = error_code; + return this; + } + + public void unsetError_code() { + this.error_code = null; + } + + // Returns true if field error_code is set (has been assigned a value) and false otherwise + public boolean isSetError_code() { + return this.error_code != null; + } + + public void setError_codeIsSet(boolean __value) { + if (!__value) { + this.error_code = null; + } + } + + /** + * + * @see Role + */ + public Role getRole() { + return this.role; + } + + /** + * + * @see Role + */ + public GetStateResponse setRole(Role role) { + this.role = role; + return this; + } + + public void unsetRole() { + this.role = null; + } + + // Returns true if field role is set (has been assigned a value) and false otherwise + public boolean isSetRole() { + return this.role != null; + } + + public void setRoleIsSet(boolean __value) { + if (!__value) { + this.role = null; + } + } + + public long getTerm() { + return this.term; + } + + public GetStateResponse setTerm(long term) { + this.term = term; + setTermIsSet(true); + return this; + } + + public void unsetTerm() { + __isset_bit_vector.clear(__TERM_ISSET_ID); + } + + // Returns true if field term is set (has been assigned a value) and false otherwise + public boolean isSetTerm() { + return __isset_bit_vector.get(__TERM_ISSET_ID); + } + + public void setTermIsSet(boolean __value) { + __isset_bit_vector.set(__TERM_ISSET_ID, __value); + } + + public boolean isIs_leader() { + return this.is_leader; + } + + public GetStateResponse setIs_leader(boolean is_leader) { + this.is_leader = is_leader; + setIs_leaderIsSet(true); + return this; + } + + public void unsetIs_leader() { + __isset_bit_vector.clear(__IS_LEADER_ISSET_ID); + } + + // Returns true if field is_leader is set (has been assigned a value) and false otherwise + public boolean isSetIs_leader() { + return __isset_bit_vector.get(__IS_LEADER_ISSET_ID); + } + + public void setIs_leaderIsSet(boolean __value) { + __isset_bit_vector.set(__IS_LEADER_ISSET_ID, __value); + } + + public long getCommitted_log_id() { + return this.committed_log_id; + } + + public GetStateResponse setCommitted_log_id(long committed_log_id) { + this.committed_log_id = committed_log_id; + setCommitted_log_idIsSet(true); + return this; + } + + public void unsetCommitted_log_id() { + __isset_bit_vector.clear(__COMMITTED_LOG_ID_ISSET_ID); + } + + // Returns true if field committed_log_id is set (has been assigned a value) and false otherwise + public boolean isSetCommitted_log_id() { + return __isset_bit_vector.get(__COMMITTED_LOG_ID_ISSET_ID); + } + + public void setCommitted_log_idIsSet(boolean __value) { + __isset_bit_vector.set(__COMMITTED_LOG_ID_ISSET_ID, __value); + } + + public long getLast_log_id() { + return this.last_log_id; + } + + public GetStateResponse setLast_log_id(long last_log_id) { + this.last_log_id = last_log_id; + setLast_log_idIsSet(true); + return this; + } + + public void unsetLast_log_id() { + __isset_bit_vector.clear(__LAST_LOG_ID_ISSET_ID); + } + + // Returns true if field last_log_id is set (has been assigned a value) and false otherwise + public boolean isSetLast_log_id() { + return __isset_bit_vector.get(__LAST_LOG_ID_ISSET_ID); + } + + public void setLast_log_idIsSet(boolean __value) { + __isset_bit_vector.set(__LAST_LOG_ID_ISSET_ID, __value); + } + + public long getLast_log_term() { + return this.last_log_term; + } + + public GetStateResponse setLast_log_term(long last_log_term) { + this.last_log_term = last_log_term; + setLast_log_termIsSet(true); + return this; + } + + public void unsetLast_log_term() { + __isset_bit_vector.clear(__LAST_LOG_TERM_ISSET_ID); + } + + // Returns true if field last_log_term is set (has been assigned a value) and false otherwise + public boolean isSetLast_log_term() { + return __isset_bit_vector.get(__LAST_LOG_TERM_ISSET_ID); + } + + public void setLast_log_termIsSet(boolean __value) { + __isset_bit_vector.set(__LAST_LOG_TERM_ISSET_ID, __value); + } + + /** + * + * @see Status + */ + public Status getStatus() { + return this.status; + } + + /** + * + * @see Status + */ + public GetStateResponse setStatus(Status status) { + this.status = status; + return this; + } + + public void unsetStatus() { + this.status = null; + } + + // Returns true if field status is set (has been assigned a value) and false otherwise + public boolean isSetStatus() { + return this.status != null; + } + + public void setStatusIsSet(boolean __value) { + if (!__value) { + this.status = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case ERROR_CODE: + if (__value == null) { + unsetError_code(); + } else { + setError_code((ErrorCode)__value); + } + break; + + case ROLE: + if (__value == null) { + unsetRole(); + } else { + setRole((Role)__value); + } + break; + + case TERM: + if (__value == null) { + unsetTerm(); + } else { + setTerm((Long)__value); + } + break; + + case IS_LEADER: + if (__value == null) { + unsetIs_leader(); + } else { + setIs_leader((Boolean)__value); + } + break; + + case COMMITTED_LOG_ID: + if (__value == null) { + unsetCommitted_log_id(); + } else { + setCommitted_log_id((Long)__value); + } + break; + + case LAST_LOG_ID: + if (__value == null) { + unsetLast_log_id(); + } else { + setLast_log_id((Long)__value); + } + break; + + case LAST_LOG_TERM: + if (__value == null) { + unsetLast_log_term(); + } else { + setLast_log_term((Long)__value); + } + break; + + case STATUS: + if (__value == null) { + unsetStatus(); + } else { + setStatus((Status)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case ERROR_CODE: + return getError_code(); + + case ROLE: + return getRole(); + + case TERM: + return new Long(getTerm()); + + case IS_LEADER: + return new Boolean(isIs_leader()); + + case COMMITTED_LOG_ID: + return new Long(getCommitted_log_id()); + + case LAST_LOG_ID: + return new Long(getLast_log_id()); + + case LAST_LOG_TERM: + return new Long(getLast_log_term()); + + case STATUS: + return getStatus(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetStateResponse)) + return false; + GetStateResponse that = (GetStateResponse)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetError_code(), that.isSetError_code(), this.error_code, that.error_code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetRole(), that.isSetRole(), this.role, that.role)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.term, that.term)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.is_leader, that.is_leader)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.committed_log_id, that.committed_log_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.last_log_id, that.last_log_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.last_log_term, that.last_log_term)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetStatus(), that.isSetStatus(), this.status, that.status)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {error_code, role, term, is_leader, committed_log_id, last_log_id, last_log_term, status}); + } + + @Override + public int compareTo(GetStateResponse other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetError_code()).compareTo(other.isSetError_code()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(error_code, other.error_code); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetRole()).compareTo(other.isSetRole()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(role, other.role); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetTerm()).compareTo(other.isSetTerm()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(term, other.term); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetIs_leader()).compareTo(other.isSetIs_leader()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(is_leader, other.is_leader); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetCommitted_log_id()).compareTo(other.isSetCommitted_log_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(committed_log_id, other.committed_log_id); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetLast_log_id()).compareTo(other.isSetLast_log_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(last_log_id, other.last_log_id); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetLast_log_term()).compareTo(other.isSetLast_log_term()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(last_log_term, other.last_log_term); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(status, other.status); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case ERROR_CODE: + if (__field.type == TType.I32) { + this.error_code = ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ROLE: + if (__field.type == TType.I32) { + this.role = Role.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TERM: + if (__field.type == TType.I64) { + this.term = iprot.readI64(); + setTermIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case IS_LEADER: + if (__field.type == TType.BOOL) { + this.is_leader = iprot.readBool(); + setIs_leaderIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case COMMITTED_LOG_ID: + if (__field.type == TType.I64) { + this.committed_log_id = iprot.readI64(); + setCommitted_log_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LAST_LOG_ID: + if (__field.type == TType.I64) { + this.last_log_id = iprot.readI64(); + setLast_log_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LAST_LOG_TERM: + if (__field.type == TType.I64) { + this.last_log_term = iprot.readI64(); + setLast_log_termIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STATUS: + if (__field.type == TType.I32) { + this.status = Status.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.error_code != null) { + oprot.writeFieldBegin(ERROR_CODE_FIELD_DESC); + oprot.writeI32(this.error_code == null ? 0 : this.error_code.getValue()); + oprot.writeFieldEnd(); + } + if (this.role != null) { + oprot.writeFieldBegin(ROLE_FIELD_DESC); + oprot.writeI32(this.role == null ? 0 : this.role.getValue()); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(TERM_FIELD_DESC); + oprot.writeI64(this.term); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(IS_LEADER_FIELD_DESC); + oprot.writeBool(this.is_leader); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(COMMITTED_LOG_ID_FIELD_DESC); + oprot.writeI64(this.committed_log_id); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(LAST_LOG_ID_FIELD_DESC); + oprot.writeI64(this.last_log_id); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(LAST_LOG_TERM_FIELD_DESC); + oprot.writeI64(this.last_log_term); + oprot.writeFieldEnd(); + if (this.status != null) { + oprot.writeFieldBegin(STATUS_FIELD_DESC); + oprot.writeI32(this.status == null ? 0 : this.status.getValue()); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetStateResponse"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("error_code"); + sb.append(space); + sb.append(":").append(space); + if (this.getError_code() == null) { + sb.append("null"); + } else { + String error_code_name = this.getError_code() == null ? "null" : this.getError_code().name(); + if (error_code_name != null) { + sb.append(error_code_name); + sb.append(" ("); + } + sb.append(this.getError_code()); + if (error_code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("role"); + sb.append(space); + sb.append(":").append(space); + if (this.getRole() == null) { + sb.append("null"); + } else { + String role_name = this.getRole() == null ? "null" : this.getRole().name(); + if (role_name != null) { + sb.append(role_name); + sb.append(" ("); + } + sb.append(this.getRole()); + if (role_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("term"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTerm(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("is_leader"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIs_leader(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("committed_log_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getCommitted_log_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("last_log_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getLast_log_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("last_log_term"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getLast_log_term(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("status"); + sb.append(space); + sb.append(":").append(space); + if (this.getStatus() == null) { + sb.append("null"); + } else { + String status_name = this.getStatus() == null ? "null" : this.getStatus().name(); + if (status_name != null) { + sb.append(status_name); + sb.append(" ("); + } + sb.append(this.getStatus()); + if (status_name != null) { + sb.append(")"); + } + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/RaftexService.java b/client/src/main/generated/RaftexService.java index e00e536ca..f1d0a7fbc 100644 --- a/client/src/main/generated/RaftexService.java +++ b/client/src/main/generated/RaftexService.java @@ -37,6 +37,8 @@ public interface Iface { public HeartbeatResponse heartbeat(HeartbeatRequest req) throws TException; + public GetStateResponse getState(GetStateRequest req) throws TException; + } public interface AsyncIface { @@ -49,6 +51,8 @@ public interface AsyncIface { public void heartbeat(HeartbeatRequest req, AsyncMethodCallback resultHandler) throws TException; + public void getState(GetStateRequest req, AsyncMethodCallback resultHandler) throws TException; + } public static class Client extends EventHandlerBase implements Iface, TClientIf { @@ -260,6 +264,51 @@ public HeartbeatResponse recv_heartbeat() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "heartbeat failed: unknown result"); } + public GetStateResponse getState(GetStateRequest req) throws TException + { + ContextStack ctx = getContextStack("RaftexService.getState", null); + this.setContextStack(ctx); + send_getState(req); + return recv_getState(); + } + + public void send_getState(GetStateRequest req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "RaftexService.getState", null); + oprot_.writeMessageBegin(new TMessage("getState", TMessageType.CALL, seqid_)); + getState_args args = new getState_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "RaftexService.getState", args); + return; + } + + public GetStateResponse recv_getState() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "RaftexService.getState"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + getState_result result = new getState_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "RaftexService.getState", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "getState failed: unknown result"); + } + } public static class AsyncClient extends TAsyncClient implements AsyncIface { public static class Factory implements TAsyncClientFactory { @@ -278,17 +327,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void askForVote(AskForVoteRequest req, AsyncMethodCallback resultHandler15) throws TException { + public void askForVote(AskForVoteRequest req, AsyncMethodCallback resultHandler16) throws TException { checkReady(); - askForVote_call method_call = new askForVote_call(req, resultHandler15, this, ___protocolFactory, ___transport); + askForVote_call method_call = new askForVote_call(req, resultHandler16, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class askForVote_call extends TAsyncMethodCall { private AskForVoteRequest req; - public askForVote_call(AskForVoteRequest req, AsyncMethodCallback resultHandler16, TAsyncClient client12, TProtocolFactory protocolFactory13, TNonblockingTransport transport14) throws TException { - super(client12, protocolFactory13, transport14, resultHandler16, false); + public askForVote_call(AskForVoteRequest req, AsyncMethodCallback resultHandler17, TAsyncClient client13, TProtocolFactory protocolFactory14, TNonblockingTransport transport15) throws TException { + super(client13, protocolFactory14, transport15, resultHandler17, false); this.req = req; } @@ -310,17 +359,17 @@ public AskForVoteResponse getResult() throws TException { } } - public void appendLog(AppendLogRequest req, AsyncMethodCallback resultHandler20) throws TException { + public void appendLog(AppendLogRequest req, AsyncMethodCallback resultHandler21) throws TException { checkReady(); - appendLog_call method_call = new appendLog_call(req, resultHandler20, this, ___protocolFactory, ___transport); + appendLog_call method_call = new appendLog_call(req, resultHandler21, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class appendLog_call extends TAsyncMethodCall { private AppendLogRequest req; - public appendLog_call(AppendLogRequest req, AsyncMethodCallback resultHandler21, TAsyncClient client17, TProtocolFactory protocolFactory18, TNonblockingTransport transport19) throws TException { - super(client17, protocolFactory18, transport19, resultHandler21, false); + public appendLog_call(AppendLogRequest req, AsyncMethodCallback resultHandler22, TAsyncClient client18, TProtocolFactory protocolFactory19, TNonblockingTransport transport20) throws TException { + super(client18, protocolFactory19, transport20, resultHandler22, false); this.req = req; } @@ -342,17 +391,17 @@ public AppendLogResponse getResult() throws TException { } } - public void sendSnapshot(SendSnapshotRequest req, AsyncMethodCallback resultHandler25) throws TException { + public void sendSnapshot(SendSnapshotRequest req, AsyncMethodCallback resultHandler26) throws TException { checkReady(); - sendSnapshot_call method_call = new sendSnapshot_call(req, resultHandler25, this, ___protocolFactory, ___transport); + sendSnapshot_call method_call = new sendSnapshot_call(req, resultHandler26, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class sendSnapshot_call extends TAsyncMethodCall { private SendSnapshotRequest req; - public sendSnapshot_call(SendSnapshotRequest req, AsyncMethodCallback resultHandler26, TAsyncClient client22, TProtocolFactory protocolFactory23, TNonblockingTransport transport24) throws TException { - super(client22, protocolFactory23, transport24, resultHandler26, false); + public sendSnapshot_call(SendSnapshotRequest req, AsyncMethodCallback resultHandler27, TAsyncClient client23, TProtocolFactory protocolFactory24, TNonblockingTransport transport25) throws TException { + super(client23, protocolFactory24, transport25, resultHandler27, false); this.req = req; } @@ -374,17 +423,17 @@ public SendSnapshotResponse getResult() throws TException { } } - public void heartbeat(HeartbeatRequest req, AsyncMethodCallback resultHandler30) throws TException { + public void heartbeat(HeartbeatRequest req, AsyncMethodCallback resultHandler31) throws TException { checkReady(); - heartbeat_call method_call = new heartbeat_call(req, resultHandler30, this, ___protocolFactory, ___transport); + heartbeat_call method_call = new heartbeat_call(req, resultHandler31, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class heartbeat_call extends TAsyncMethodCall { private HeartbeatRequest req; - public heartbeat_call(HeartbeatRequest req, AsyncMethodCallback resultHandler31, TAsyncClient client27, TProtocolFactory protocolFactory28, TNonblockingTransport transport29) throws TException { - super(client27, protocolFactory28, transport29, resultHandler31, false); + public heartbeat_call(HeartbeatRequest req, AsyncMethodCallback resultHandler32, TAsyncClient client28, TProtocolFactory protocolFactory29, TNonblockingTransport transport30) throws TException { + super(client28, protocolFactory29, transport30, resultHandler32, false); this.req = req; } @@ -406,6 +455,38 @@ public HeartbeatResponse getResult() throws TException { } } + public void getState(GetStateRequest req, AsyncMethodCallback resultHandler36) throws TException { + checkReady(); + getState_call method_call = new getState_call(req, resultHandler36, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class getState_call extends TAsyncMethodCall { + private GetStateRequest req; + public getState_call(GetStateRequest req, AsyncMethodCallback resultHandler37, TAsyncClient client33, TProtocolFactory protocolFactory34, TNonblockingTransport transport35) throws TException { + super(client33, protocolFactory34, transport35, resultHandler37, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("getState", TMessageType.CALL, 0)); + getState_args args = new getState_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public GetStateResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_getState(); + } + } + } public static class Processor implements TProcessor { @@ -418,6 +499,7 @@ public Processor(Iface iface) processMap_.put("appendLog", new appendLog()); processMap_.put("sendSnapshot", new sendSnapshot()); processMap_.put("heartbeat", new heartbeat()); + processMap_.put("getState", new getState()); } protected static interface ProcessFunction { @@ -534,6 +616,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class getState implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("RaftexService.getState", server_ctx); + getState_args args = new getState_args(); + event_handler_.preRead(handler_ctx, "RaftexService.getState"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "RaftexService.getState", args); + getState_result result = new getState_result(); + result.success = iface_.getState(args.req); + event_handler_.preWrite(handler_ctx, "RaftexService.getState", result); + oprot.writeMessageBegin(new TMessage("getState", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "RaftexService.getState", result); + } + + } + } public static class askForVote_args implements TBase, java.io.Serializable, Cloneable, Comparable { @@ -2276,4 +2379,439 @@ public void validate() throws TException { } + public static class getState_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getState_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public GetStateRequest req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, GetStateRequest.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(getState_args.class, metaDataMap); + } + + public getState_args() { + } + + public getState_args( + GetStateRequest req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public getState_args(getState_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public getState_args deepCopy() { + return new getState_args(this); + } + + public GetStateRequest getReq() { + return this.req; + } + + public getState_args setReq(GetStateRequest req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((GetStateRequest)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof getState_args)) + return false; + getState_args that = (getState_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(getState_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new GetStateRequest(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("getState_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class getState_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getState_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public GetStateResponse success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, GetStateResponse.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(getState_result.class, metaDataMap); + } + + public getState_result() { + } + + public getState_result( + GetStateResponse success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public getState_result(getState_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public getState_result deepCopy() { + return new getState_result(this); + } + + public GetStateResponse getSuccess() { + return this.success; + } + + public getState_result setSuccess(GetStateResponse success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((GetStateResponse)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof getState_result)) + return false; + getState_result that = (getState_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(getState_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new GetStateResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("getState_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + } diff --git a/client/src/main/generated/Role.java b/client/src/main/generated/Role.java new file mode 100644 index 000000000..6e3ea6e15 --- /dev/null +++ b/client/src/main/generated/Role.java @@ -0,0 +1,50 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ + +import com.facebook.thrift.IntRangeSet; +import java.util.Map; +import java.util.HashMap; + +@SuppressWarnings({ "unused" }) +public enum Role implements com.facebook.thrift.TEnum { + LEADER(1), + FOLLOWER(2), + CANDIDATE(3), + LEARNER(4); + + private final int value; + + private Role(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static Role findByValue(int value) { + switch (value) { + case 1: + return LEADER; + case 2: + return FOLLOWER; + case 3: + return CANDIDATE; + case 4: + return LEARNER; + default: + return null; + } + } +} diff --git a/client/src/main/generated/Status.java b/client/src/main/generated/Status.java new file mode 100644 index 000000000..f32f0760c --- /dev/null +++ b/client/src/main/generated/Status.java @@ -0,0 +1,50 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ + +import com.facebook.thrift.IntRangeSet; +import java.util.Map; +import java.util.HashMap; + +@SuppressWarnings({ "unused" }) +public enum Status implements com.facebook.thrift.TEnum { + STARTING(0), + RUNNING(1), + STOPPED(2), + WAITING_SNAPSHOT(3); + + private final int value; + + private Status(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static Status findByValue(int value) { + switch (value) { + case 0: + return STARTING; + case 1: + return RUNNING; + case 2: + return STOPPED; + case 3: + return WAITING_SNAPSHOT; + default: + return null; + } + } +} diff --git a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java index c31b591bd..cd84b2ceb 100644 --- a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java +++ b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java @@ -66,7 +66,7 @@ public enum ErrorCode implements com.facebook.thrift.TEnum { E_BALANCED(-2024), E_NO_RUNNING_BALANCE_PLAN(-2025), E_NO_VALID_HOST(-2026), - E_CORRUPTTED_BALANCE_PLAN(-2027), + E_CORRUPTED_BALANCE_PLAN(-2027), E_NO_INVALID_BALANCE_PLAN(-2028), E_IMPROPER_ROLE(-2030), E_INVALID_PARTITION_NUM(-2031), diff --git a/client/src/main/generated/com/vesoft/nebula/LogEntry.java b/client/src/main/generated/com/vesoft/nebula/LogEntry.java new file mode 100644 index 000000000..3b03c984f --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/LogEntry.java @@ -0,0 +1,357 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class LogEntry implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("LogEntry"); + private static final TField CLUSTER_FIELD_DESC = new TField("cluster", TType.I64, (short)1); + private static final TField LOG_STR_FIELD_DESC = new TField("log_str", TType.STRING, (short)2); + + public long cluster; + public byte[] log_str; + public static final int CLUSTER = 1; + public static final int LOG_STR = 2; + + // isset id assignments + private static final int __CLUSTER_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CLUSTER, new FieldMetaData("cluster", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(LOG_STR, new FieldMetaData("log_str", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(LogEntry.class, metaDataMap); + } + + public LogEntry() { + } + + public LogEntry( + long cluster, + byte[] log_str) { + this(); + this.cluster = cluster; + setClusterIsSet(true); + this.log_str = log_str; + } + + public static class Builder { + private long cluster; + private byte[] log_str; + + BitSet __optional_isset = new BitSet(1); + + public Builder() { + } + + public Builder setCluster(final long cluster) { + this.cluster = cluster; + __optional_isset.set(__CLUSTER_ISSET_ID, true); + return this; + } + + public Builder setLog_str(final byte[] log_str) { + this.log_str = log_str; + return this; + } + + public LogEntry build() { + LogEntry result = new LogEntry(); + if (__optional_isset.get(__CLUSTER_ISSET_ID)) { + result.setCluster(this.cluster); + } + result.setLog_str(this.log_str); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public LogEntry(LogEntry other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.cluster = TBaseHelper.deepCopy(other.cluster); + if (other.isSetLog_str()) { + this.log_str = TBaseHelper.deepCopy(other.log_str); + } + } + + public LogEntry deepCopy() { + return new LogEntry(this); + } + + public long getCluster() { + return this.cluster; + } + + public LogEntry setCluster(long cluster) { + this.cluster = cluster; + setClusterIsSet(true); + return this; + } + + public void unsetCluster() { + __isset_bit_vector.clear(__CLUSTER_ISSET_ID); + } + + // Returns true if field cluster is set (has been assigned a value) and false otherwise + public boolean isSetCluster() { + return __isset_bit_vector.get(__CLUSTER_ISSET_ID); + } + + public void setClusterIsSet(boolean __value) { + __isset_bit_vector.set(__CLUSTER_ISSET_ID, __value); + } + + public byte[] getLog_str() { + return this.log_str; + } + + public LogEntry setLog_str(byte[] log_str) { + this.log_str = log_str; + return this; + } + + public void unsetLog_str() { + this.log_str = null; + } + + // Returns true if field log_str is set (has been assigned a value) and false otherwise + public boolean isSetLog_str() { + return this.log_str != null; + } + + public void setLog_strIsSet(boolean __value) { + if (!__value) { + this.log_str = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CLUSTER: + if (__value == null) { + unsetCluster(); + } else { + setCluster((Long)__value); + } + break; + + case LOG_STR: + if (__value == null) { + unsetLog_str(); + } else { + setLog_str((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CLUSTER: + return new Long(getCluster()); + + case LOG_STR: + return getLog_str(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof LogEntry)) + return false; + LogEntry that = (LogEntry)_that; + + if (!TBaseHelper.equalsNobinary(this.cluster, that.cluster)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetLog_str(), that.isSetLog_str(), this.log_str, that.log_str)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {cluster, log_str}); + } + + @Override + public int compareTo(LogEntry other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCluster()).compareTo(other.isSetCluster()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(cluster, other.cluster); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetLog_str()).compareTo(other.isSetLog_str()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(log_str, other.log_str); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CLUSTER: + if (__field.type == TType.I64) { + this.cluster = iprot.readI64(); + setClusterIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LOG_STR: + if (__field.type == TType.STRING) { + this.log_str = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(CLUSTER_FIELD_DESC); + oprot.writeI64(this.cluster); + oprot.writeFieldEnd(); + if (this.log_str != null) { + oprot.writeFieldBegin(LOG_STR_FIELD_DESC); + oprot.writeBinary(this.log_str); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("LogEntry"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("cluster"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getCluster(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("log_str"); + sb.append(space); + sb.append(":").append(space); + if (this.getLog_str() == null) { + sb.append("null"); + } else { + int __log_str_size = Math.min(this.getLog_str().length, 128); + for (int i = 0; i < __log_str_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getLog_str()[i]).length() > 1 ? Integer.toHexString(this.getLog_str()[i]).substring(Integer.toHexString(this.getLog_str()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getLog_str()[i]).toUpperCase()); + } + if (this.getLog_str().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ExecutionResponse.java b/client/src/main/generated/com/vesoft/nebula/graph/ExecutionResponse.java index 3a538c63c..8c265d9f6 100644 --- a/client/src/main/generated/com/vesoft/nebula/graph/ExecutionResponse.java +++ b/client/src/main/generated/com/vesoft/nebula/graph/ExecutionResponse.java @@ -27,7 +27,7 @@ public class ExecutionResponse implements TBase, java.io.Serializable, Cloneable { private static final TStruct STRUCT_DESC = new TStruct("ExecutionResponse"); private static final TField ERROR_CODE_FIELD_DESC = new TField("error_code", TType.I32, (short)1); - private static final TField LATENCY_IN_US_FIELD_DESC = new TField("latency_in_us", TType.I32, (short)2); + private static final TField LATENCY_IN_US_FIELD_DESC = new TField("latency_in_us", TType.I64, (short)2); private static final TField DATA_FIELD_DESC = new TField("data", TType.STRUCT, (short)3); private static final TField SPACE_NAME_FIELD_DESC = new TField("space_name", TType.STRING, (short)4); private static final TField ERROR_MSG_FIELD_DESC = new TField("error_msg", TType.STRING, (short)5); @@ -39,7 +39,7 @@ public class ExecutionResponse implements TBase, java.io.Serializable, Cloneable * @see com.vesoft.nebula.ErrorCode */ public com.vesoft.nebula.ErrorCode error_code; - public int latency_in_us; + public long latency_in_us; public com.vesoft.nebula.DataSet data; public byte[] space_name; public byte[] error_msg; @@ -64,7 +64,7 @@ public class ExecutionResponse implements TBase, java.io.Serializable, Cloneable tmpMetaDataMap.put(ERROR_CODE, new FieldMetaData("error_code", TFieldRequirementType.REQUIRED, new FieldValueMetaData(TType.I32))); tmpMetaDataMap.put(LATENCY_IN_US, new FieldMetaData("latency_in_us", TFieldRequirementType.REQUIRED, - new FieldValueMetaData(TType.I32))); + new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(DATA, new FieldMetaData("data", TFieldRequirementType.OPTIONAL, new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); tmpMetaDataMap.put(SPACE_NAME, new FieldMetaData("space_name", TFieldRequirementType.OPTIONAL, @@ -87,7 +87,7 @@ public ExecutionResponse() { public ExecutionResponse( com.vesoft.nebula.ErrorCode error_code, - int latency_in_us) { + long latency_in_us) { this(); this.error_code = error_code; this.latency_in_us = latency_in_us; @@ -96,7 +96,7 @@ public ExecutionResponse( public ExecutionResponse( com.vesoft.nebula.ErrorCode error_code, - int latency_in_us, + long latency_in_us, com.vesoft.nebula.DataSet data, byte[] space_name, byte[] error_msg, @@ -115,7 +115,7 @@ public ExecutionResponse( public static class Builder { private com.vesoft.nebula.ErrorCode error_code; - private int latency_in_us; + private long latency_in_us; private com.vesoft.nebula.DataSet data; private byte[] space_name; private byte[] error_msg; @@ -132,7 +132,7 @@ public Builder setError_code(final com.vesoft.nebula.ErrorCode error_code) { return this; } - public Builder setLatency_in_us(final int latency_in_us) { + public Builder setLatency_in_us(final long latency_in_us) { this.latency_in_us = latency_in_us; __optional_isset.set(__LATENCY_IN_US_ISSET_ID, true); return this; @@ -245,11 +245,11 @@ public void setError_codeIsSet(boolean __value) { } } - public int getLatency_in_us() { + public long getLatency_in_us() { return this.latency_in_us; } - public ExecutionResponse setLatency_in_us(int latency_in_us) { + public ExecutionResponse setLatency_in_us(long latency_in_us) { this.latency_in_us = latency_in_us; setLatency_in_usIsSet(true); return this; @@ -402,7 +402,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetLatency_in_us(); } else { - setLatency_in_us((Integer)__value); + setLatency_in_us((Long)__value); } break; @@ -457,7 +457,7 @@ public Object getFieldValue(int fieldID) { return getError_code(); case LATENCY_IN_US: - return new Integer(getLatency_in_us()); + return new Long(getLatency_in_us()); case DATA: return getData(); @@ -530,8 +530,8 @@ public void read(TProtocol iprot) throws TException { } break; case LATENCY_IN_US: - if (__field.type == TType.I32) { - this.latency_in_us = iprot.readI32(); + if (__field.type == TType.I64) { + this.latency_in_us = iprot.readI64(); setLatency_in_usIsSet(true); } else { TProtocolUtil.skip(iprot, __field.type); @@ -600,7 +600,7 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } oprot.writeFieldBegin(LATENCY_IN_US_FIELD_DESC); - oprot.writeI32(this.latency_in_us); + oprot.writeI64(this.latency_in_us); oprot.writeFieldEnd(); if (this.data != null) { if (isSetData()) { diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java index 7dc4e4772..8f33f1678 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java @@ -267,15 +267,15 @@ public void read(TProtocol iprot) throws TException { case ZONE_NAMES: if (__field.type == TType.LIST) { { - TList _list218 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list218.size)); - for (int _i219 = 0; - (_list218.size < 0) ? iprot.peekList() : (_i219 < _list218.size); - ++_i219) + TList _list210 = iprot.readListBegin(); + this.zone_names = new ArrayList(Math.max(0, _list210.size)); + for (int _i211 = 0; + (_list210.size < 0) ? iprot.peekList() : (_i211 < _list210.size); + ++_i211) { - byte[] _elem220; - _elem220 = iprot.readBinary(); - this.zone_names.add(_elem220); + byte[] _elem212; + _elem212 = iprot.readBinary(); + this.zone_names.add(_elem212); } iprot.readListEnd(); } @@ -309,8 +309,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter221 : this.zone_names) { - oprot.writeBinary(_iter221); + for (byte[] _iter213 : this.zone_names) { + oprot.writeBinary(_iter213); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java index e9c62041d..9a8a5c6ce 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java @@ -356,16 +356,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list234 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list234.size)); - for (int _i235 = 0; - (_list234.size < 0) ? iprot.peekList() : (_i235 < _list234.size); - ++_i235) + TList _list224 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list224.size)); + for (int _i225 = 0; + (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); + ++_i225) { - com.vesoft.nebula.HostAddr _elem236; - _elem236 = new com.vesoft.nebula.HostAddr(); - _elem236.read(iprot); - this.hosts.add(_elem236); + com.vesoft.nebula.HostAddr _elem226; + _elem226 = new com.vesoft.nebula.HostAddr(); + _elem226.read(iprot); + this.hosts.add(_elem226); } iprot.readListEnd(); } @@ -402,8 +402,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter237 : this.hosts) { - _iter237.write(oprot); + for (com.vesoft.nebula.HostAddr _iter227 : this.hosts) { + _iter227.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java index 92bc14f6d..ad8c74265 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java @@ -267,16 +267,16 @@ public void read(TProtocol iprot) throws TException { case NODES: if (__field.type == TType.LIST) { { - TList _list202 = iprot.readListBegin(); - this.nodes = new ArrayList(Math.max(0, _list202.size)); - for (int _i203 = 0; - (_list202.size < 0) ? iprot.peekList() : (_i203 < _list202.size); - ++_i203) + TList _list208 = iprot.readListBegin(); + this.nodes = new ArrayList(Math.max(0, _list208.size)); + for (int _i209 = 0; + (_list208.size < 0) ? iprot.peekList() : (_i209 < _list208.size); + ++_i209) { - com.vesoft.nebula.HostAddr _elem204; - _elem204 = new com.vesoft.nebula.HostAddr(); - _elem204.read(iprot); - this.nodes.add(_elem204); + com.vesoft.nebula.HostAddr _elem210; + _elem210 = new com.vesoft.nebula.HostAddr(); + _elem210.read(iprot); + this.nodes.add(_elem210); } iprot.readListEnd(); } @@ -310,8 +310,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(NODES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.nodes.size())); - for (com.vesoft.nebula.HostAddr _iter205 : this.nodes) { - _iter205.write(oprot); + for (com.vesoft.nebula.HostAddr _iter211 : this.nodes) { + _iter211.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AdminCmd.java b/client/src/main/generated/com/vesoft/nebula/meta/AdminCmd.java index 4cd410204..7fad7f713 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AdminCmd.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AdminCmd.java @@ -22,6 +22,7 @@ public enum AdminCmd implements com.facebook.thrift.TEnum { DATA_BALANCE(6), DOWNLOAD(7), INGEST(8), + LEADER_BALANCE(9), UNKNOWN(99); private final int value; @@ -61,6 +62,8 @@ public static AdminCmd findByValue(int value) { return DOWNLOAD; case 8: return INGEST; + case 9: + return LEADER_BALANCE; case 99: return UNKNOWN; default: diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java index 1a9f68888..e1588ae80 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java @@ -268,16 +268,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list242 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list242.size)); - for (int _i243 = 0; - (_list242.size < 0) ? iprot.peekList() : (_i243 < _list242.size); - ++_i243) + TList _list232 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list232.size)); + for (int _i233 = 0; + (_list232.size < 0) ? iprot.peekList() : (_i233 < _list232.size); + ++_i233) { - com.vesoft.nebula.CheckpointInfo _elem244; - _elem244 = new com.vesoft.nebula.CheckpointInfo(); - _elem244.read(iprot); - this.info.add(_elem244); + com.vesoft.nebula.CheckpointInfo _elem234; + _elem234 = new com.vesoft.nebula.CheckpointInfo(); + _elem234.read(iprot); + this.info.add(_elem234); } iprot.readListEnd(); } @@ -311,8 +311,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter245 : this.info) { - _iter245.write(oprot); + for (com.vesoft.nebula.CheckpointInfo _iter235 : this.info) { + _iter235.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java index 96348ed68..2065c4c59 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java @@ -521,18 +521,18 @@ public void read(TProtocol iprot) throws TException { case BACKUP_INFO: if (__field.type == TType.MAP) { { - TMap _map250 = iprot.readMapBegin(); - this.backup_info = new HashMap(Math.max(0, 2*_map250.size)); - for (int _i251 = 0; - (_map250.size < 0) ? iprot.peekMap() : (_i251 < _map250.size); - ++_i251) + TMap _map240 = iprot.readMapBegin(); + this.backup_info = new HashMap(Math.max(0, 2*_map240.size)); + for (int _i241 = 0; + (_map240.size < 0) ? iprot.peekMap() : (_i241 < _map240.size); + ++_i241) { - int _key252; - SpaceBackupInfo _val253; - _key252 = iprot.readI32(); - _val253 = new SpaceBackupInfo(); - _val253.read(iprot); - this.backup_info.put(_key252, _val253); + int _key242; + SpaceBackupInfo _val243; + _key242 = iprot.readI32(); + _val243 = new SpaceBackupInfo(); + _val243.read(iprot); + this.backup_info.put(_key242, _val243); } iprot.readMapEnd(); } @@ -543,15 +543,15 @@ public void read(TProtocol iprot) throws TException { case META_FILES: if (__field.type == TType.LIST) { { - TList _list254 = iprot.readListBegin(); - this.meta_files = new ArrayList(Math.max(0, _list254.size)); - for (int _i255 = 0; - (_list254.size < 0) ? iprot.peekList() : (_i255 < _list254.size); - ++_i255) + TList _list244 = iprot.readListBegin(); + this.meta_files = new ArrayList(Math.max(0, _list244.size)); + for (int _i245 = 0; + (_list244.size < 0) ? iprot.peekList() : (_i245 < _list244.size); + ++_i245) { - byte[] _elem256; - _elem256 = iprot.readBinary(); - this.meta_files.add(_elem256); + byte[] _elem246; + _elem246 = iprot.readBinary(); + this.meta_files.add(_elem246); } iprot.readListEnd(); } @@ -611,9 +611,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(BACKUP_INFO_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.backup_info.size())); - for (Map.Entry _iter257 : this.backup_info.entrySet()) { - oprot.writeI32(_iter257.getKey()); - _iter257.getValue().write(oprot); + for (Map.Entry _iter247 : this.backup_info.entrySet()) { + oprot.writeI32(_iter247.getKey()); + _iter247.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -623,8 +623,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(META_FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.meta_files.size())); - for (byte[] _iter258 : this.meta_files) { - oprot.writeBinary(_iter258); + for (byte[] _iter248 : this.meta_files) { + oprot.writeBinary(_iter248); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BalanceTask.java b/client/src/main/generated/com/vesoft/nebula/meta/BalanceTask.java index cf8fcf9ac..1ae5700f3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BalanceTask.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BalanceTask.java @@ -27,18 +27,30 @@ public class BalanceTask implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("BalanceTask"); private static final TField ID_FIELD_DESC = new TField("id", TType.STRING, (short)1); - private static final TField RESULT_FIELD_DESC = new TField("result", TType.I32, (short)2); + private static final TField COMMAND_FIELD_DESC = new TField("command", TType.STRING, (short)2); + private static final TField RESULT_FIELD_DESC = new TField("result", TType.I32, (short)3); + private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)4); + private static final TField STOP_TIME_FIELD_DESC = new TField("stop_time", TType.I64, (short)5); public byte[] id; + public byte[] command; /** * * @see TaskResult */ public TaskResult result; + public long start_time; + public long stop_time; public static final int ID = 1; - public static final int RESULT = 2; + public static final int COMMAND = 2; + public static final int RESULT = 3; + public static final int START_TIME = 4; + public static final int STOP_TIME = 5; // isset id assignments + private static final int __START_TIME_ISSET_ID = 0; + private static final int __STOP_TIME_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); public static final Map metaDataMap; @@ -46,8 +58,14 @@ public class BalanceTask implements TBase, java.io.Serializable, Cloneable, Comp Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(ID, new FieldMetaData("id", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(COMMAND, new FieldMetaData("command", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(START_TIME, new FieldMetaData("start_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(STOP_TIME, new FieldMetaData("stop_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -60,15 +78,28 @@ public BalanceTask() { public BalanceTask( byte[] id, - TaskResult result) { + byte[] command, + TaskResult result, + long start_time, + long stop_time) { this(); this.id = id; + this.command = command; this.result = result; + this.start_time = start_time; + setStart_timeIsSet(true); + this.stop_time = stop_time; + setStop_timeIsSet(true); } public static class Builder { private byte[] id; + private byte[] command; private TaskResult result; + private long start_time; + private long stop_time; + + BitSet __optional_isset = new BitSet(2); public Builder() { } @@ -78,15 +109,39 @@ public Builder setId(final byte[] id) { return this; } + public Builder setCommand(final byte[] command) { + this.command = command; + return this; + } + public Builder setResult(final TaskResult result) { this.result = result; return this; } + public Builder setStart_time(final long start_time) { + this.start_time = start_time; + __optional_isset.set(__START_TIME_ISSET_ID, true); + return this; + } + + public Builder setStop_time(final long stop_time) { + this.stop_time = stop_time; + __optional_isset.set(__STOP_TIME_ISSET_ID, true); + return this; + } + public BalanceTask build() { BalanceTask result = new BalanceTask(); result.setId(this.id); + result.setCommand(this.command); result.setResult(this.result); + if (__optional_isset.get(__START_TIME_ISSET_ID)) { + result.setStart_time(this.start_time); + } + if (__optional_isset.get(__STOP_TIME_ISSET_ID)) { + result.setStop_time(this.stop_time); + } return result; } } @@ -99,12 +154,19 @@ public static Builder builder() { * Performs a deep copy on other. */ public BalanceTask(BalanceTask other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); if (other.isSetId()) { this.id = TBaseHelper.deepCopy(other.id); } + if (other.isSetCommand()) { + this.command = TBaseHelper.deepCopy(other.command); + } if (other.isSetResult()) { this.result = TBaseHelper.deepCopy(other.result); } + this.start_time = TBaseHelper.deepCopy(other.start_time); + this.stop_time = TBaseHelper.deepCopy(other.stop_time); } public BalanceTask deepCopy() { @@ -135,6 +197,30 @@ public void setIdIsSet(boolean __value) { } } + public byte[] getCommand() { + return this.command; + } + + public BalanceTask setCommand(byte[] command) { + this.command = command; + return this; + } + + public void unsetCommand() { + this.command = null; + } + + // Returns true if field command is set (has been assigned a value) and false otherwise + public boolean isSetCommand() { + return this.command != null; + } + + public void setCommandIsSet(boolean __value) { + if (!__value) { + this.command = null; + } + } + /** * * @see TaskResult @@ -167,6 +253,52 @@ public void setResultIsSet(boolean __value) { } } + public long getStart_time() { + return this.start_time; + } + + public BalanceTask setStart_time(long start_time) { + this.start_time = start_time; + setStart_timeIsSet(true); + return this; + } + + public void unsetStart_time() { + __isset_bit_vector.clear(__START_TIME_ISSET_ID); + } + + // Returns true if field start_time is set (has been assigned a value) and false otherwise + public boolean isSetStart_time() { + return __isset_bit_vector.get(__START_TIME_ISSET_ID); + } + + public void setStart_timeIsSet(boolean __value) { + __isset_bit_vector.set(__START_TIME_ISSET_ID, __value); + } + + public long getStop_time() { + return this.stop_time; + } + + public BalanceTask setStop_time(long stop_time) { + this.stop_time = stop_time; + setStop_timeIsSet(true); + return this; + } + + public void unsetStop_time() { + __isset_bit_vector.clear(__STOP_TIME_ISSET_ID); + } + + // Returns true if field stop_time is set (has been assigned a value) and false otherwise + public boolean isSetStop_time() { + return __isset_bit_vector.get(__STOP_TIME_ISSET_ID); + } + + public void setStop_timeIsSet(boolean __value) { + __isset_bit_vector.set(__STOP_TIME_ISSET_ID, __value); + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case ID: @@ -177,6 +309,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case COMMAND: + if (__value == null) { + unsetCommand(); + } else { + setCommand((byte[])__value); + } + break; + case RESULT: if (__value == null) { unsetResult(); @@ -185,6 +325,22 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case START_TIME: + if (__value == null) { + unsetStart_time(); + } else { + setStart_time((Long)__value); + } + break; + + case STOP_TIME: + if (__value == null) { + unsetStop_time(); + } else { + setStop_time((Long)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -195,9 +351,18 @@ public Object getFieldValue(int fieldID) { case ID: return getId(); + case COMMAND: + return getCommand(); + case RESULT: return getResult(); + case START_TIME: + return new Long(getStart_time()); + + case STOP_TIME: + return new Long(getStop_time()); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -215,14 +380,20 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetId(), that.isSetId(), this.id, that.id)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetCommand(), that.isSetCommand(), this.command, that.command)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } + if (!TBaseHelper.equalsNobinary(this.start_time, that.start_time)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.stop_time, that.stop_time)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {id, result}); + return Arrays.deepHashCode(new Object[] {id, command, result, start_time, stop_time}); } @Override @@ -245,6 +416,14 @@ public int compareTo(BalanceTask other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetCommand()).compareTo(other.isSetCommand()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(command, other.command); + if (lastComparison != 0) { + return lastComparison; + } lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult()); if (lastComparison != 0) { return lastComparison; @@ -253,6 +432,22 @@ public int compareTo(BalanceTask other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetStart_time()).compareTo(other.isSetStart_time()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(start_time, other.start_time); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStop_time()).compareTo(other.isSetStop_time()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(stop_time, other.stop_time); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -274,6 +469,13 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case COMMAND: + if (__field.type == TType.STRING) { + this.command = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; case RESULT: if (__field.type == TType.I32) { this.result = TaskResult.findByValue(iprot.readI32()); @@ -281,6 +483,22 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case START_TIME: + if (__field.type == TType.I64) { + this.start_time = iprot.readI64(); + setStart_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STOP_TIME: + if (__field.type == TType.I64) { + this.stop_time = iprot.readI64(); + setStop_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -303,11 +521,22 @@ public void write(TProtocol oprot) throws TException { oprot.writeBinary(this.id); oprot.writeFieldEnd(); } + if (this.command != null) { + oprot.writeFieldBegin(COMMAND_FIELD_DESC); + oprot.writeBinary(this.command); + oprot.writeFieldEnd(); + } if (this.result != null) { oprot.writeFieldBegin(RESULT_FIELD_DESC); oprot.writeI32(this.result == null ? 0 : this.result.getValue()); oprot.writeFieldEnd(); } + oprot.writeFieldBegin(START_TIME_FIELD_DESC); + oprot.writeI64(this.start_time); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(STOP_TIME_FIELD_DESC); + oprot.writeI64(this.stop_time); + oprot.writeFieldEnd(); oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -345,6 +574,22 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); + sb.append("command"); + sb.append(space); + sb.append(":").append(space); + if (this.getCommand() == null) { + sb.append("null"); + } else { + int __command_size = Math.min(this.getCommand().length, 128); + for (int i = 0; i < __command_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getCommand()[i]).length() > 1 ? Integer.toHexString(this.getCommand()[i]).substring(Integer.toHexString(this.getCommand()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getCommand()[i]).toUpperCase()); + } + if (this.getCommand().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); sb.append("result"); sb.append(space); sb.append(":").append(space); @@ -362,6 +607,20 @@ public String toString(int indent, boolean prettyPrint) { } } first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("start_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getStart_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("stop_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getStop_time(), indent + 1, prettyPrint)); + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java index aeff353f4..86b982e5e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java @@ -198,15 +198,15 @@ public void read(TProtocol iprot) throws TException { case SPACES: if (__field.type == TType.LIST) { { - TList _list259 = iprot.readListBegin(); - this.spaces = new ArrayList(Math.max(0, _list259.size)); - for (int _i260 = 0; - (_list259.size < 0) ? iprot.peekList() : (_i260 < _list259.size); - ++_i260) + TList _list249 = iprot.readListBegin(); + this.spaces = new ArrayList(Math.max(0, _list249.size)); + for (int _i250 = 0; + (_list249.size < 0) ? iprot.peekList() : (_i250 < _list249.size); + ++_i250) { - byte[] _elem261; - _elem261 = iprot.readBinary(); - this.spaces.add(_elem261); + byte[] _elem251; + _elem251 = iprot.readBinary(); + this.spaces.add(_elem251); } iprot.readListEnd(); } @@ -236,8 +236,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.spaces.size())); - for (byte[] _iter262 : this.spaces) { - oprot.writeBinary(_iter262); + for (byte[] _iter252 : this.spaces) { + oprot.writeBinary(_iter252); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java index 0a0c50334..ea50efe47 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java @@ -555,16 +555,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list157 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list157.size)); - for (int _i158 = 0; - (_list157.size < 0) ? iprot.peekList() : (_i158 < _list157.size); - ++_i158) + TList _list171 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list171.size)); + for (int _i172 = 0; + (_list171.size < 0) ? iprot.peekList() : (_i172 < _list171.size); + ++_i172) { - IndexFieldDef _elem159; - _elem159 = new IndexFieldDef(); - _elem159.read(iprot); - this.fields.add(_elem159); + IndexFieldDef _elem173; + _elem173 = new IndexFieldDef(); + _elem173.read(iprot); + this.fields.add(_elem173); } iprot.readListEnd(); } @@ -621,8 +621,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter160 : this.fields) { - _iter160.write(oprot); + for (IndexFieldDef _iter174 : this.fields) { + _iter174.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java index 6220fa0b3..bd1036b54 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java @@ -555,16 +555,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list149 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list149.size)); - for (int _i150 = 0; - (_list149.size < 0) ? iprot.peekList() : (_i150 < _list149.size); - ++_i150) + TList _list163 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list163.size)); + for (int _i164 = 0; + (_list163.size < 0) ? iprot.peekList() : (_i164 < _list163.size); + ++_i164) { - IndexFieldDef _elem151; - _elem151 = new IndexFieldDef(); - _elem151.read(iprot); - this.fields.add(_elem151); + IndexFieldDef _elem165; + _elem165 = new IndexFieldDef(); + _elem165.read(iprot); + this.fields.add(_elem165); } iprot.readListEnd(); } @@ -621,8 +621,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter152 : this.fields) { - _iter152.write(oprot); + for (IndexFieldDef _iter166 : this.fields) { + _iter166.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/FTClient.java b/client/src/main/generated/com/vesoft/nebula/meta/FTClient.java index 7dfbba9d5..3f55e09b8 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/FTClient.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/FTClient.java @@ -29,13 +29,16 @@ public class FTClient implements TBase, java.io.Serializable, Cloneable, Compara private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)1); private static final TField USER_FIELD_DESC = new TField("user", TType.STRING, (short)2); private static final TField PWD_FIELD_DESC = new TField("pwd", TType.STRING, (short)3); + private static final TField CONN_TYPE_FIELD_DESC = new TField("conn_type", TType.STRING, (short)4); public com.vesoft.nebula.HostAddr host; public byte[] user; public byte[] pwd; + public byte[] conn_type; public static final int HOST = 1; public static final int USER = 2; public static final int PWD = 3; + public static final int CONN_TYPE = 4; // isset id assignments @@ -49,6 +52,8 @@ public class FTClient implements TBase, java.io.Serializable, Cloneable, Compara new FieldValueMetaData(TType.STRING))); tmpMetaDataMap.put(PWD, new FieldMetaData("pwd", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(CONN_TYPE, new FieldMetaData("conn_type", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -68,17 +73,20 @@ public FTClient( public FTClient( com.vesoft.nebula.HostAddr host, byte[] user, - byte[] pwd) { + byte[] pwd, + byte[] conn_type) { this(); this.host = host; this.user = user; this.pwd = pwd; + this.conn_type = conn_type; } public static class Builder { private com.vesoft.nebula.HostAddr host; private byte[] user; private byte[] pwd; + private byte[] conn_type; public Builder() { } @@ -98,11 +106,17 @@ public Builder setPwd(final byte[] pwd) { return this; } + public Builder setConn_type(final byte[] conn_type) { + this.conn_type = conn_type; + return this; + } + public FTClient build() { FTClient result = new FTClient(); result.setHost(this.host); result.setUser(this.user); result.setPwd(this.pwd); + result.setConn_type(this.conn_type); return result; } } @@ -124,6 +138,9 @@ public FTClient(FTClient other) { if (other.isSetPwd()) { this.pwd = TBaseHelper.deepCopy(other.pwd); } + if (other.isSetConn_type()) { + this.conn_type = TBaseHelper.deepCopy(other.conn_type); + } } public FTClient deepCopy() { @@ -202,6 +219,30 @@ public void setPwdIsSet(boolean __value) { } } + public byte[] getConn_type() { + return this.conn_type; + } + + public FTClient setConn_type(byte[] conn_type) { + this.conn_type = conn_type; + return this; + } + + public void unsetConn_type() { + this.conn_type = null; + } + + // Returns true if field conn_type is set (has been assigned a value) and false otherwise + public boolean isSetConn_type() { + return this.conn_type != null; + } + + public void setConn_typeIsSet(boolean __value) { + if (!__value) { + this.conn_type = null; + } + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case HOST: @@ -228,6 +269,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case CONN_TYPE: + if (__value == null) { + unsetConn_type(); + } else { + setConn_type((byte[])__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -244,6 +293,9 @@ public Object getFieldValue(int fieldID) { case PWD: return getPwd(); + case CONN_TYPE: + return getConn_type(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -265,12 +317,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetPwd(), that.isSetPwd(), this.pwd, that.pwd)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetConn_type(), that.isSetConn_type(), this.conn_type, that.conn_type)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {host, user, pwd}); + return Arrays.deepHashCode(new Object[] {host, user, pwd, conn_type}); } @Override @@ -309,6 +363,14 @@ public int compareTo(FTClient other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetConn_type()).compareTo(other.isSetConn_type()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(conn_type, other.conn_type); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -345,6 +407,13 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case CONN_TYPE: + if (__field.type == TType.STRING) { + this.conn_type = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -381,6 +450,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } } + if (this.conn_type != null) { + if (isSetConn_type()) { + oprot.writeFieldBegin(CONN_TYPE_FIELD_DESC); + oprot.writeBinary(this.conn_type); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -449,6 +525,25 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } + if (isSetConn_type()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("conn_type"); + sb.append(space); + sb.append(":").append(space); + if (this.getConn_type() == null) { + sb.append("null"); + } else { + int __conn_type_size = Math.min(this.getConn_type().length, 128); + for (int i = 0; i < __conn_type_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getConn_type()[i]).length() > 1 ? Integer.toHexString(this.getConn_type()[i]).substring(Integer.toHexString(this.getConn_type()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getConn_type()[i]).toUpperCase()); + } + if (this.getConn_type().length > 128) sb.append(" ..."); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java index 6050baa48..48bb851ca 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java @@ -345,15 +345,15 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list279 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list279.size)); - for (int _i280 = 0; - (_list279.size < 0) ? iprot.peekList() : (_i280 < _list279.size); - ++_i280) + TList _list269 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list269.size)); + for (int _i270 = 0; + (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); + ++_i270) { - byte[] _elem281; - _elem281 = iprot.readBinary(); - this.fields.add(_elem281); + byte[] _elem271; + _elem271 = iprot.readBinary(); + this.fields.add(_elem271); } iprot.readListEnd(); } @@ -390,8 +390,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.fields.size())); - for (byte[] _iter282 : this.fields) { - oprot.writeBinary(_iter282); + for (byte[] _iter272 : this.fields) { + oprot.writeBinary(_iter272); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java index 5bebbe62c..356787301 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list186 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list186.size)); - for (int _i187 = 0; - (_list186.size < 0) ? iprot.peekList() : (_i187 < _list186.size); - ++_i187) + TList _list192 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list192.size)); + for (int _i193 = 0; + (_list192.size < 0) ? iprot.peekList() : (_i193 < _list192.size); + ++_i193) { - ConfigItem _elem188; - _elem188 = new ConfigItem(); - _elem188.read(iprot); - this.items.add(_elem188); + ConfigItem _elem194; + _elem194 = new ConfigItem(); + _elem194.read(iprot); + this.items.add(_elem194); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter189 : this.items) { - _iter189.write(oprot); + for (ConfigItem _iter195 : this.items) { + _iter195.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java index a1757fff3..83be4c9b1 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java @@ -349,15 +349,15 @@ public void read(TProtocol iprot) throws TException { case ZONE_NAMES: if (__field.type == TType.LIST) { { - TList _list222 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list222.size)); - for (int _i223 = 0; - (_list222.size < 0) ? iprot.peekList() : (_i223 < _list222.size); - ++_i223) + TList _list214 = iprot.readListBegin(); + this.zone_names = new ArrayList(Math.max(0, _list214.size)); + for (int _i215 = 0; + (_list214.size < 0) ? iprot.peekList() : (_i215 < _list214.size); + ++_i215) { - byte[] _elem224; - _elem224 = iprot.readBinary(); - this.zone_names.add(_elem224); + byte[] _elem216; + _elem216 = iprot.readBinary(); + this.zone_names.add(_elem216); } iprot.readListEnd(); } @@ -396,8 +396,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter225 : this.zone_names) { - oprot.writeBinary(_iter225); + for (byte[] _iter217 : this.zone_names) { + oprot.writeBinary(_iter217); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java index b68e90a4c..aacd4b403 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list206 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list206.size)); - for (int _i207 = 0; - (_list206.size < 0) ? iprot.peekList() : (_i207 < _list206.size); - ++_i207) + TList _list212 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list212.size)); + for (int _i213 = 0; + (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); + ++_i213) { - com.vesoft.nebula.HostAddr _elem208; - _elem208 = new com.vesoft.nebula.HostAddr(); - _elem208.read(iprot); - this.hosts.add(_elem208); + com.vesoft.nebula.HostAddr _elem214; + _elem214 = new com.vesoft.nebula.HostAddr(); + _elem214.read(iprot); + this.hosts.add(_elem214); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter209 : this.hosts) { - _iter209.write(oprot); + for (com.vesoft.nebula.HostAddr _iter215 : this.hosts) { + _iter215.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Group.java b/client/src/main/generated/com/vesoft/nebula/meta/Group.java index dad0ad82f..4dd7090c1 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Group.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Group.java @@ -267,15 +267,15 @@ public void read(TProtocol iprot) throws TException { case ZONE_NAMES: if (__field.type == TType.LIST) { { - TList _list226 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list226.size)); - for (int _i227 = 0; - (_list226.size < 0) ? iprot.peekList() : (_i227 < _list226.size); - ++_i227) + TList _list218 = iprot.readListBegin(); + this.zone_names = new ArrayList(Math.max(0, _list218.size)); + for (int _i219 = 0; + (_list218.size < 0) ? iprot.peekList() : (_i219 < _list218.size); + ++_i219) { - byte[] _elem228; - _elem228 = iprot.readBinary(); - this.zone_names.add(_elem228); + byte[] _elem220; + _elem220 = iprot.readBinary(); + this.zone_names.add(_elem220); } iprot.readListEnd(); } @@ -309,8 +309,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter229 : this.zone_names) { - oprot.writeBinary(_iter229); + for (byte[] _iter221 : this.zone_names) { + oprot.writeBinary(_iter221); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java index a3619f26b..8021c5f19 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java @@ -31,7 +31,7 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable private static final TField CLUSTER_ID_FIELD_DESC = new TField("cluster_id", TType.I64, (short)3); private static final TField LEADER_PART_IDS_FIELD_DESC = new TField("leader_partIds", TType.MAP, (short)4); private static final TField GIT_INFO_SHA_FIELD_DESC = new TField("git_info_sha", TType.STRING, (short)5); - private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)6); + private static final TField DISK_PARTS_FIELD_DESC = new TField("disk_parts", TType.MAP, (short)6); /** * @@ -42,13 +42,13 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable public long cluster_id; public Map> leader_partIds; public byte[] git_info_sha; - public byte[] version; + public Map> disk_parts; public static final int ROLE = 1; public static final int HOST = 2; public static final int CLUSTER_ID = 3; public static final int LEADER_PARTIDS = 4; public static final int GIT_INFO_SHA = 5; - public static final int VERSION = 6; + public static final int DISK_PARTS = 6; // isset id assignments private static final int __CLUSTER_ID_ISSET_ID = 0; @@ -71,8 +71,12 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable new StructMetaData(TType.STRUCT, LeaderInfo.class))))); tmpMetaDataMap.put(GIT_INFO_SHA, new FieldMetaData("git_info_sha", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(DISK_PARTS, new FieldMetaData("disk_parts", TFieldRequirementType.OPTIONAL, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, PartitionList.class))))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -102,7 +106,7 @@ public HBReq( long cluster_id, Map> leader_partIds, byte[] git_info_sha, - byte[] version) { + Map> disk_parts) { this(); this.role = role; this.host = host; @@ -110,7 +114,7 @@ public HBReq( setCluster_idIsSet(true); this.leader_partIds = leader_partIds; this.git_info_sha = git_info_sha; - this.version = version; + this.disk_parts = disk_parts; } public static class Builder { @@ -119,7 +123,7 @@ public static class Builder { private long cluster_id; private Map> leader_partIds; private byte[] git_info_sha; - private byte[] version; + private Map> disk_parts; BitSet __optional_isset = new BitSet(1); @@ -152,8 +156,8 @@ public Builder setGit_info_sha(final byte[] git_info_sha) { return this; } - public Builder setVersion(final byte[] version) { - this.version = version; + public Builder setDisk_parts(final Map> disk_parts) { + this.disk_parts = disk_parts; return this; } @@ -166,7 +170,7 @@ public HBReq build() { } result.setLeader_partIds(this.leader_partIds); result.setGit_info_sha(this.git_info_sha); - result.setVersion(this.version); + result.setDisk_parts(this.disk_parts); return result; } } @@ -194,8 +198,8 @@ public HBReq(HBReq other) { if (other.isSetGit_info_sha()) { this.git_info_sha = TBaseHelper.deepCopy(other.git_info_sha); } - if (other.isSetVersion()) { - this.version = TBaseHelper.deepCopy(other.version); + if (other.isSetDisk_parts()) { + this.disk_parts = TBaseHelper.deepCopy(other.disk_parts); } } @@ -330,27 +334,27 @@ public void setGit_info_shaIsSet(boolean __value) { } } - public byte[] getVersion() { - return this.version; + public Map> getDisk_parts() { + return this.disk_parts; } - public HBReq setVersion(byte[] version) { - this.version = version; + public HBReq setDisk_parts(Map> disk_parts) { + this.disk_parts = disk_parts; return this; } - public void unsetVersion() { - this.version = null; + public void unsetDisk_parts() { + this.disk_parts = null; } - // Returns true if field version is set (has been assigned a value) and false otherwise - public boolean isSetVersion() { - return this.version != null; + // Returns true if field disk_parts is set (has been assigned a value) and false otherwise + public boolean isSetDisk_parts() { + return this.disk_parts != null; } - public void setVersionIsSet(boolean __value) { + public void setDisk_partsIsSet(boolean __value) { if (!__value) { - this.version = null; + this.disk_parts = null; } } @@ -397,11 +401,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case VERSION: + case DISK_PARTS: if (__value == null) { - unsetVersion(); + unsetDisk_parts(); } else { - setVersion((byte[])__value); + setDisk_parts((Map>)__value); } break; @@ -427,8 +431,8 @@ public Object getFieldValue(int fieldID) { case GIT_INFO_SHA: return getGit_info_sha(); - case VERSION: - return getVersion(); + case DISK_PARTS: + return getDisk_parts(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -455,14 +459,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetGit_info_sha(), that.isSetGit_info_sha(), this.git_info_sha, that.git_info_sha)) { return false; } - if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetDisk_parts(), that.isSetDisk_parts(), this.disk_parts, that.disk_parts)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {role, host, cluster_id, leader_partIds, git_info_sha, version}); + return Arrays.deepHashCode(new Object[] {role, host, cluster_id, leader_partIds, git_info_sha, disk_parts}); } @Override @@ -517,11 +521,11 @@ public int compareTo(HBReq other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + lastComparison = Boolean.valueOf(isSetDisk_parts()).compareTo(other.isSetDisk_parts()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(version, other.version); + lastComparison = TBaseHelper.compareTo(disk_parts, other.disk_parts); if (lastComparison != 0) { return lastComparison; } @@ -565,30 +569,30 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTIDS: if (__field.type == TType.MAP) { { - TMap _map140 = iprot.readMapBegin(); - this.leader_partIds = new HashMap>(Math.max(0, 2*_map140.size)); - for (int _i141 = 0; - (_map140.size < 0) ? iprot.peekMap() : (_i141 < _map140.size); - ++_i141) + TMap _map144 = iprot.readMapBegin(); + this.leader_partIds = new HashMap>(Math.max(0, 2*_map144.size)); + for (int _i145 = 0; + (_map144.size < 0) ? iprot.peekMap() : (_i145 < _map144.size); + ++_i145) { - int _key142; - List _val143; - _key142 = iprot.readI32(); + int _key146; + List _val147; + _key146 = iprot.readI32(); { - TList _list144 = iprot.readListBegin(); - _val143 = new ArrayList(Math.max(0, _list144.size)); - for (int _i145 = 0; - (_list144.size < 0) ? iprot.peekList() : (_i145 < _list144.size); - ++_i145) + TList _list148 = iprot.readListBegin(); + _val147 = new ArrayList(Math.max(0, _list148.size)); + for (int _i149 = 0; + (_list148.size < 0) ? iprot.peekList() : (_i149 < _list148.size); + ++_i149) { - LeaderInfo _elem146; - _elem146 = new LeaderInfo(); - _elem146.read(iprot); - _val143.add(_elem146); + LeaderInfo _elem150; + _elem150 = new LeaderInfo(); + _elem150.read(iprot); + _val147.add(_elem150); } iprot.readListEnd(); } - this.leader_partIds.put(_key142, _val143); + this.leader_partIds.put(_key146, _val147); } iprot.readMapEnd(); } @@ -603,9 +607,38 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case VERSION: - if (__field.type == TType.STRING) { - this.version = iprot.readBinary(); + case DISK_PARTS: + if (__field.type == TType.MAP) { + { + TMap _map151 = iprot.readMapBegin(); + this.disk_parts = new HashMap>(Math.max(0, 2*_map151.size)); + for (int _i152 = 0; + (_map151.size < 0) ? iprot.peekMap() : (_i152 < _map151.size); + ++_i152) + { + int _key153; + Map _val154; + _key153 = iprot.readI32(); + { + TMap _map155 = iprot.readMapBegin(); + _val154 = new HashMap(Math.max(0, 2*_map155.size)); + for (int _i156 = 0; + (_map155.size < 0) ? iprot.peekMap() : (_i156 < _map155.size); + ++_i156) + { + byte[] _key157; + PartitionList _val158; + _key157 = iprot.readBinary(); + _val158 = new PartitionList(); + _val158.read(iprot); + _val154.put(_key157, _val158); + } + iprot.readMapEnd(); + } + this.disk_parts.put(_key153, _val154); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -645,12 +678,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PART_IDS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.leader_partIds.size())); - for (Map.Entry> _iter147 : this.leader_partIds.entrySet()) { - oprot.writeI32(_iter147.getKey()); + for (Map.Entry> _iter159 : this.leader_partIds.entrySet()) { + oprot.writeI32(_iter159.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter147.getValue().size())); - for (LeaderInfo _iter148 : _iter147.getValue()) { - _iter148.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter159.getValue().size())); + for (LeaderInfo _iter160 : _iter159.getValue()) { + _iter160.write(oprot); } oprot.writeListEnd(); } @@ -665,10 +698,24 @@ public void write(TProtocol oprot) throws TException { oprot.writeBinary(this.git_info_sha); oprot.writeFieldEnd(); } - if (this.version != null) { - if (isSetVersion()) { - oprot.writeFieldBegin(VERSION_FIELD_DESC); - oprot.writeBinary(this.version); + if (this.disk_parts != null) { + if (isSetDisk_parts()) { + oprot.writeFieldBegin(DISK_PARTS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.MAP, this.disk_parts.size())); + for (Map.Entry> _iter161 : this.disk_parts.entrySet()) { + oprot.writeI32(_iter161.getKey()); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, _iter161.getValue().size())); + for (Map.Entry _iter162 : _iter161.getValue().entrySet()) { + oprot.writeBinary(_iter162.getKey()); + _iter162.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + } + oprot.writeMapEnd(); + } oprot.writeFieldEnd(); } } @@ -758,22 +805,17 @@ public String toString(int indent, boolean prettyPrint) { if (this.getGit_info_sha().length > 128) sb.append(" ..."); } first = false; - if (isSetVersion()) + if (isSetDisk_parts()) { if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("version"); + sb.append("disk_parts"); sb.append(space); sb.append(":").append(space); - if (this.getVersion() == null) { + if (this.getDisk_parts() == null) { sb.append("null"); } else { - int __version_size = Math.min(this.getVersion().length, 128); - for (int i = 0; i < __version_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); - } - if (this.getVersion().length > 128) sb.append(" ..."); + sb.append(TBaseHelper.toString(this.getDisk_parts(), indent + 1, prettyPrint)); } first = false; } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java b/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java new file mode 100644 index 000000000..6b68dd756 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java @@ -0,0 +1,454 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class IndexParams implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("IndexParams"); + private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)1); + private static final TField S2_MAX_LEVEL_FIELD_DESC = new TField("s2_max_level", TType.I32, (short)2); + private static final TField S2_MAX_CELLS_FIELD_DESC = new TField("s2_max_cells", TType.I32, (short)3); + + public byte[] comment; + public int s2_max_level; + public int s2_max_cells; + public static final int COMMENT = 1; + public static final int S2_MAX_LEVEL = 2; + public static final int S2_MAX_CELLS = 3; + + // isset id assignments + private static final int __S2_MAX_LEVEL_ISSET_ID = 0; + private static final int __S2_MAX_CELLS_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(S2_MAX_LEVEL, new FieldMetaData("s2_max_level", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(S2_MAX_CELLS, new FieldMetaData("s2_max_cells", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(IndexParams.class, metaDataMap); + } + + public IndexParams() { + } + + public IndexParams( + byte[] comment, + int s2_max_level, + int s2_max_cells) { + this(); + this.comment = comment; + this.s2_max_level = s2_max_level; + setS2_max_levelIsSet(true); + this.s2_max_cells = s2_max_cells; + setS2_max_cellsIsSet(true); + } + + public static class Builder { + private byte[] comment; + private int s2_max_level; + private int s2_max_cells; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setComment(final byte[] comment) { + this.comment = comment; + return this; + } + + public Builder setS2_max_level(final int s2_max_level) { + this.s2_max_level = s2_max_level; + __optional_isset.set(__S2_MAX_LEVEL_ISSET_ID, true); + return this; + } + + public Builder setS2_max_cells(final int s2_max_cells) { + this.s2_max_cells = s2_max_cells; + __optional_isset.set(__S2_MAX_CELLS_ISSET_ID, true); + return this; + } + + public IndexParams build() { + IndexParams result = new IndexParams(); + result.setComment(this.comment); + if (__optional_isset.get(__S2_MAX_LEVEL_ISSET_ID)) { + result.setS2_max_level(this.s2_max_level); + } + if (__optional_isset.get(__S2_MAX_CELLS_ISSET_ID)) { + result.setS2_max_cells(this.s2_max_cells); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public IndexParams(IndexParams other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + if (other.isSetComment()) { + this.comment = TBaseHelper.deepCopy(other.comment); + } + this.s2_max_level = TBaseHelper.deepCopy(other.s2_max_level); + this.s2_max_cells = TBaseHelper.deepCopy(other.s2_max_cells); + } + + public IndexParams deepCopy() { + return new IndexParams(this); + } + + public byte[] getComment() { + return this.comment; + } + + public IndexParams setComment(byte[] comment) { + this.comment = comment; + return this; + } + + public void unsetComment() { + this.comment = null; + } + + // Returns true if field comment is set (has been assigned a value) and false otherwise + public boolean isSetComment() { + return this.comment != null; + } + + public void setCommentIsSet(boolean __value) { + if (!__value) { + this.comment = null; + } + } + + public int getS2_max_level() { + return this.s2_max_level; + } + + public IndexParams setS2_max_level(int s2_max_level) { + this.s2_max_level = s2_max_level; + setS2_max_levelIsSet(true); + return this; + } + + public void unsetS2_max_level() { + __isset_bit_vector.clear(__S2_MAX_LEVEL_ISSET_ID); + } + + // Returns true if field s2_max_level is set (has been assigned a value) and false otherwise + public boolean isSetS2_max_level() { + return __isset_bit_vector.get(__S2_MAX_LEVEL_ISSET_ID); + } + + public void setS2_max_levelIsSet(boolean __value) { + __isset_bit_vector.set(__S2_MAX_LEVEL_ISSET_ID, __value); + } + + public int getS2_max_cells() { + return this.s2_max_cells; + } + + public IndexParams setS2_max_cells(int s2_max_cells) { + this.s2_max_cells = s2_max_cells; + setS2_max_cellsIsSet(true); + return this; + } + + public void unsetS2_max_cells() { + __isset_bit_vector.clear(__S2_MAX_CELLS_ISSET_ID); + } + + // Returns true if field s2_max_cells is set (has been assigned a value) and false otherwise + public boolean isSetS2_max_cells() { + return __isset_bit_vector.get(__S2_MAX_CELLS_ISSET_ID); + } + + public void setS2_max_cellsIsSet(boolean __value) { + __isset_bit_vector.set(__S2_MAX_CELLS_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case COMMENT: + if (__value == null) { + unsetComment(); + } else { + setComment((byte[])__value); + } + break; + + case S2_MAX_LEVEL: + if (__value == null) { + unsetS2_max_level(); + } else { + setS2_max_level((Integer)__value); + } + break; + + case S2_MAX_CELLS: + if (__value == null) { + unsetS2_max_cells(); + } else { + setS2_max_cells((Integer)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case COMMENT: + return getComment(); + + case S2_MAX_LEVEL: + return new Integer(getS2_max_level()); + + case S2_MAX_CELLS: + return new Integer(getS2_max_cells()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof IndexParams)) + return false; + IndexParams that = (IndexParams)_that; + + if (!TBaseHelper.equalsSlow(this.isSetComment(), that.isSetComment(), this.comment, that.comment)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetS2_max_level(), that.isSetS2_max_level(), this.s2_max_level, that.s2_max_level)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetS2_max_cells(), that.isSetS2_max_cells(), this.s2_max_cells, that.s2_max_cells)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {comment, s2_max_level, s2_max_cells}); + } + + @Override + public int compareTo(IndexParams other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetComment()).compareTo(other.isSetComment()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(comment, other.comment); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetS2_max_level()).compareTo(other.isSetS2_max_level()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(s2_max_level, other.s2_max_level); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetS2_max_cells()).compareTo(other.isSetS2_max_cells()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(s2_max_cells, other.s2_max_cells); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case COMMENT: + if (__field.type == TType.STRING) { + this.comment = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case S2_MAX_LEVEL: + if (__field.type == TType.I32) { + this.s2_max_level = iprot.readI32(); + setS2_max_levelIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case S2_MAX_CELLS: + if (__field.type == TType.I32) { + this.s2_max_cells = iprot.readI32(); + setS2_max_cellsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.comment != null) { + if (isSetComment()) { + oprot.writeFieldBegin(COMMENT_FIELD_DESC); + oprot.writeBinary(this.comment); + oprot.writeFieldEnd(); + } + } + if (isSetS2_max_level()) { + oprot.writeFieldBegin(S2_MAX_LEVEL_FIELD_DESC); + oprot.writeI32(this.s2_max_level); + oprot.writeFieldEnd(); + } + if (isSetS2_max_cells()) { + oprot.writeFieldBegin(S2_MAX_CELLS_FIELD_DESC); + oprot.writeI32(this.s2_max_cells); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("IndexParams"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + if (isSetComment()) + { + sb.append(indentStr); + sb.append("comment"); + sb.append(space); + sb.append(":").append(space); + if (this.getComment() == null) { + sb.append("null"); + } else { + int __comment_size = Math.min(this.getComment().length, 128); + for (int i = 0; i < __comment_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getComment()[i]).length() > 1 ? Integer.toHexString(this.getComment()[i]).substring(Integer.toHexString(this.getComment()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getComment()[i]).toUpperCase()); + } + if (this.getComment().length > 128) sb.append(" ..."); + } + first = false; + } + if (isSetS2_max_level()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("s2_max_level"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getS2_max_level(), indent + 1, prettyPrint)); + first = false; + } + if (isSetS2_max_cells()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("s2_max_cells"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getS2_max_cells(), indent + 1, prettyPrint)); + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java index 1e217fb6b..5b9b80d2e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java @@ -200,29 +200,29 @@ public void read(TProtocol iprot) throws TException { case KILL_QUERIES: if (__field.type == TType.MAP) { { - TMap _map316 = iprot.readMapBegin(); - this.kill_queries = new HashMap>(Math.max(0, 2*_map316.size)); - for (int _i317 = 0; - (_map316.size < 0) ? iprot.peekMap() : (_i317 < _map316.size); - ++_i317) + TMap _map306 = iprot.readMapBegin(); + this.kill_queries = new HashMap>(Math.max(0, 2*_map306.size)); + for (int _i307 = 0; + (_map306.size < 0) ? iprot.peekMap() : (_i307 < _map306.size); + ++_i307) { - long _key318; - Set _val319; - _key318 = iprot.readI64(); + long _key308; + Set _val309; + _key308 = iprot.readI64(); { - TSet _set320 = iprot.readSetBegin(); - _val319 = new HashSet(Math.max(0, 2*_set320.size)); - for (int _i321 = 0; - (_set320.size < 0) ? iprot.peekSet() : (_i321 < _set320.size); - ++_i321) + TSet _set310 = iprot.readSetBegin(); + _val309 = new HashSet(Math.max(0, 2*_set310.size)); + for (int _i311 = 0; + (_set310.size < 0) ? iprot.peekSet() : (_i311 < _set310.size); + ++_i311) { - long _elem322; - _elem322 = iprot.readI64(); - _val319.add(_elem322); + long _elem312; + _elem312 = iprot.readI64(); + _val309.add(_elem312); } iprot.readSetEnd(); } - this.kill_queries.put(_key318, _val319); + this.kill_queries.put(_key308, _val309); } iprot.readMapEnd(); } @@ -251,12 +251,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILL_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.SET, this.kill_queries.size())); - for (Map.Entry> _iter323 : this.kill_queries.entrySet()) { - oprot.writeI64(_iter323.getKey()); + for (Map.Entry> _iter313 : this.kill_queries.entrySet()) { + oprot.writeI64(_iter313.getKey()); { - oprot.writeSetBegin(new TSet(TType.I64, _iter323.getValue().size())); - for (long _iter324 : _iter323.getValue()) { - oprot.writeI64(_iter324); + oprot.writeSetBegin(new TSet(TType.I64, _iter313.getValue().size())); + for (long _iter314 : _iter313.getValue()) { + oprot.writeI64(_iter314); } oprot.writeSetEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java index b36692e5b..0692221f0 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java @@ -412,16 +412,16 @@ public void read(TProtocol iprot) throws TException { case META_SERVERS: if (__field.type == TType.LIST) { { - TList _list325 = iprot.readListBegin(); - this.meta_servers = new ArrayList(Math.max(0, _list325.size)); - for (int _i326 = 0; - (_list325.size < 0) ? iprot.peekList() : (_i326 < _list325.size); - ++_i326) + TList _list315 = iprot.readListBegin(); + this.meta_servers = new ArrayList(Math.max(0, _list315.size)); + for (int _i316 = 0; + (_list315.size < 0) ? iprot.peekList() : (_i316 < _list315.size); + ++_i316) { - com.vesoft.nebula.HostAddr _elem327; - _elem327 = new com.vesoft.nebula.HostAddr(); - _elem327.read(iprot); - this.meta_servers.add(_elem327); + com.vesoft.nebula.HostAddr _elem317; + _elem317 = new com.vesoft.nebula.HostAddr(); + _elem317.read(iprot); + this.meta_servers.add(_elem317); } iprot.readListEnd(); } @@ -432,16 +432,16 @@ public void read(TProtocol iprot) throws TException { case STORAGE_SERVERS: if (__field.type == TType.LIST) { { - TList _list328 = iprot.readListBegin(); - this.storage_servers = new ArrayList(Math.max(0, _list328.size)); - for (int _i329 = 0; - (_list328.size < 0) ? iprot.peekList() : (_i329 < _list328.size); - ++_i329) + TList _list318 = iprot.readListBegin(); + this.storage_servers = new ArrayList(Math.max(0, _list318.size)); + for (int _i319 = 0; + (_list318.size < 0) ? iprot.peekList() : (_i319 < _list318.size); + ++_i319) { - com.vesoft.nebula.NodeInfo _elem330; - _elem330 = new com.vesoft.nebula.NodeInfo(); - _elem330.read(iprot); - this.storage_servers.add(_elem330); + com.vesoft.nebula.NodeInfo _elem320; + _elem320 = new com.vesoft.nebula.NodeInfo(); + _elem320.read(iprot); + this.storage_servers.add(_elem320); } iprot.readListEnd(); } @@ -480,8 +480,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(META_SERVERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.meta_servers.size())); - for (com.vesoft.nebula.HostAddr _iter331 : this.meta_servers) { - _iter331.write(oprot); + for (com.vesoft.nebula.HostAddr _iter321 : this.meta_servers) { + _iter321.write(oprot); } oprot.writeListEnd(); } @@ -491,8 +491,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STORAGE_SERVERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.storage_servers.size())); - for (com.vesoft.nebula.NodeInfo _iter332 : this.storage_servers) { - _iter332.write(oprot); + for (com.vesoft.nebula.NodeInfo _iter322 : this.storage_servers) { + _iter322.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java index 72ea27d8b..38451aca5 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list190 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list190.size)); - for (int _i191 = 0; - (_list190.size < 0) ? iprot.peekList() : (_i191 < _list190.size); - ++_i191) + TList _list196 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list196.size)); + for (int _i197 = 0; + (_list196.size < 0) ? iprot.peekList() : (_i197 < _list196.size); + ++_i197) { - ConfigItem _elem192; - _elem192 = new ConfigItem(); - _elem192.read(iprot); - this.items.add(_elem192); + ConfigItem _elem198; + _elem198 = new ConfigItem(); + _elem198.read(iprot); + this.items.add(_elem198); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter193 : this.items) { - _iter193.write(oprot); + for (ConfigItem _iter199 : this.items) { + _iter199.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java index f5ab1538e..7f434d14a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list161 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list161.size)); - for (int _i162 = 0; - (_list161.size < 0) ? iprot.peekList() : (_i162 < _list161.size); - ++_i162) + TList _list175 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list175.size)); + for (int _i176 = 0; + (_list175.size < 0) ? iprot.peekList() : (_i176 < _list175.size); + ++_i176) { - IndexItem _elem163; - _elem163 = new IndexItem(); - _elem163.read(iprot); - this.items.add(_elem163); + IndexItem _elem177; + _elem177 = new IndexItem(); + _elem177.read(iprot); + this.items.add(_elem177); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter164 : this.items) { - _iter164.write(oprot); + for (IndexItem _iter178 : this.items) { + _iter178.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java index e635736be..3f87699e1 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list275 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list275.size)); - for (int _i276 = 0; - (_list275.size < 0) ? iprot.peekList() : (_i276 < _list275.size); - ++_i276) + TList _list265 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list265.size)); + for (int _i266 = 0; + (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); + ++_i266) { - FTClient _elem277; - _elem277 = new FTClient(); - _elem277.read(iprot); - this.clients.add(_elem277); + FTClient _elem267; + _elem267 = new FTClient(); + _elem267.read(iprot); + this.clients.add(_elem267); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter278 : this.clients) { - _iter278.write(oprot); + for (FTClient _iter268 : this.clients) { + _iter268.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java index 7da068dd9..4d4bfa55e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java @@ -350,18 +350,18 @@ public void read(TProtocol iprot) throws TException { case INDEXES: if (__field.type == TType.MAP) { { - TMap _map283 = iprot.readMapBegin(); - this.indexes = new HashMap(Math.max(0, 2*_map283.size)); - for (int _i284 = 0; - (_map283.size < 0) ? iprot.peekMap() : (_i284 < _map283.size); - ++_i284) + TMap _map273 = iprot.readMapBegin(); + this.indexes = new HashMap(Math.max(0, 2*_map273.size)); + for (int _i274 = 0; + (_map273.size < 0) ? iprot.peekMap() : (_i274 < _map273.size); + ++_i274) { - byte[] _key285; - FTIndex _val286; - _key285 = iprot.readBinary(); - _val286 = new FTIndex(); - _val286.read(iprot); - this.indexes.put(_key285, _val286); + byte[] _key275; + FTIndex _val276; + _key275 = iprot.readBinary(); + _val276 = new FTIndex(); + _val276.read(iprot); + this.indexes.put(_key275, _val276); } iprot.readMapEnd(); } @@ -400,9 +400,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INDEXES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.indexes.size())); - for (Map.Entry _iter287 : this.indexes.entrySet()) { - oprot.writeBinary(_iter287.getKey()); - _iter287.getValue().write(oprot); + for (Map.Entry _iter277 : this.indexes.entrySet()) { + oprot.writeBinary(_iter277.getKey()); + _iter277.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java index c0e46c967..c7ddca52f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case GROUPS: if (__field.type == TType.LIST) { { - TList _list230 = iprot.readListBegin(); - this.groups = new ArrayList(Math.max(0, _list230.size)); - for (int _i231 = 0; - (_list230.size < 0) ? iprot.peekList() : (_i231 < _list230.size); - ++_i231) + TList _list222 = iprot.readListBegin(); + this.groups = new ArrayList(Math.max(0, _list222.size)); + for (int _i223 = 0; + (_list222.size < 0) ? iprot.peekList() : (_i223 < _list222.size); + ++_i223) { - Group _elem232; - _elem232 = new Group(); - _elem232.read(iprot); - this.groups.add(_elem232); + Group _elem224; + _elem224 = new Group(); + _elem224.read(iprot); + this.groups.add(_elem224); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(GROUPS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.groups.size())); - for (Group _iter233 : this.groups) { - _iter233.write(oprot); + for (Group _iter225 : this.groups) { + _iter225.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java index 8373f7057..cc30b3476 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case STATUSES: if (__field.type == TType.LIST) { { - TList _list198 = iprot.readListBegin(); - this.statuses = new ArrayList(Math.max(0, _list198.size)); - for (int _i199 = 0; - (_list198.size < 0) ? iprot.peekList() : (_i199 < _list198.size); - ++_i199) + TList _list204 = iprot.readListBegin(); + this.statuses = new ArrayList(Math.max(0, _list204.size)); + for (int _i205 = 0; + (_list204.size < 0) ? iprot.peekList() : (_i205 < _list204.size); + ++_i205) { - IndexStatus _elem200; - _elem200 = new IndexStatus(); - _elem200.read(iprot); - this.statuses.add(_elem200); + IndexStatus _elem206; + _elem206 = new IndexStatus(); + _elem206.read(iprot); + this.statuses.add(_elem206); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STATUSES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.statuses.size())); - for (IndexStatus _iter201 : this.statuses) { - _iter201.write(oprot); + for (IndexStatus _iter207 : this.statuses) { + _iter207.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java index 957b1fab3..4c9359e4e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case LISTENERS: if (__field.type == TType.LIST) { { - TList _list238 = iprot.readListBegin(); - this.listeners = new ArrayList(Math.max(0, _list238.size)); - for (int _i239 = 0; - (_list238.size < 0) ? iprot.peekList() : (_i239 < _list238.size); - ++_i239) + TList _list228 = iprot.readListBegin(); + this.listeners = new ArrayList(Math.max(0, _list228.size)); + for (int _i229 = 0; + (_list228.size < 0) ? iprot.peekList() : (_i229 < _list228.size); + ++_i229) { - ListenerInfo _elem240; - _elem240 = new ListenerInfo(); - _elem240.read(iprot); - this.listeners.add(_elem240); + ListenerInfo _elem230; + _elem230 = new ListenerInfo(); + _elem230.read(iprot); + this.listeners.add(_elem230); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LISTENERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.listeners.size())); - for (ListenerInfo _iter241 : this.listeners) { - _iter241.write(oprot); + for (ListenerInfo _iter231 : this.listeners) { + _iter231.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java index 7d6e852d0..ea478aeef 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ROLES: if (__field.type == TType.LIST) { { - TList _list170 = iprot.readListBegin(); - this.roles = new ArrayList(Math.max(0, _list170.size)); - for (int _i171 = 0; - (_list170.size < 0) ? iprot.peekList() : (_i171 < _list170.size); - ++_i171) + TList _list184 = iprot.readListBegin(); + this.roles = new ArrayList(Math.max(0, _list184.size)); + for (int _i185 = 0; + (_list184.size < 0) ? iprot.peekList() : (_i185 < _list184.size); + ++_i185) { - RoleItem _elem172; - _elem172 = new RoleItem(); - _elem172.read(iprot); - this.roles.add(_elem172); + RoleItem _elem186; + _elem186 = new RoleItem(); + _elem186.read(iprot); + this.roles.add(_elem186); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ROLES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.roles.size())); - for (RoleItem _iter173 : this.roles) { - _iter173.write(oprot); + for (RoleItem _iter187 : this.roles) { + _iter187.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java index 747ff9085..7e67870a3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list312 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list312.size)); - for (int _i313 = 0; - (_list312.size < 0) ? iprot.peekList() : (_i313 < _list312.size); - ++_i313) + TList _list302 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list302.size)); + for (int _i303 = 0; + (_list302.size < 0) ? iprot.peekList() : (_i303 < _list302.size); + ++_i303) { - Session _elem314; - _elem314 = new Session(); - _elem314.read(iprot); - this.sessions.add(_elem314); + Session _elem304; + _elem304 = new Session(); + _elem304.read(iprot); + this.sessions.add(_elem304); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter315 : this.sessions) { - _iter315.write(oprot); + for (Session _iter305 : this.sessions) { + _iter305.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java index a81d9d8fb..278492ed5 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case SNAPSHOTS: if (__field.type == TType.LIST) { { - TList _list194 = iprot.readListBegin(); - this.snapshots = new ArrayList(Math.max(0, _list194.size)); - for (int _i195 = 0; - (_list194.size < 0) ? iprot.peekList() : (_i195 < _list194.size); - ++_i195) + TList _list200 = iprot.readListBegin(); + this.snapshots = new ArrayList(Math.max(0, _list200.size)); + for (int _i201 = 0; + (_list200.size < 0) ? iprot.peekList() : (_i201 < _list200.size); + ++_i201) { - Snapshot _elem196; - _elem196 = new Snapshot(); - _elem196.read(iprot); - this.snapshots.add(_elem196); + Snapshot _elem202; + _elem202 = new Snapshot(); + _elem202.read(iprot); + this.snapshots.add(_elem202); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SNAPSHOTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.snapshots.size())); - for (Snapshot _iter197 : this.snapshots) { - _iter197.write(oprot); + for (Snapshot _iter203 : this.snapshots) { + _iter203.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java index f515202b6..042054f62 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list153 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list153.size)); - for (int _i154 = 0; - (_list153.size < 0) ? iprot.peekList() : (_i154 < _list153.size); - ++_i154) + TList _list167 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list167.size)); + for (int _i168 = 0; + (_list167.size < 0) ? iprot.peekList() : (_i168 < _list167.size); + ++_i168) { - IndexItem _elem155; - _elem155 = new IndexItem(); - _elem155.read(iprot); - this.items.add(_elem155); + IndexItem _elem169; + _elem169 = new IndexItem(); + _elem169.read(iprot); + this.items.add(_elem169); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter156 : this.items) { - _iter156.write(oprot); + for (IndexItem _iter170 : this.items) { + _iter170.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java index 898c1bcdc..cae213fbf 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java @@ -350,17 +350,17 @@ public void read(TProtocol iprot) throws TException { case USERS: if (__field.type == TType.MAP) { { - TMap _map165 = iprot.readMapBegin(); - this.users = new HashMap(Math.max(0, 2*_map165.size)); - for (int _i166 = 0; - (_map165.size < 0) ? iprot.peekMap() : (_i166 < _map165.size); - ++_i166) + TMap _map179 = iprot.readMapBegin(); + this.users = new HashMap(Math.max(0, 2*_map179.size)); + for (int _i180 = 0; + (_map179.size < 0) ? iprot.peekMap() : (_i180 < _map179.size); + ++_i180) { - byte[] _key167; - byte[] _val168; - _key167 = iprot.readBinary(); - _val168 = iprot.readBinary(); - this.users.put(_key167, _val168); + byte[] _key181; + byte[] _val182; + _key181 = iprot.readBinary(); + _val182 = iprot.readBinary(); + this.users.put(_key181, _val182); } iprot.readMapEnd(); } @@ -399,9 +399,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(USERS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.users.size())); - for (Map.Entry _iter169 : this.users.entrySet()) { - oprot.writeBinary(_iter169.getKey()); - oprot.writeBinary(_iter169.getValue()); + for (Map.Entry _iter183 : this.users.entrySet()) { + oprot.writeBinary(_iter183.getKey()); + oprot.writeBinary(_iter183.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java index 0312f1aa4..b6b47f564 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ZONES: if (__field.type == TType.LIST) { { - TList _list214 = iprot.readListBegin(); - this.zones = new ArrayList(Math.max(0, _list214.size)); - for (int _i215 = 0; - (_list214.size < 0) ? iprot.peekList() : (_i215 < _list214.size); - ++_i215) + TList _list220 = iprot.readListBegin(); + this.zones = new ArrayList(Math.max(0, _list220.size)); + for (int _i221 = 0; + (_list220.size < 0) ? iprot.peekList() : (_i221 < _list220.size); + ++_i221) { - Zone _elem216; - _elem216 = new Zone(); - _elem216.read(iprot); - this.zones.add(_elem216); + Zone _elem222; + _elem222 = new Zone(); + _elem222.read(iprot); + this.zones.add(_elem222); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.zones.size())); - for (Zone _iter217 : this.zones) { - _iter217.write(oprot); + for (Zone _iter223 : this.zones) { + _iter223.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java index 818acaa9e..935646e9c 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java @@ -123,10 +123,6 @@ public interface Iface { public HBResp heartBeat(HBReq req) throws TException; - public BalanceResp balance(BalanceReq req) throws TException; - - public ExecResp leaderBalance(LeaderBalanceReq req) throws TException; - public ExecResp regConfig(RegConfigReq req) throws TException; public GetConfigResp getConfig(GetConfigReq req) throws TException; @@ -155,18 +151,6 @@ public interface Iface { public ListZonesResp listZones(ListZonesReq req) throws TException; - public ExecResp addGroup(AddGroupReq req) throws TException; - - public ExecResp dropGroup(DropGroupReq req) throws TException; - - public ExecResp addZoneIntoGroup(AddZoneIntoGroupReq req) throws TException; - - public ExecResp dropZoneFromGroup(DropZoneFromGroupReq req) throws TException; - - public GetGroupResp getGroup(GetGroupReq req) throws TException; - - public ListGroupsResp listGroups(ListGroupsReq req) throws TException; - public CreateBackupResp createBackup(CreateBackupReq req) throws TException; public ExecResp restoreMeta(RestoreMetaReq req) throws TException; @@ -307,10 +291,6 @@ public interface AsyncIface { public void heartBeat(HBReq req, AsyncMethodCallback resultHandler) throws TException; - public void balance(BalanceReq req, AsyncMethodCallback resultHandler) throws TException; - - public void leaderBalance(LeaderBalanceReq req, AsyncMethodCallback resultHandler) throws TException; - public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler) throws TException; public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler) throws TException; @@ -339,18 +319,6 @@ public interface AsyncIface { public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler) throws TException; - public void addGroup(AddGroupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void dropGroup(DropGroupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void addZoneIntoGroup(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void dropZoneFromGroup(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void getGroup(GetGroupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void listGroups(ListGroupsReq req, AsyncMethodCallback resultHandler) throws TException; - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler) throws TException; public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler) throws TException; @@ -2496,96 +2464,6 @@ public HBResp recv_heartBeat() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "heartBeat failed: unknown result"); } - public BalanceResp balance(BalanceReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.balance", null); - this.setContextStack(ctx); - send_balance(req); - return recv_balance(); - } - - public void send_balance(BalanceReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.balance", null); - oprot_.writeMessageBegin(new TMessage("balance", TMessageType.CALL, seqid_)); - balance_args args = new balance_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.balance", args); - return; - } - - public BalanceResp recv_balance() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.balance"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - balance_result result = new balance_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.balance", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "balance failed: unknown result"); - } - - public ExecResp leaderBalance(LeaderBalanceReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.leaderBalance", null); - this.setContextStack(ctx); - send_leaderBalance(req); - return recv_leaderBalance(); - } - - public void send_leaderBalance(LeaderBalanceReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.leaderBalance", null); - oprot_.writeMessageBegin(new TMessage("leaderBalance", TMessageType.CALL, seqid_)); - leaderBalance_args args = new leaderBalance_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.leaderBalance", args); - return; - } - - public ExecResp recv_leaderBalance() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.leaderBalance"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - leaderBalance_result result = new leaderBalance_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.leaderBalance", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "leaderBalance failed: unknown result"); - } - public ExecResp regConfig(RegConfigReq req) throws TException { ContextStack ctx = getContextStack("MetaService.regConfig", null); @@ -3216,276 +3094,6 @@ public ListZonesResp recv_listZones() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "listZones failed: unknown result"); } - public ExecResp addGroup(AddGroupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.addGroup", null); - this.setContextStack(ctx); - send_addGroup(req); - return recv_addGroup(); - } - - public void send_addGroup(AddGroupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.addGroup", null); - oprot_.writeMessageBegin(new TMessage("addGroup", TMessageType.CALL, seqid_)); - addGroup_args args = new addGroup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.addGroup", args); - return; - } - - public ExecResp recv_addGroup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.addGroup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - addGroup_result result = new addGroup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.addGroup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "addGroup failed: unknown result"); - } - - public ExecResp dropGroup(DropGroupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.dropGroup", null); - this.setContextStack(ctx); - send_dropGroup(req); - return recv_dropGroup(); - } - - public void send_dropGroup(DropGroupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.dropGroup", null); - oprot_.writeMessageBegin(new TMessage("dropGroup", TMessageType.CALL, seqid_)); - dropGroup_args args = new dropGroup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.dropGroup", args); - return; - } - - public ExecResp recv_dropGroup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.dropGroup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - dropGroup_result result = new dropGroup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.dropGroup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "dropGroup failed: unknown result"); - } - - public ExecResp addZoneIntoGroup(AddZoneIntoGroupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.addZoneIntoGroup", null); - this.setContextStack(ctx); - send_addZoneIntoGroup(req); - return recv_addZoneIntoGroup(); - } - - public void send_addZoneIntoGroup(AddZoneIntoGroupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.addZoneIntoGroup", null); - oprot_.writeMessageBegin(new TMessage("addZoneIntoGroup", TMessageType.CALL, seqid_)); - addZoneIntoGroup_args args = new addZoneIntoGroup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.addZoneIntoGroup", args); - return; - } - - public ExecResp recv_addZoneIntoGroup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.addZoneIntoGroup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - addZoneIntoGroup_result result = new addZoneIntoGroup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.addZoneIntoGroup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "addZoneIntoGroup failed: unknown result"); - } - - public ExecResp dropZoneFromGroup(DropZoneFromGroupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.dropZoneFromGroup", null); - this.setContextStack(ctx); - send_dropZoneFromGroup(req); - return recv_dropZoneFromGroup(); - } - - public void send_dropZoneFromGroup(DropZoneFromGroupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.dropZoneFromGroup", null); - oprot_.writeMessageBegin(new TMessage("dropZoneFromGroup", TMessageType.CALL, seqid_)); - dropZoneFromGroup_args args = new dropZoneFromGroup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.dropZoneFromGroup", args); - return; - } - - public ExecResp recv_dropZoneFromGroup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.dropZoneFromGroup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - dropZoneFromGroup_result result = new dropZoneFromGroup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.dropZoneFromGroup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "dropZoneFromGroup failed: unknown result"); - } - - public GetGroupResp getGroup(GetGroupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.getGroup", null); - this.setContextStack(ctx); - send_getGroup(req); - return recv_getGroup(); - } - - public void send_getGroup(GetGroupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.getGroup", null); - oprot_.writeMessageBegin(new TMessage("getGroup", TMessageType.CALL, seqid_)); - getGroup_args args = new getGroup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.getGroup", args); - return; - } - - public GetGroupResp recv_getGroup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.getGroup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - getGroup_result result = new getGroup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.getGroup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "getGroup failed: unknown result"); - } - - public ListGroupsResp listGroups(ListGroupsReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.listGroups", null); - this.setContextStack(ctx); - send_listGroups(req); - return recv_listGroups(); - } - - public void send_listGroups(ListGroupsReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.listGroups", null); - oprot_.writeMessageBegin(new TMessage("listGroups", TMessageType.CALL, seqid_)); - listGroups_args args = new listGroups_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.listGroups", args); - return; - } - - public ListGroupsResp recv_listGroups() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.listGroups"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - listGroups_result result = new listGroups_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.listGroups", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "listGroups failed: unknown result"); - } - public CreateBackupResp createBackup(CreateBackupReq req) throws TException { ContextStack ctx = getContextStack("MetaService.createBackup", null); @@ -4494,17 +4102,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler426) throws TException { + public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler408) throws TException { checkReady(); - createSpace_call method_call = new createSpace_call(req, resultHandler426, this, ___protocolFactory, ___transport); + createSpace_call method_call = new createSpace_call(req, resultHandler408, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpace_call extends TAsyncMethodCall { private CreateSpaceReq req; - public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler427, TAsyncClient client423, TProtocolFactory protocolFactory424, TNonblockingTransport transport425) throws TException { - super(client423, protocolFactory424, transport425, resultHandler427, false); + public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler409, TAsyncClient client405, TProtocolFactory protocolFactory406, TNonblockingTransport transport407) throws TException { + super(client405, protocolFactory406, transport407, resultHandler409, false); this.req = req; } @@ -4526,17 +4134,17 @@ public ExecResp getResult() throws TException { } } - public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler431) throws TException { + public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler413) throws TException { checkReady(); - dropSpace_call method_call = new dropSpace_call(req, resultHandler431, this, ___protocolFactory, ___transport); + dropSpace_call method_call = new dropSpace_call(req, resultHandler413, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSpace_call extends TAsyncMethodCall { private DropSpaceReq req; - public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler432, TAsyncClient client428, TProtocolFactory protocolFactory429, TNonblockingTransport transport430) throws TException { - super(client428, protocolFactory429, transport430, resultHandler432, false); + public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler414, TAsyncClient client410, TProtocolFactory protocolFactory411, TNonblockingTransport transport412) throws TException { + super(client410, protocolFactory411, transport412, resultHandler414, false); this.req = req; } @@ -4558,17 +4166,17 @@ public ExecResp getResult() throws TException { } } - public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler436) throws TException { + public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler418) throws TException { checkReady(); - getSpace_call method_call = new getSpace_call(req, resultHandler436, this, ___protocolFactory, ___transport); + getSpace_call method_call = new getSpace_call(req, resultHandler418, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSpace_call extends TAsyncMethodCall { private GetSpaceReq req; - public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler437, TAsyncClient client433, TProtocolFactory protocolFactory434, TNonblockingTransport transport435) throws TException { - super(client433, protocolFactory434, transport435, resultHandler437, false); + public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler419, TAsyncClient client415, TProtocolFactory protocolFactory416, TNonblockingTransport transport417) throws TException { + super(client415, protocolFactory416, transport417, resultHandler419, false); this.req = req; } @@ -4590,17 +4198,17 @@ public GetSpaceResp getResult() throws TException { } } - public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler441) throws TException { + public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler423) throws TException { checkReady(); - listSpaces_call method_call = new listSpaces_call(req, resultHandler441, this, ___protocolFactory, ___transport); + listSpaces_call method_call = new listSpaces_call(req, resultHandler423, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSpaces_call extends TAsyncMethodCall { private ListSpacesReq req; - public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler442, TAsyncClient client438, TProtocolFactory protocolFactory439, TNonblockingTransport transport440) throws TException { - super(client438, protocolFactory439, transport440, resultHandler442, false); + public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler424, TAsyncClient client420, TProtocolFactory protocolFactory421, TNonblockingTransport transport422) throws TException { + super(client420, protocolFactory421, transport422, resultHandler424, false); this.req = req; } @@ -4622,17 +4230,17 @@ public ListSpacesResp getResult() throws TException { } } - public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler446) throws TException { + public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler428) throws TException { checkReady(); - createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler446, this, ___protocolFactory, ___transport); + createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler428, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpaceAs_call extends TAsyncMethodCall { private CreateSpaceAsReq req; - public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler447, TAsyncClient client443, TProtocolFactory protocolFactory444, TNonblockingTransport transport445) throws TException { - super(client443, protocolFactory444, transport445, resultHandler447, false); + public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler429, TAsyncClient client425, TProtocolFactory protocolFactory426, TNonblockingTransport transport427) throws TException { + super(client425, protocolFactory426, transport427, resultHandler429, false); this.req = req; } @@ -4654,17 +4262,17 @@ public ExecResp getResult() throws TException { } } - public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler451) throws TException { + public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler433) throws TException { checkReady(); - createTag_call method_call = new createTag_call(req, resultHandler451, this, ___protocolFactory, ___transport); + createTag_call method_call = new createTag_call(req, resultHandler433, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTag_call extends TAsyncMethodCall { private CreateTagReq req; - public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler452, TAsyncClient client448, TProtocolFactory protocolFactory449, TNonblockingTransport transport450) throws TException { - super(client448, protocolFactory449, transport450, resultHandler452, false); + public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler434, TAsyncClient client430, TProtocolFactory protocolFactory431, TNonblockingTransport transport432) throws TException { + super(client430, protocolFactory431, transport432, resultHandler434, false); this.req = req; } @@ -4686,17 +4294,17 @@ public ExecResp getResult() throws TException { } } - public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler456) throws TException { + public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler438) throws TException { checkReady(); - alterTag_call method_call = new alterTag_call(req, resultHandler456, this, ___protocolFactory, ___transport); + alterTag_call method_call = new alterTag_call(req, resultHandler438, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterTag_call extends TAsyncMethodCall { private AlterTagReq req; - public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler457, TAsyncClient client453, TProtocolFactory protocolFactory454, TNonblockingTransport transport455) throws TException { - super(client453, protocolFactory454, transport455, resultHandler457, false); + public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler439, TAsyncClient client435, TProtocolFactory protocolFactory436, TNonblockingTransport transport437) throws TException { + super(client435, protocolFactory436, transport437, resultHandler439, false); this.req = req; } @@ -4718,17 +4326,17 @@ public ExecResp getResult() throws TException { } } - public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler461) throws TException { + public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler443) throws TException { checkReady(); - dropTag_call method_call = new dropTag_call(req, resultHandler461, this, ___protocolFactory, ___transport); + dropTag_call method_call = new dropTag_call(req, resultHandler443, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTag_call extends TAsyncMethodCall { private DropTagReq req; - public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler462, TAsyncClient client458, TProtocolFactory protocolFactory459, TNonblockingTransport transport460) throws TException { - super(client458, protocolFactory459, transport460, resultHandler462, false); + public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler444, TAsyncClient client440, TProtocolFactory protocolFactory441, TNonblockingTransport transport442) throws TException { + super(client440, protocolFactory441, transport442, resultHandler444, false); this.req = req; } @@ -4750,17 +4358,17 @@ public ExecResp getResult() throws TException { } } - public void getTag(GetTagReq req, AsyncMethodCallback resultHandler466) throws TException { + public void getTag(GetTagReq req, AsyncMethodCallback resultHandler448) throws TException { checkReady(); - getTag_call method_call = new getTag_call(req, resultHandler466, this, ___protocolFactory, ___transport); + getTag_call method_call = new getTag_call(req, resultHandler448, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTag_call extends TAsyncMethodCall { private GetTagReq req; - public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler467, TAsyncClient client463, TProtocolFactory protocolFactory464, TNonblockingTransport transport465) throws TException { - super(client463, protocolFactory464, transport465, resultHandler467, false); + public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler449, TAsyncClient client445, TProtocolFactory protocolFactory446, TNonblockingTransport transport447) throws TException { + super(client445, protocolFactory446, transport447, resultHandler449, false); this.req = req; } @@ -4782,17 +4390,17 @@ public GetTagResp getResult() throws TException { } } - public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler471) throws TException { + public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler453) throws TException { checkReady(); - listTags_call method_call = new listTags_call(req, resultHandler471, this, ___protocolFactory, ___transport); + listTags_call method_call = new listTags_call(req, resultHandler453, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTags_call extends TAsyncMethodCall { private ListTagsReq req; - public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler472, TAsyncClient client468, TProtocolFactory protocolFactory469, TNonblockingTransport transport470) throws TException { - super(client468, protocolFactory469, transport470, resultHandler472, false); + public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler454, TAsyncClient client450, TProtocolFactory protocolFactory451, TNonblockingTransport transport452) throws TException { + super(client450, protocolFactory451, transport452, resultHandler454, false); this.req = req; } @@ -4814,17 +4422,17 @@ public ListTagsResp getResult() throws TException { } } - public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler476) throws TException { + public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler458) throws TException { checkReady(); - createEdge_call method_call = new createEdge_call(req, resultHandler476, this, ___protocolFactory, ___transport); + createEdge_call method_call = new createEdge_call(req, resultHandler458, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdge_call extends TAsyncMethodCall { private CreateEdgeReq req; - public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler477, TAsyncClient client473, TProtocolFactory protocolFactory474, TNonblockingTransport transport475) throws TException { - super(client473, protocolFactory474, transport475, resultHandler477, false); + public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler459, TAsyncClient client455, TProtocolFactory protocolFactory456, TNonblockingTransport transport457) throws TException { + super(client455, protocolFactory456, transport457, resultHandler459, false); this.req = req; } @@ -4846,17 +4454,17 @@ public ExecResp getResult() throws TException { } } - public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler481) throws TException { + public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler463) throws TException { checkReady(); - alterEdge_call method_call = new alterEdge_call(req, resultHandler481, this, ___protocolFactory, ___transport); + alterEdge_call method_call = new alterEdge_call(req, resultHandler463, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterEdge_call extends TAsyncMethodCall { private AlterEdgeReq req; - public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler482, TAsyncClient client478, TProtocolFactory protocolFactory479, TNonblockingTransport transport480) throws TException { - super(client478, protocolFactory479, transport480, resultHandler482, false); + public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler464, TAsyncClient client460, TProtocolFactory protocolFactory461, TNonblockingTransport transport462) throws TException { + super(client460, protocolFactory461, transport462, resultHandler464, false); this.req = req; } @@ -4878,17 +4486,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler486) throws TException { + public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler468) throws TException { checkReady(); - dropEdge_call method_call = new dropEdge_call(req, resultHandler486, this, ___protocolFactory, ___transport); + dropEdge_call method_call = new dropEdge_call(req, resultHandler468, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdge_call extends TAsyncMethodCall { private DropEdgeReq req; - public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler487, TAsyncClient client483, TProtocolFactory protocolFactory484, TNonblockingTransport transport485) throws TException { - super(client483, protocolFactory484, transport485, resultHandler487, false); + public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler469, TAsyncClient client465, TProtocolFactory protocolFactory466, TNonblockingTransport transport467) throws TException { + super(client465, protocolFactory466, transport467, resultHandler469, false); this.req = req; } @@ -4910,17 +4518,17 @@ public ExecResp getResult() throws TException { } } - public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler491) throws TException { + public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler473) throws TException { checkReady(); - getEdge_call method_call = new getEdge_call(req, resultHandler491, this, ___protocolFactory, ___transport); + getEdge_call method_call = new getEdge_call(req, resultHandler473, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdge_call extends TAsyncMethodCall { private GetEdgeReq req; - public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler492, TAsyncClient client488, TProtocolFactory protocolFactory489, TNonblockingTransport transport490) throws TException { - super(client488, protocolFactory489, transport490, resultHandler492, false); + public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler474, TAsyncClient client470, TProtocolFactory protocolFactory471, TNonblockingTransport transport472) throws TException { + super(client470, protocolFactory471, transport472, resultHandler474, false); this.req = req; } @@ -4942,17 +4550,17 @@ public GetEdgeResp getResult() throws TException { } } - public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler496) throws TException { + public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler478) throws TException { checkReady(); - listEdges_call method_call = new listEdges_call(req, resultHandler496, this, ___protocolFactory, ___transport); + listEdges_call method_call = new listEdges_call(req, resultHandler478, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdges_call extends TAsyncMethodCall { private ListEdgesReq req; - public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler497, TAsyncClient client493, TProtocolFactory protocolFactory494, TNonblockingTransport transport495) throws TException { - super(client493, protocolFactory494, transport495, resultHandler497, false); + public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler479, TAsyncClient client475, TProtocolFactory protocolFactory476, TNonblockingTransport transport477) throws TException { + super(client475, protocolFactory476, transport477, resultHandler479, false); this.req = req; } @@ -4974,17 +4582,17 @@ public ListEdgesResp getResult() throws TException { } } - public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler501) throws TException { + public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler483) throws TException { checkReady(); - listHosts_call method_call = new listHosts_call(req, resultHandler501, this, ___protocolFactory, ___transport); + listHosts_call method_call = new listHosts_call(req, resultHandler483, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listHosts_call extends TAsyncMethodCall { private ListHostsReq req; - public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler502, TAsyncClient client498, TProtocolFactory protocolFactory499, TNonblockingTransport transport500) throws TException { - super(client498, protocolFactory499, transport500, resultHandler502, false); + public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler484, TAsyncClient client480, TProtocolFactory protocolFactory481, TNonblockingTransport transport482) throws TException { + super(client480, protocolFactory481, transport482, resultHandler484, false); this.req = req; } @@ -5006,17 +4614,17 @@ public ListHostsResp getResult() throws TException { } } - public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler506) throws TException { + public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler488) throws TException { checkReady(); - getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler506, this, ___protocolFactory, ___transport); + getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler488, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getPartsAlloc_call extends TAsyncMethodCall { private GetPartsAllocReq req; - public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler507, TAsyncClient client503, TProtocolFactory protocolFactory504, TNonblockingTransport transport505) throws TException { - super(client503, protocolFactory504, transport505, resultHandler507, false); + public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler489, TAsyncClient client485, TProtocolFactory protocolFactory486, TNonblockingTransport transport487) throws TException { + super(client485, protocolFactory486, transport487, resultHandler489, false); this.req = req; } @@ -5038,17 +4646,17 @@ public GetPartsAllocResp getResult() throws TException { } } - public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler511) throws TException { + public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler493) throws TException { checkReady(); - listParts_call method_call = new listParts_call(req, resultHandler511, this, ___protocolFactory, ___transport); + listParts_call method_call = new listParts_call(req, resultHandler493, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listParts_call extends TAsyncMethodCall { private ListPartsReq req; - public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler512, TAsyncClient client508, TProtocolFactory protocolFactory509, TNonblockingTransport transport510) throws TException { - super(client508, protocolFactory509, transport510, resultHandler512, false); + public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler494, TAsyncClient client490, TProtocolFactory protocolFactory491, TNonblockingTransport transport492) throws TException { + super(client490, protocolFactory491, transport492, resultHandler494, false); this.req = req; } @@ -5070,17 +4678,17 @@ public ListPartsResp getResult() throws TException { } } - public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler516) throws TException { + public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler498) throws TException { checkReady(); - multiPut_call method_call = new multiPut_call(req, resultHandler516, this, ___protocolFactory, ___transport); + multiPut_call method_call = new multiPut_call(req, resultHandler498, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiPut_call extends TAsyncMethodCall { private MultiPutReq req; - public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler517, TAsyncClient client513, TProtocolFactory protocolFactory514, TNonblockingTransport transport515) throws TException { - super(client513, protocolFactory514, transport515, resultHandler517, false); + public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler499, TAsyncClient client495, TProtocolFactory protocolFactory496, TNonblockingTransport transport497) throws TException { + super(client495, protocolFactory496, transport497, resultHandler499, false); this.req = req; } @@ -5102,17 +4710,17 @@ public ExecResp getResult() throws TException { } } - public void get(GetReq req, AsyncMethodCallback resultHandler521) throws TException { + public void get(GetReq req, AsyncMethodCallback resultHandler503) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler521, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler503, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private GetReq req; - public get_call(GetReq req, AsyncMethodCallback resultHandler522, TAsyncClient client518, TProtocolFactory protocolFactory519, TNonblockingTransport transport520) throws TException { - super(client518, protocolFactory519, transport520, resultHandler522, false); + public get_call(GetReq req, AsyncMethodCallback resultHandler504, TAsyncClient client500, TProtocolFactory protocolFactory501, TNonblockingTransport transport502) throws TException { + super(client500, protocolFactory501, transport502, resultHandler504, false); this.req = req; } @@ -5134,17 +4742,17 @@ public GetResp getResult() throws TException { } } - public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler526) throws TException { + public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler508) throws TException { checkReady(); - multiGet_call method_call = new multiGet_call(req, resultHandler526, this, ___protocolFactory, ___transport); + multiGet_call method_call = new multiGet_call(req, resultHandler508, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiGet_call extends TAsyncMethodCall { private MultiGetReq req; - public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler527, TAsyncClient client523, TProtocolFactory protocolFactory524, TNonblockingTransport transport525) throws TException { - super(client523, protocolFactory524, transport525, resultHandler527, false); + public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler509, TAsyncClient client505, TProtocolFactory protocolFactory506, TNonblockingTransport transport507) throws TException { + super(client505, protocolFactory506, transport507, resultHandler509, false); this.req = req; } @@ -5166,17 +4774,17 @@ public MultiGetResp getResult() throws TException { } } - public void remove(RemoveReq req, AsyncMethodCallback resultHandler531) throws TException { + public void remove(RemoveReq req, AsyncMethodCallback resultHandler513) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler531, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler513, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private RemoveReq req; - public remove_call(RemoveReq req, AsyncMethodCallback resultHandler532, TAsyncClient client528, TProtocolFactory protocolFactory529, TNonblockingTransport transport530) throws TException { - super(client528, protocolFactory529, transport530, resultHandler532, false); + public remove_call(RemoveReq req, AsyncMethodCallback resultHandler514, TAsyncClient client510, TProtocolFactory protocolFactory511, TNonblockingTransport transport512) throws TException { + super(client510, protocolFactory511, transport512, resultHandler514, false); this.req = req; } @@ -5198,17 +4806,17 @@ public ExecResp getResult() throws TException { } } - public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler536) throws TException { + public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler518) throws TException { checkReady(); - removeRange_call method_call = new removeRange_call(req, resultHandler536, this, ___protocolFactory, ___transport); + removeRange_call method_call = new removeRange_call(req, resultHandler518, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeRange_call extends TAsyncMethodCall { private RemoveRangeReq req; - public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler537, TAsyncClient client533, TProtocolFactory protocolFactory534, TNonblockingTransport transport535) throws TException { - super(client533, protocolFactory534, transport535, resultHandler537, false); + public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler519, TAsyncClient client515, TProtocolFactory protocolFactory516, TNonblockingTransport transport517) throws TException { + super(client515, protocolFactory516, transport517, resultHandler519, false); this.req = req; } @@ -5230,17 +4838,17 @@ public ExecResp getResult() throws TException { } } - public void scan(ScanReq req, AsyncMethodCallback resultHandler541) throws TException { + public void scan(ScanReq req, AsyncMethodCallback resultHandler523) throws TException { checkReady(); - scan_call method_call = new scan_call(req, resultHandler541, this, ___protocolFactory, ___transport); + scan_call method_call = new scan_call(req, resultHandler523, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scan_call extends TAsyncMethodCall { private ScanReq req; - public scan_call(ScanReq req, AsyncMethodCallback resultHandler542, TAsyncClient client538, TProtocolFactory protocolFactory539, TNonblockingTransport transport540) throws TException { - super(client538, protocolFactory539, transport540, resultHandler542, false); + public scan_call(ScanReq req, AsyncMethodCallback resultHandler524, TAsyncClient client520, TProtocolFactory protocolFactory521, TNonblockingTransport transport522) throws TException { + super(client520, protocolFactory521, transport522, resultHandler524, false); this.req = req; } @@ -5262,17 +4870,17 @@ public ScanResp getResult() throws TException { } } - public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler546) throws TException { + public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler528) throws TException { checkReady(); - createTagIndex_call method_call = new createTagIndex_call(req, resultHandler546, this, ___protocolFactory, ___transport); + createTagIndex_call method_call = new createTagIndex_call(req, resultHandler528, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTagIndex_call extends TAsyncMethodCall { private CreateTagIndexReq req; - public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler547, TAsyncClient client543, TProtocolFactory protocolFactory544, TNonblockingTransport transport545) throws TException { - super(client543, protocolFactory544, transport545, resultHandler547, false); + public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler529, TAsyncClient client525, TProtocolFactory protocolFactory526, TNonblockingTransport transport527) throws TException { + super(client525, protocolFactory526, transport527, resultHandler529, false); this.req = req; } @@ -5294,17 +4902,17 @@ public ExecResp getResult() throws TException { } } - public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler551) throws TException { + public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler533) throws TException { checkReady(); - dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler551, this, ___protocolFactory, ___transport); + dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler533, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTagIndex_call extends TAsyncMethodCall { private DropTagIndexReq req; - public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler552, TAsyncClient client548, TProtocolFactory protocolFactory549, TNonblockingTransport transport550) throws TException { - super(client548, protocolFactory549, transport550, resultHandler552, false); + public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler534, TAsyncClient client530, TProtocolFactory protocolFactory531, TNonblockingTransport transport532) throws TException { + super(client530, protocolFactory531, transport532, resultHandler534, false); this.req = req; } @@ -5326,17 +4934,17 @@ public ExecResp getResult() throws TException { } } - public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler556) throws TException { + public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler538) throws TException { checkReady(); - getTagIndex_call method_call = new getTagIndex_call(req, resultHandler556, this, ___protocolFactory, ___transport); + getTagIndex_call method_call = new getTagIndex_call(req, resultHandler538, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTagIndex_call extends TAsyncMethodCall { private GetTagIndexReq req; - public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler557, TAsyncClient client553, TProtocolFactory protocolFactory554, TNonblockingTransport transport555) throws TException { - super(client553, protocolFactory554, transport555, resultHandler557, false); + public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler539, TAsyncClient client535, TProtocolFactory protocolFactory536, TNonblockingTransport transport537) throws TException { + super(client535, protocolFactory536, transport537, resultHandler539, false); this.req = req; } @@ -5358,17 +4966,17 @@ public GetTagIndexResp getResult() throws TException { } } - public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler561) throws TException { + public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler543) throws TException { checkReady(); - listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler561, this, ___protocolFactory, ___transport); + listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler543, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexes_call extends TAsyncMethodCall { private ListTagIndexesReq req; - public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler562, TAsyncClient client558, TProtocolFactory protocolFactory559, TNonblockingTransport transport560) throws TException { - super(client558, protocolFactory559, transport560, resultHandler562, false); + public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler544, TAsyncClient client540, TProtocolFactory protocolFactory541, TNonblockingTransport transport542) throws TException { + super(client540, protocolFactory541, transport542, resultHandler544, false); this.req = req; } @@ -5390,17 +4998,17 @@ public ListTagIndexesResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler566) throws TException { + public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler548) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler566, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler548, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler567, TAsyncClient client563, TProtocolFactory protocolFactory564, TNonblockingTransport transport565) throws TException { - super(client563, protocolFactory564, transport565, resultHandler567, false); + public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler549, TAsyncClient client545, TProtocolFactory protocolFactory546, TNonblockingTransport transport547) throws TException { + super(client545, protocolFactory546, transport547, resultHandler549, false); this.req = req; } @@ -5422,17 +5030,17 @@ public ExecResp getResult() throws TException { } } - public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler571) throws TException { + public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler553) throws TException { checkReady(); - listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler571, this, ___protocolFactory, ___transport); + listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler553, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler572, TAsyncClient client568, TProtocolFactory protocolFactory569, TNonblockingTransport transport570) throws TException { - super(client568, protocolFactory569, transport570, resultHandler572, false); + public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler554, TAsyncClient client550, TProtocolFactory protocolFactory551, TNonblockingTransport transport552) throws TException { + super(client550, protocolFactory551, transport552, resultHandler554, false); this.req = req; } @@ -5454,17 +5062,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler576) throws TException { + public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler558) throws TException { checkReady(); - createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler576, this, ___protocolFactory, ___transport); + createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler558, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdgeIndex_call extends TAsyncMethodCall { private CreateEdgeIndexReq req; - public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler577, TAsyncClient client573, TProtocolFactory protocolFactory574, TNonblockingTransport transport575) throws TException { - super(client573, protocolFactory574, transport575, resultHandler577, false); + public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler559, TAsyncClient client555, TProtocolFactory protocolFactory556, TNonblockingTransport transport557) throws TException { + super(client555, protocolFactory556, transport557, resultHandler559, false); this.req = req; } @@ -5486,17 +5094,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler581) throws TException { + public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler563) throws TException { checkReady(); - dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler581, this, ___protocolFactory, ___transport); + dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler563, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdgeIndex_call extends TAsyncMethodCall { private DropEdgeIndexReq req; - public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler582, TAsyncClient client578, TProtocolFactory protocolFactory579, TNonblockingTransport transport580) throws TException { - super(client578, protocolFactory579, transport580, resultHandler582, false); + public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler564, TAsyncClient client560, TProtocolFactory protocolFactory561, TNonblockingTransport transport562) throws TException { + super(client560, protocolFactory561, transport562, resultHandler564, false); this.req = req; } @@ -5518,17 +5126,17 @@ public ExecResp getResult() throws TException { } } - public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler586) throws TException { + public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler568) throws TException { checkReady(); - getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler586, this, ___protocolFactory, ___transport); + getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler568, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdgeIndex_call extends TAsyncMethodCall { private GetEdgeIndexReq req; - public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler587, TAsyncClient client583, TProtocolFactory protocolFactory584, TNonblockingTransport transport585) throws TException { - super(client583, protocolFactory584, transport585, resultHandler587, false); + public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler569, TAsyncClient client565, TProtocolFactory protocolFactory566, TNonblockingTransport transport567) throws TException { + super(client565, protocolFactory566, transport567, resultHandler569, false); this.req = req; } @@ -5550,17 +5158,17 @@ public GetEdgeIndexResp getResult() throws TException { } } - public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler591) throws TException { + public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler573) throws TException { checkReady(); - listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler591, this, ___protocolFactory, ___transport); + listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler573, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexes_call extends TAsyncMethodCall { private ListEdgeIndexesReq req; - public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler592, TAsyncClient client588, TProtocolFactory protocolFactory589, TNonblockingTransport transport590) throws TException { - super(client588, protocolFactory589, transport590, resultHandler592, false); + public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler574, TAsyncClient client570, TProtocolFactory protocolFactory571, TNonblockingTransport transport572) throws TException { + super(client570, protocolFactory571, transport572, resultHandler574, false); this.req = req; } @@ -5582,17 +5190,17 @@ public ListEdgeIndexesResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler596) throws TException { + public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler578) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler596, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler578, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler597, TAsyncClient client593, TProtocolFactory protocolFactory594, TNonblockingTransport transport595) throws TException { - super(client593, protocolFactory594, transport595, resultHandler597, false); + public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler579, TAsyncClient client575, TProtocolFactory protocolFactory576, TNonblockingTransport transport577) throws TException { + super(client575, protocolFactory576, transport577, resultHandler579, false); this.req = req; } @@ -5614,17 +5222,17 @@ public ExecResp getResult() throws TException { } } - public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler601) throws TException { + public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler583) throws TException { checkReady(); - listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler601, this, ___protocolFactory, ___transport); + listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler583, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler602, TAsyncClient client598, TProtocolFactory protocolFactory599, TNonblockingTransport transport600) throws TException { - super(client598, protocolFactory599, transport600, resultHandler602, false); + public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler584, TAsyncClient client580, TProtocolFactory protocolFactory581, TNonblockingTransport transport582) throws TException { + super(client580, protocolFactory581, transport582, resultHandler584, false); this.req = req; } @@ -5646,17 +5254,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler606) throws TException { + public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler588) throws TException { checkReady(); - createUser_call method_call = new createUser_call(req, resultHandler606, this, ___protocolFactory, ___transport); + createUser_call method_call = new createUser_call(req, resultHandler588, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createUser_call extends TAsyncMethodCall { private CreateUserReq req; - public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler607, TAsyncClient client603, TProtocolFactory protocolFactory604, TNonblockingTransport transport605) throws TException { - super(client603, protocolFactory604, transport605, resultHandler607, false); + public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler589, TAsyncClient client585, TProtocolFactory protocolFactory586, TNonblockingTransport transport587) throws TException { + super(client585, protocolFactory586, transport587, resultHandler589, false); this.req = req; } @@ -5678,17 +5286,17 @@ public ExecResp getResult() throws TException { } } - public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler611) throws TException { + public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler593) throws TException { checkReady(); - dropUser_call method_call = new dropUser_call(req, resultHandler611, this, ___protocolFactory, ___transport); + dropUser_call method_call = new dropUser_call(req, resultHandler593, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropUser_call extends TAsyncMethodCall { private DropUserReq req; - public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler612, TAsyncClient client608, TProtocolFactory protocolFactory609, TNonblockingTransport transport610) throws TException { - super(client608, protocolFactory609, transport610, resultHandler612, false); + public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler594, TAsyncClient client590, TProtocolFactory protocolFactory591, TNonblockingTransport transport592) throws TException { + super(client590, protocolFactory591, transport592, resultHandler594, false); this.req = req; } @@ -5710,17 +5318,17 @@ public ExecResp getResult() throws TException { } } - public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler616) throws TException { + public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler598) throws TException { checkReady(); - alterUser_call method_call = new alterUser_call(req, resultHandler616, this, ___protocolFactory, ___transport); + alterUser_call method_call = new alterUser_call(req, resultHandler598, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterUser_call extends TAsyncMethodCall { private AlterUserReq req; - public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler617, TAsyncClient client613, TProtocolFactory protocolFactory614, TNonblockingTransport transport615) throws TException { - super(client613, protocolFactory614, transport615, resultHandler617, false); + public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler599, TAsyncClient client595, TProtocolFactory protocolFactory596, TNonblockingTransport transport597) throws TException { + super(client595, protocolFactory596, transport597, resultHandler599, false); this.req = req; } @@ -5742,17 +5350,17 @@ public ExecResp getResult() throws TException { } } - public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler621) throws TException { + public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler603) throws TException { checkReady(); - grantRole_call method_call = new grantRole_call(req, resultHandler621, this, ___protocolFactory, ___transport); + grantRole_call method_call = new grantRole_call(req, resultHandler603, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class grantRole_call extends TAsyncMethodCall { private GrantRoleReq req; - public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler622, TAsyncClient client618, TProtocolFactory protocolFactory619, TNonblockingTransport transport620) throws TException { - super(client618, protocolFactory619, transport620, resultHandler622, false); + public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler604, TAsyncClient client600, TProtocolFactory protocolFactory601, TNonblockingTransport transport602) throws TException { + super(client600, protocolFactory601, transport602, resultHandler604, false); this.req = req; } @@ -5774,17 +5382,17 @@ public ExecResp getResult() throws TException { } } - public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler626) throws TException { + public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler608) throws TException { checkReady(); - revokeRole_call method_call = new revokeRole_call(req, resultHandler626, this, ___protocolFactory, ___transport); + revokeRole_call method_call = new revokeRole_call(req, resultHandler608, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class revokeRole_call extends TAsyncMethodCall { private RevokeRoleReq req; - public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler627, TAsyncClient client623, TProtocolFactory protocolFactory624, TNonblockingTransport transport625) throws TException { - super(client623, protocolFactory624, transport625, resultHandler627, false); + public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler609, TAsyncClient client605, TProtocolFactory protocolFactory606, TNonblockingTransport transport607) throws TException { + super(client605, protocolFactory606, transport607, resultHandler609, false); this.req = req; } @@ -5806,17 +5414,17 @@ public ExecResp getResult() throws TException { } } - public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler631) throws TException { + public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler613) throws TException { checkReady(); - listUsers_call method_call = new listUsers_call(req, resultHandler631, this, ___protocolFactory, ___transport); + listUsers_call method_call = new listUsers_call(req, resultHandler613, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listUsers_call extends TAsyncMethodCall { private ListUsersReq req; - public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler632, TAsyncClient client628, TProtocolFactory protocolFactory629, TNonblockingTransport transport630) throws TException { - super(client628, protocolFactory629, transport630, resultHandler632, false); + public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler614, TAsyncClient client610, TProtocolFactory protocolFactory611, TNonblockingTransport transport612) throws TException { + super(client610, protocolFactory611, transport612, resultHandler614, false); this.req = req; } @@ -5838,17 +5446,17 @@ public ListUsersResp getResult() throws TException { } } - public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler636) throws TException { + public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler618) throws TException { checkReady(); - listRoles_call method_call = new listRoles_call(req, resultHandler636, this, ___protocolFactory, ___transport); + listRoles_call method_call = new listRoles_call(req, resultHandler618, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listRoles_call extends TAsyncMethodCall { private ListRolesReq req; - public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler637, TAsyncClient client633, TProtocolFactory protocolFactory634, TNonblockingTransport transport635) throws TException { - super(client633, protocolFactory634, transport635, resultHandler637, false); + public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler619, TAsyncClient client615, TProtocolFactory protocolFactory616, TNonblockingTransport transport617) throws TException { + super(client615, protocolFactory616, transport617, resultHandler619, false); this.req = req; } @@ -5870,17 +5478,17 @@ public ListRolesResp getResult() throws TException { } } - public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler641) throws TException { + public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler623) throws TException { checkReady(); - getUserRoles_call method_call = new getUserRoles_call(req, resultHandler641, this, ___protocolFactory, ___transport); + getUserRoles_call method_call = new getUserRoles_call(req, resultHandler623, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUserRoles_call extends TAsyncMethodCall { private GetUserRolesReq req; - public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler642, TAsyncClient client638, TProtocolFactory protocolFactory639, TNonblockingTransport transport640) throws TException { - super(client638, protocolFactory639, transport640, resultHandler642, false); + public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler624, TAsyncClient client620, TProtocolFactory protocolFactory621, TNonblockingTransport transport622) throws TException { + super(client620, protocolFactory621, transport622, resultHandler624, false); this.req = req; } @@ -5902,17 +5510,17 @@ public ListRolesResp getResult() throws TException { } } - public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler646) throws TException { + public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler628) throws TException { checkReady(); - changePassword_call method_call = new changePassword_call(req, resultHandler646, this, ___protocolFactory, ___transport); + changePassword_call method_call = new changePassword_call(req, resultHandler628, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class changePassword_call extends TAsyncMethodCall { private ChangePasswordReq req; - public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler647, TAsyncClient client643, TProtocolFactory protocolFactory644, TNonblockingTransport transport645) throws TException { - super(client643, protocolFactory644, transport645, resultHandler647, false); + public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler629, TAsyncClient client625, TProtocolFactory protocolFactory626, TNonblockingTransport transport627) throws TException { + super(client625, protocolFactory626, transport627, resultHandler629, false); this.req = req; } @@ -5934,17 +5542,17 @@ public ExecResp getResult() throws TException { } } - public void heartBeat(HBReq req, AsyncMethodCallback resultHandler651) throws TException { + public void heartBeat(HBReq req, AsyncMethodCallback resultHandler633) throws TException { checkReady(); - heartBeat_call method_call = new heartBeat_call(req, resultHandler651, this, ___protocolFactory, ___transport); + heartBeat_call method_call = new heartBeat_call(req, resultHandler633, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class heartBeat_call extends TAsyncMethodCall { private HBReq req; - public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler652, TAsyncClient client648, TProtocolFactory protocolFactory649, TNonblockingTransport transport650) throws TException { - super(client648, protocolFactory649, transport650, resultHandler652, false); + public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler634, TAsyncClient client630, TProtocolFactory protocolFactory631, TNonblockingTransport transport632) throws TException { + super(client630, protocolFactory631, transport632, resultHandler634, false); this.req = req; } @@ -5966,81 +5574,17 @@ public HBResp getResult() throws TException { } } - public void balance(BalanceReq req, AsyncMethodCallback resultHandler656) throws TException { + public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler638) throws TException { checkReady(); - balance_call method_call = new balance_call(req, resultHandler656, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class balance_call extends TAsyncMethodCall { - private BalanceReq req; - public balance_call(BalanceReq req, AsyncMethodCallback resultHandler657, TAsyncClient client653, TProtocolFactory protocolFactory654, TNonblockingTransport transport655) throws TException { - super(client653, protocolFactory654, transport655, resultHandler657, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("balance", TMessageType.CALL, 0)); - balance_args args = new balance_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public BalanceResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_balance(); - } - } - - public void leaderBalance(LeaderBalanceReq req, AsyncMethodCallback resultHandler661) throws TException { - checkReady(); - leaderBalance_call method_call = new leaderBalance_call(req, resultHandler661, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class leaderBalance_call extends TAsyncMethodCall { - private LeaderBalanceReq req; - public leaderBalance_call(LeaderBalanceReq req, AsyncMethodCallback resultHandler662, TAsyncClient client658, TProtocolFactory protocolFactory659, TNonblockingTransport transport660) throws TException { - super(client658, protocolFactory659, transport660, resultHandler662, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("leaderBalance", TMessageType.CALL, 0)); - leaderBalance_args args = new leaderBalance_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_leaderBalance(); - } - } - - public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler666) throws TException { - checkReady(); - regConfig_call method_call = new regConfig_call(req, resultHandler666, this, ___protocolFactory, ___transport); + regConfig_call method_call = new regConfig_call(req, resultHandler638, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class regConfig_call extends TAsyncMethodCall { private RegConfigReq req; - public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler667, TAsyncClient client663, TProtocolFactory protocolFactory664, TNonblockingTransport transport665) throws TException { - super(client663, protocolFactory664, transport665, resultHandler667, false); + public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler639, TAsyncClient client635, TProtocolFactory protocolFactory636, TNonblockingTransport transport637) throws TException { + super(client635, protocolFactory636, transport637, resultHandler639, false); this.req = req; } @@ -6062,17 +5606,17 @@ public ExecResp getResult() throws TException { } } - public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler671) throws TException { + public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler643) throws TException { checkReady(); - getConfig_call method_call = new getConfig_call(req, resultHandler671, this, ___protocolFactory, ___transport); + getConfig_call method_call = new getConfig_call(req, resultHandler643, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getConfig_call extends TAsyncMethodCall { private GetConfigReq req; - public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler672, TAsyncClient client668, TProtocolFactory protocolFactory669, TNonblockingTransport transport670) throws TException { - super(client668, protocolFactory669, transport670, resultHandler672, false); + public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler644, TAsyncClient client640, TProtocolFactory protocolFactory641, TNonblockingTransport transport642) throws TException { + super(client640, protocolFactory641, transport642, resultHandler644, false); this.req = req; } @@ -6094,17 +5638,17 @@ public GetConfigResp getResult() throws TException { } } - public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler676) throws TException { + public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler648) throws TException { checkReady(); - setConfig_call method_call = new setConfig_call(req, resultHandler676, this, ___protocolFactory, ___transport); + setConfig_call method_call = new setConfig_call(req, resultHandler648, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class setConfig_call extends TAsyncMethodCall { private SetConfigReq req; - public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler677, TAsyncClient client673, TProtocolFactory protocolFactory674, TNonblockingTransport transport675) throws TException { - super(client673, protocolFactory674, transport675, resultHandler677, false); + public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler649, TAsyncClient client645, TProtocolFactory protocolFactory646, TNonblockingTransport transport647) throws TException { + super(client645, protocolFactory646, transport647, resultHandler649, false); this.req = req; } @@ -6126,17 +5670,17 @@ public ExecResp getResult() throws TException { } } - public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler681) throws TException { + public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler653) throws TException { checkReady(); - listConfigs_call method_call = new listConfigs_call(req, resultHandler681, this, ___protocolFactory, ___transport); + listConfigs_call method_call = new listConfigs_call(req, resultHandler653, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listConfigs_call extends TAsyncMethodCall { private ListConfigsReq req; - public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler682, TAsyncClient client678, TProtocolFactory protocolFactory679, TNonblockingTransport transport680) throws TException { - super(client678, protocolFactory679, transport680, resultHandler682, false); + public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler654, TAsyncClient client650, TProtocolFactory protocolFactory651, TNonblockingTransport transport652) throws TException { + super(client650, protocolFactory651, transport652, resultHandler654, false); this.req = req; } @@ -6158,17 +5702,17 @@ public ListConfigsResp getResult() throws TException { } } - public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler686) throws TException { + public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler658) throws TException { checkReady(); - createSnapshot_call method_call = new createSnapshot_call(req, resultHandler686, this, ___protocolFactory, ___transport); + createSnapshot_call method_call = new createSnapshot_call(req, resultHandler658, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSnapshot_call extends TAsyncMethodCall { private CreateSnapshotReq req; - public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler687, TAsyncClient client683, TProtocolFactory protocolFactory684, TNonblockingTransport transport685) throws TException { - super(client683, protocolFactory684, transport685, resultHandler687, false); + public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler659, TAsyncClient client655, TProtocolFactory protocolFactory656, TNonblockingTransport transport657) throws TException { + super(client655, protocolFactory656, transport657, resultHandler659, false); this.req = req; } @@ -6190,17 +5734,17 @@ public ExecResp getResult() throws TException { } } - public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler691) throws TException { + public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler663) throws TException { checkReady(); - dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler691, this, ___protocolFactory, ___transport); + dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler663, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSnapshot_call extends TAsyncMethodCall { private DropSnapshotReq req; - public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler692, TAsyncClient client688, TProtocolFactory protocolFactory689, TNonblockingTransport transport690) throws TException { - super(client688, protocolFactory689, transport690, resultHandler692, false); + public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler664, TAsyncClient client660, TProtocolFactory protocolFactory661, TNonblockingTransport transport662) throws TException { + super(client660, protocolFactory661, transport662, resultHandler664, false); this.req = req; } @@ -6222,17 +5766,17 @@ public ExecResp getResult() throws TException { } } - public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler696) throws TException { + public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler668) throws TException { checkReady(); - listSnapshots_call method_call = new listSnapshots_call(req, resultHandler696, this, ___protocolFactory, ___transport); + listSnapshots_call method_call = new listSnapshots_call(req, resultHandler668, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSnapshots_call extends TAsyncMethodCall { private ListSnapshotsReq req; - public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler697, TAsyncClient client693, TProtocolFactory protocolFactory694, TNonblockingTransport transport695) throws TException { - super(client693, protocolFactory694, transport695, resultHandler697, false); + public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler669, TAsyncClient client665, TProtocolFactory protocolFactory666, TNonblockingTransport transport667) throws TException { + super(client665, protocolFactory666, transport667, resultHandler669, false); this.req = req; } @@ -6254,17 +5798,17 @@ public ListSnapshotsResp getResult() throws TException { } } - public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler701) throws TException { + public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler673) throws TException { checkReady(); - runAdminJob_call method_call = new runAdminJob_call(req, resultHandler701, this, ___protocolFactory, ___transport); + runAdminJob_call method_call = new runAdminJob_call(req, resultHandler673, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class runAdminJob_call extends TAsyncMethodCall { private AdminJobReq req; - public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler702, TAsyncClient client698, TProtocolFactory protocolFactory699, TNonblockingTransport transport700) throws TException { - super(client698, protocolFactory699, transport700, resultHandler702, false); + public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler674, TAsyncClient client670, TProtocolFactory protocolFactory671, TNonblockingTransport transport672) throws TException { + super(client670, protocolFactory671, transport672, resultHandler674, false); this.req = req; } @@ -6286,17 +5830,17 @@ public AdminJobResp getResult() throws TException { } } - public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler706) throws TException { + public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler678) throws TException { checkReady(); - addZone_call method_call = new addZone_call(req, resultHandler706, this, ___protocolFactory, ___transport); + addZone_call method_call = new addZone_call(req, resultHandler678, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addZone_call extends TAsyncMethodCall { private AddZoneReq req; - public addZone_call(AddZoneReq req, AsyncMethodCallback resultHandler707, TAsyncClient client703, TProtocolFactory protocolFactory704, TNonblockingTransport transport705) throws TException { - super(client703, protocolFactory704, transport705, resultHandler707, false); + public addZone_call(AddZoneReq req, AsyncMethodCallback resultHandler679, TAsyncClient client675, TProtocolFactory protocolFactory676, TNonblockingTransport transport677) throws TException { + super(client675, protocolFactory676, transport677, resultHandler679, false); this.req = req; } @@ -6318,17 +5862,17 @@ public ExecResp getResult() throws TException { } } - public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler711) throws TException { + public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler683) throws TException { checkReady(); - dropZone_call method_call = new dropZone_call(req, resultHandler711, this, ___protocolFactory, ___transport); + dropZone_call method_call = new dropZone_call(req, resultHandler683, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropZone_call extends TAsyncMethodCall { private DropZoneReq req; - public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler712, TAsyncClient client708, TProtocolFactory protocolFactory709, TNonblockingTransport transport710) throws TException { - super(client708, protocolFactory709, transport710, resultHandler712, false); + public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler684, TAsyncClient client680, TProtocolFactory protocolFactory681, TNonblockingTransport transport682) throws TException { + super(client680, protocolFactory681, transport682, resultHandler684, false); this.req = req; } @@ -6350,17 +5894,17 @@ public ExecResp getResult() throws TException { } } - public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler716) throws TException { + public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler688) throws TException { checkReady(); - addHostIntoZone_call method_call = new addHostIntoZone_call(req, resultHandler716, this, ___protocolFactory, ___transport); + addHostIntoZone_call method_call = new addHostIntoZone_call(req, resultHandler688, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addHostIntoZone_call extends TAsyncMethodCall { private AddHostIntoZoneReq req; - public addHostIntoZone_call(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler717, TAsyncClient client713, TProtocolFactory protocolFactory714, TNonblockingTransport transport715) throws TException { - super(client713, protocolFactory714, transport715, resultHandler717, false); + public addHostIntoZone_call(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler689, TAsyncClient client685, TProtocolFactory protocolFactory686, TNonblockingTransport transport687) throws TException { + super(client685, protocolFactory686, transport687, resultHandler689, false); this.req = req; } @@ -6382,17 +5926,17 @@ public ExecResp getResult() throws TException { } } - public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler721) throws TException { + public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler693) throws TException { checkReady(); - dropHostFromZone_call method_call = new dropHostFromZone_call(req, resultHandler721, this, ___protocolFactory, ___transport); + dropHostFromZone_call method_call = new dropHostFromZone_call(req, resultHandler693, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropHostFromZone_call extends TAsyncMethodCall { private DropHostFromZoneReq req; - public dropHostFromZone_call(DropHostFromZoneReq req, AsyncMethodCallback resultHandler722, TAsyncClient client718, TProtocolFactory protocolFactory719, TNonblockingTransport transport720) throws TException { - super(client718, protocolFactory719, transport720, resultHandler722, false); + public dropHostFromZone_call(DropHostFromZoneReq req, AsyncMethodCallback resultHandler694, TAsyncClient client690, TProtocolFactory protocolFactory691, TNonblockingTransport transport692) throws TException { + super(client690, protocolFactory691, transport692, resultHandler694, false); this.req = req; } @@ -6414,17 +5958,17 @@ public ExecResp getResult() throws TException { } } - public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler726) throws TException { + public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler698) throws TException { checkReady(); - getZone_call method_call = new getZone_call(req, resultHandler726, this, ___protocolFactory, ___transport); + getZone_call method_call = new getZone_call(req, resultHandler698, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getZone_call extends TAsyncMethodCall { private GetZoneReq req; - public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler727, TAsyncClient client723, TProtocolFactory protocolFactory724, TNonblockingTransport transport725) throws TException { - super(client723, protocolFactory724, transport725, resultHandler727, false); + public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler699, TAsyncClient client695, TProtocolFactory protocolFactory696, TNonblockingTransport transport697) throws TException { + super(client695, protocolFactory696, transport697, resultHandler699, false); this.req = req; } @@ -6446,17 +5990,17 @@ public GetZoneResp getResult() throws TException { } } - public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler731) throws TException { + public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler703) throws TException { checkReady(); - listZones_call method_call = new listZones_call(req, resultHandler731, this, ___protocolFactory, ___transport); + listZones_call method_call = new listZones_call(req, resultHandler703, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listZones_call extends TAsyncMethodCall { private ListZonesReq req; - public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler732, TAsyncClient client728, TProtocolFactory protocolFactory729, TNonblockingTransport transport730) throws TException { - super(client728, protocolFactory729, transport730, resultHandler732, false); + public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler704, TAsyncClient client700, TProtocolFactory protocolFactory701, TNonblockingTransport transport702) throws TException { + super(client700, protocolFactory701, transport702, resultHandler704, false); this.req = req; } @@ -6478,209 +6022,17 @@ public ListZonesResp getResult() throws TException { } } - public void addGroup(AddGroupReq req, AsyncMethodCallback resultHandler736) throws TException { - checkReady(); - addGroup_call method_call = new addGroup_call(req, resultHandler736, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class addGroup_call extends TAsyncMethodCall { - private AddGroupReq req; - public addGroup_call(AddGroupReq req, AsyncMethodCallback resultHandler737, TAsyncClient client733, TProtocolFactory protocolFactory734, TNonblockingTransport transport735) throws TException { - super(client733, protocolFactory734, transport735, resultHandler737, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("addGroup", TMessageType.CALL, 0)); - addGroup_args args = new addGroup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_addGroup(); - } - } - - public void dropGroup(DropGroupReq req, AsyncMethodCallback resultHandler741) throws TException { + public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler708) throws TException { checkReady(); - dropGroup_call method_call = new dropGroup_call(req, resultHandler741, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class dropGroup_call extends TAsyncMethodCall { - private DropGroupReq req; - public dropGroup_call(DropGroupReq req, AsyncMethodCallback resultHandler742, TAsyncClient client738, TProtocolFactory protocolFactory739, TNonblockingTransport transport740) throws TException { - super(client738, protocolFactory739, transport740, resultHandler742, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("dropGroup", TMessageType.CALL, 0)); - dropGroup_args args = new dropGroup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_dropGroup(); - } - } - - public void addZoneIntoGroup(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler746) throws TException { - checkReady(); - addZoneIntoGroup_call method_call = new addZoneIntoGroup_call(req, resultHandler746, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class addZoneIntoGroup_call extends TAsyncMethodCall { - private AddZoneIntoGroupReq req; - public addZoneIntoGroup_call(AddZoneIntoGroupReq req, AsyncMethodCallback resultHandler747, TAsyncClient client743, TProtocolFactory protocolFactory744, TNonblockingTransport transport745) throws TException { - super(client743, protocolFactory744, transport745, resultHandler747, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("addZoneIntoGroup", TMessageType.CALL, 0)); - addZoneIntoGroup_args args = new addZoneIntoGroup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_addZoneIntoGroup(); - } - } - - public void dropZoneFromGroup(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler751) throws TException { - checkReady(); - dropZoneFromGroup_call method_call = new dropZoneFromGroup_call(req, resultHandler751, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class dropZoneFromGroup_call extends TAsyncMethodCall { - private DropZoneFromGroupReq req; - public dropZoneFromGroup_call(DropZoneFromGroupReq req, AsyncMethodCallback resultHandler752, TAsyncClient client748, TProtocolFactory protocolFactory749, TNonblockingTransport transport750) throws TException { - super(client748, protocolFactory749, transport750, resultHandler752, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("dropZoneFromGroup", TMessageType.CALL, 0)); - dropZoneFromGroup_args args = new dropZoneFromGroup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_dropZoneFromGroup(); - } - } - - public void getGroup(GetGroupReq req, AsyncMethodCallback resultHandler756) throws TException { - checkReady(); - getGroup_call method_call = new getGroup_call(req, resultHandler756, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class getGroup_call extends TAsyncMethodCall { - private GetGroupReq req; - public getGroup_call(GetGroupReq req, AsyncMethodCallback resultHandler757, TAsyncClient client753, TProtocolFactory protocolFactory754, TNonblockingTransport transport755) throws TException { - super(client753, protocolFactory754, transport755, resultHandler757, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("getGroup", TMessageType.CALL, 0)); - getGroup_args args = new getGroup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public GetGroupResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_getGroup(); - } - } - - public void listGroups(ListGroupsReq req, AsyncMethodCallback resultHandler761) throws TException { - checkReady(); - listGroups_call method_call = new listGroups_call(req, resultHandler761, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class listGroups_call extends TAsyncMethodCall { - private ListGroupsReq req; - public listGroups_call(ListGroupsReq req, AsyncMethodCallback resultHandler762, TAsyncClient client758, TProtocolFactory protocolFactory759, TNonblockingTransport transport760) throws TException { - super(client758, protocolFactory759, transport760, resultHandler762, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("listGroups", TMessageType.CALL, 0)); - listGroups_args args = new listGroups_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ListGroupsResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_listGroups(); - } - } - - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler766) throws TException { - checkReady(); - createBackup_call method_call = new createBackup_call(req, resultHandler766, this, ___protocolFactory, ___transport); + createBackup_call method_call = new createBackup_call(req, resultHandler708, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createBackup_call extends TAsyncMethodCall { private CreateBackupReq req; - public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler767, TAsyncClient client763, TProtocolFactory protocolFactory764, TNonblockingTransport transport765) throws TException { - super(client763, protocolFactory764, transport765, resultHandler767, false); + public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler709, TAsyncClient client705, TProtocolFactory protocolFactory706, TNonblockingTransport transport707) throws TException { + super(client705, protocolFactory706, transport707, resultHandler709, false); this.req = req; } @@ -6702,17 +6054,17 @@ public CreateBackupResp getResult() throws TException { } } - public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler771) throws TException { + public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler713) throws TException { checkReady(); - restoreMeta_call method_call = new restoreMeta_call(req, resultHandler771, this, ___protocolFactory, ___transport); + restoreMeta_call method_call = new restoreMeta_call(req, resultHandler713, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class restoreMeta_call extends TAsyncMethodCall { private RestoreMetaReq req; - public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler772, TAsyncClient client768, TProtocolFactory protocolFactory769, TNonblockingTransport transport770) throws TException { - super(client768, protocolFactory769, transport770, resultHandler772, false); + public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler714, TAsyncClient client710, TProtocolFactory protocolFactory711, TNonblockingTransport transport712) throws TException { + super(client710, protocolFactory711, transport712, resultHandler714, false); this.req = req; } @@ -6734,17 +6086,17 @@ public ExecResp getResult() throws TException { } } - public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler776) throws TException { + public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler718) throws TException { checkReady(); - addListener_call method_call = new addListener_call(req, resultHandler776, this, ___protocolFactory, ___transport); + addListener_call method_call = new addListener_call(req, resultHandler718, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addListener_call extends TAsyncMethodCall { private AddListenerReq req; - public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler777, TAsyncClient client773, TProtocolFactory protocolFactory774, TNonblockingTransport transport775) throws TException { - super(client773, protocolFactory774, transport775, resultHandler777, false); + public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler719, TAsyncClient client715, TProtocolFactory protocolFactory716, TNonblockingTransport transport717) throws TException { + super(client715, protocolFactory716, transport717, resultHandler719, false); this.req = req; } @@ -6766,17 +6118,17 @@ public ExecResp getResult() throws TException { } } - public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler781) throws TException { + public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler723) throws TException { checkReady(); - removeListener_call method_call = new removeListener_call(req, resultHandler781, this, ___protocolFactory, ___transport); + removeListener_call method_call = new removeListener_call(req, resultHandler723, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeListener_call extends TAsyncMethodCall { private RemoveListenerReq req; - public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler782, TAsyncClient client778, TProtocolFactory protocolFactory779, TNonblockingTransport transport780) throws TException { - super(client778, protocolFactory779, transport780, resultHandler782, false); + public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler724, TAsyncClient client720, TProtocolFactory protocolFactory721, TNonblockingTransport transport722) throws TException { + super(client720, protocolFactory721, transport722, resultHandler724, false); this.req = req; } @@ -6798,17 +6150,17 @@ public ExecResp getResult() throws TException { } } - public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler786) throws TException { + public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler728) throws TException { checkReady(); - listListener_call method_call = new listListener_call(req, resultHandler786, this, ___protocolFactory, ___transport); + listListener_call method_call = new listListener_call(req, resultHandler728, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listListener_call extends TAsyncMethodCall { private ListListenerReq req; - public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler787, TAsyncClient client783, TProtocolFactory protocolFactory784, TNonblockingTransport transport785) throws TException { - super(client783, protocolFactory784, transport785, resultHandler787, false); + public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler729, TAsyncClient client725, TProtocolFactory protocolFactory726, TNonblockingTransport transport727) throws TException { + super(client725, protocolFactory726, transport727, resultHandler729, false); this.req = req; } @@ -6830,17 +6182,17 @@ public ListListenerResp getResult() throws TException { } } - public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler791) throws TException { + public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler733) throws TException { checkReady(); - getStats_call method_call = new getStats_call(req, resultHandler791, this, ___protocolFactory, ___transport); + getStats_call method_call = new getStats_call(req, resultHandler733, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getStats_call extends TAsyncMethodCall { private GetStatsReq req; - public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler792, TAsyncClient client788, TProtocolFactory protocolFactory789, TNonblockingTransport transport790) throws TException { - super(client788, protocolFactory789, transport790, resultHandler792, false); + public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler734, TAsyncClient client730, TProtocolFactory protocolFactory731, TNonblockingTransport transport732) throws TException { + super(client730, protocolFactory731, transport732, resultHandler734, false); this.req = req; } @@ -6862,17 +6214,17 @@ public GetStatsResp getResult() throws TException { } } - public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler796) throws TException { + public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler738) throws TException { checkReady(); - signInFTService_call method_call = new signInFTService_call(req, resultHandler796, this, ___protocolFactory, ___transport); + signInFTService_call method_call = new signInFTService_call(req, resultHandler738, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signInFTService_call extends TAsyncMethodCall { private SignInFTServiceReq req; - public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler797, TAsyncClient client793, TProtocolFactory protocolFactory794, TNonblockingTransport transport795) throws TException { - super(client793, protocolFactory794, transport795, resultHandler797, false); + public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler739, TAsyncClient client735, TProtocolFactory protocolFactory736, TNonblockingTransport transport737) throws TException { + super(client735, protocolFactory736, transport737, resultHandler739, false); this.req = req; } @@ -6894,17 +6246,17 @@ public ExecResp getResult() throws TException { } } - public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler801) throws TException { + public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler743) throws TException { checkReady(); - signOutFTService_call method_call = new signOutFTService_call(req, resultHandler801, this, ___protocolFactory, ___transport); + signOutFTService_call method_call = new signOutFTService_call(req, resultHandler743, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signOutFTService_call extends TAsyncMethodCall { private SignOutFTServiceReq req; - public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler802, TAsyncClient client798, TProtocolFactory protocolFactory799, TNonblockingTransport transport800) throws TException { - super(client798, protocolFactory799, transport800, resultHandler802, false); + public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler744, TAsyncClient client740, TProtocolFactory protocolFactory741, TNonblockingTransport transport742) throws TException { + super(client740, protocolFactory741, transport742, resultHandler744, false); this.req = req; } @@ -6926,17 +6278,17 @@ public ExecResp getResult() throws TException { } } - public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler806) throws TException { + public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler748) throws TException { checkReady(); - listFTClients_call method_call = new listFTClients_call(req, resultHandler806, this, ___protocolFactory, ___transport); + listFTClients_call method_call = new listFTClients_call(req, resultHandler748, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTClients_call extends TAsyncMethodCall { private ListFTClientsReq req; - public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler807, TAsyncClient client803, TProtocolFactory protocolFactory804, TNonblockingTransport transport805) throws TException { - super(client803, protocolFactory804, transport805, resultHandler807, false); + public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler749, TAsyncClient client745, TProtocolFactory protocolFactory746, TNonblockingTransport transport747) throws TException { + super(client745, protocolFactory746, transport747, resultHandler749, false); this.req = req; } @@ -6958,17 +6310,17 @@ public ListFTClientsResp getResult() throws TException { } } - public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler811) throws TException { + public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler753) throws TException { checkReady(); - createFTIndex_call method_call = new createFTIndex_call(req, resultHandler811, this, ___protocolFactory, ___transport); + createFTIndex_call method_call = new createFTIndex_call(req, resultHandler753, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createFTIndex_call extends TAsyncMethodCall { private CreateFTIndexReq req; - public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler812, TAsyncClient client808, TProtocolFactory protocolFactory809, TNonblockingTransport transport810) throws TException { - super(client808, protocolFactory809, transport810, resultHandler812, false); + public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler754, TAsyncClient client750, TProtocolFactory protocolFactory751, TNonblockingTransport transport752) throws TException { + super(client750, protocolFactory751, transport752, resultHandler754, false); this.req = req; } @@ -6990,17 +6342,17 @@ public ExecResp getResult() throws TException { } } - public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler816) throws TException { + public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler758) throws TException { checkReady(); - dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler816, this, ___protocolFactory, ___transport); + dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler758, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropFTIndex_call extends TAsyncMethodCall { private DropFTIndexReq req; - public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler817, TAsyncClient client813, TProtocolFactory protocolFactory814, TNonblockingTransport transport815) throws TException { - super(client813, protocolFactory814, transport815, resultHandler817, false); + public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler759, TAsyncClient client755, TProtocolFactory protocolFactory756, TNonblockingTransport transport757) throws TException { + super(client755, protocolFactory756, transport757, resultHandler759, false); this.req = req; } @@ -7022,17 +6374,17 @@ public ExecResp getResult() throws TException { } } - public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler821) throws TException { + public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler763) throws TException { checkReady(); - listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler821, this, ___protocolFactory, ___transport); + listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler763, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTIndexes_call extends TAsyncMethodCall { private ListFTIndexesReq req; - public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler822, TAsyncClient client818, TProtocolFactory protocolFactory819, TNonblockingTransport transport820) throws TException { - super(client818, protocolFactory819, transport820, resultHandler822, false); + public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler764, TAsyncClient client760, TProtocolFactory protocolFactory761, TNonblockingTransport transport762) throws TException { + super(client760, protocolFactory761, transport762, resultHandler764, false); this.req = req; } @@ -7054,17 +6406,17 @@ public ListFTIndexesResp getResult() throws TException { } } - public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler826) throws TException { + public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler768) throws TException { checkReady(); - createSession_call method_call = new createSession_call(req, resultHandler826, this, ___protocolFactory, ___transport); + createSession_call method_call = new createSession_call(req, resultHandler768, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSession_call extends TAsyncMethodCall { private CreateSessionReq req; - public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler827, TAsyncClient client823, TProtocolFactory protocolFactory824, TNonblockingTransport transport825) throws TException { - super(client823, protocolFactory824, transport825, resultHandler827, false); + public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler769, TAsyncClient client765, TProtocolFactory protocolFactory766, TNonblockingTransport transport767) throws TException { + super(client765, protocolFactory766, transport767, resultHandler769, false); this.req = req; } @@ -7086,17 +6438,17 @@ public CreateSessionResp getResult() throws TException { } } - public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler831) throws TException { + public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler773) throws TException { checkReady(); - updateSessions_call method_call = new updateSessions_call(req, resultHandler831, this, ___protocolFactory, ___transport); + updateSessions_call method_call = new updateSessions_call(req, resultHandler773, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateSessions_call extends TAsyncMethodCall { private UpdateSessionsReq req; - public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler832, TAsyncClient client828, TProtocolFactory protocolFactory829, TNonblockingTransport transport830) throws TException { - super(client828, protocolFactory829, transport830, resultHandler832, false); + public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler774, TAsyncClient client770, TProtocolFactory protocolFactory771, TNonblockingTransport transport772) throws TException { + super(client770, protocolFactory771, transport772, resultHandler774, false); this.req = req; } @@ -7118,17 +6470,17 @@ public UpdateSessionsResp getResult() throws TException { } } - public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler836) throws TException { + public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler778) throws TException { checkReady(); - listSessions_call method_call = new listSessions_call(req, resultHandler836, this, ___protocolFactory, ___transport); + listSessions_call method_call = new listSessions_call(req, resultHandler778, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSessions_call extends TAsyncMethodCall { private ListSessionsReq req; - public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler837, TAsyncClient client833, TProtocolFactory protocolFactory834, TNonblockingTransport transport835) throws TException { - super(client833, protocolFactory834, transport835, resultHandler837, false); + public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler779, TAsyncClient client775, TProtocolFactory protocolFactory776, TNonblockingTransport transport777) throws TException { + super(client775, protocolFactory776, transport777, resultHandler779, false); this.req = req; } @@ -7150,17 +6502,17 @@ public ListSessionsResp getResult() throws TException { } } - public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler841) throws TException { + public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler783) throws TException { checkReady(); - getSession_call method_call = new getSession_call(req, resultHandler841, this, ___protocolFactory, ___transport); + getSession_call method_call = new getSession_call(req, resultHandler783, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSession_call extends TAsyncMethodCall { private GetSessionReq req; - public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler842, TAsyncClient client838, TProtocolFactory protocolFactory839, TNonblockingTransport transport840) throws TException { - super(client838, protocolFactory839, transport840, resultHandler842, false); + public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler784, TAsyncClient client780, TProtocolFactory protocolFactory781, TNonblockingTransport transport782) throws TException { + super(client780, protocolFactory781, transport782, resultHandler784, false); this.req = req; } @@ -7182,17 +6534,17 @@ public GetSessionResp getResult() throws TException { } } - public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler846) throws TException { + public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler788) throws TException { checkReady(); - removeSession_call method_call = new removeSession_call(req, resultHandler846, this, ___protocolFactory, ___transport); + removeSession_call method_call = new removeSession_call(req, resultHandler788, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeSession_call extends TAsyncMethodCall { private RemoveSessionReq req; - public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler847, TAsyncClient client843, TProtocolFactory protocolFactory844, TNonblockingTransport transport845) throws TException { - super(client843, protocolFactory844, transport845, resultHandler847, false); + public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler789, TAsyncClient client785, TProtocolFactory protocolFactory786, TNonblockingTransport transport787) throws TException { + super(client785, protocolFactory786, transport787, resultHandler789, false); this.req = req; } @@ -7214,17 +6566,17 @@ public ExecResp getResult() throws TException { } } - public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler851) throws TException { + public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler793) throws TException { checkReady(); - killQuery_call method_call = new killQuery_call(req, resultHandler851, this, ___protocolFactory, ___transport); + killQuery_call method_call = new killQuery_call(req, resultHandler793, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class killQuery_call extends TAsyncMethodCall { private KillQueryReq req; - public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler852, TAsyncClient client848, TProtocolFactory protocolFactory849, TNonblockingTransport transport850) throws TException { - super(client848, protocolFactory849, transport850, resultHandler852, false); + public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler794, TAsyncClient client790, TProtocolFactory protocolFactory791, TNonblockingTransport transport792) throws TException { + super(client790, protocolFactory791, transport792, resultHandler794, false); this.req = req; } @@ -7246,17 +6598,17 @@ public ExecResp getResult() throws TException { } } - public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler856) throws TException { + public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler798) throws TException { checkReady(); - reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler856, this, ___protocolFactory, ___transport); + reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler798, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class reportTaskFinish_call extends TAsyncMethodCall { private ReportTaskReq req; - public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler857, TAsyncClient client853, TProtocolFactory protocolFactory854, TNonblockingTransport transport855) throws TException { - super(client853, protocolFactory854, transport855, resultHandler857, false); + public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler799, TAsyncClient client795, TProtocolFactory protocolFactory796, TNonblockingTransport transport797) throws TException { + super(client795, protocolFactory796, transport797, resultHandler799, false); this.req = req; } @@ -7278,17 +6630,17 @@ public ExecResp getResult() throws TException { } } - public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler861) throws TException { + public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler803) throws TException { checkReady(); - listCluster_call method_call = new listCluster_call(req, resultHandler861, this, ___protocolFactory, ___transport); + listCluster_call method_call = new listCluster_call(req, resultHandler803, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listCluster_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler862, TAsyncClient client858, TProtocolFactory protocolFactory859, TNonblockingTransport transport860) throws TException { - super(client858, protocolFactory859, transport860, resultHandler862, false); + public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler804, TAsyncClient client800, TProtocolFactory protocolFactory801, TNonblockingTransport transport802) throws TException { + super(client800, protocolFactory801, transport802, resultHandler804, false); this.req = req; } @@ -7310,17 +6662,17 @@ public ListClusterInfoResp getResult() throws TException { } } - public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler866) throws TException { + public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler808) throws TException { checkReady(); - getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler866, this, ___protocolFactory, ___transport); + getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler808, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getMetaDirInfo_call extends TAsyncMethodCall { private GetMetaDirInfoReq req; - public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler867, TAsyncClient client863, TProtocolFactory protocolFactory864, TNonblockingTransport transport865) throws TException { - super(client863, protocolFactory864, transport865, resultHandler867, false); + public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler809, TAsyncClient client805, TProtocolFactory protocolFactory806, TNonblockingTransport transport807) throws TException { + super(client805, protocolFactory806, transport807, resultHandler809, false); this.req = req; } @@ -7342,17 +6694,17 @@ public GetMetaDirInfoResp getResult() throws TException { } } - public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler871) throws TException { + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler813) throws TException { checkReady(); - verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler871, this, ___protocolFactory, ___transport); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler813, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class verifyClientVersion_call extends TAsyncMethodCall { private VerifyClientVersionReq req; - public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler872, TAsyncClient client868, TProtocolFactory protocolFactory869, TNonblockingTransport transport870) throws TException { - super(client868, protocolFactory869, transport870, resultHandler872, false); + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler814, TAsyncClient client810, TProtocolFactory protocolFactory811, TNonblockingTransport transport812) throws TException { + super(client810, protocolFactory811, transport812, resultHandler814, false); this.req = req; } @@ -7428,8 +6780,6 @@ public Processor(Iface iface) processMap_.put("getUserRoles", new getUserRoles()); processMap_.put("changePassword", new changePassword()); processMap_.put("heartBeat", new heartBeat()); - processMap_.put("balance", new balance()); - processMap_.put("leaderBalance", new leaderBalance()); processMap_.put("regConfig", new regConfig()); processMap_.put("getConfig", new getConfig()); processMap_.put("setConfig", new setConfig()); @@ -7444,12 +6794,6 @@ public Processor(Iface iface) processMap_.put("dropHostFromZone", new dropHostFromZone()); processMap_.put("getZone", new getZone()); processMap_.put("listZones", new listZones()); - processMap_.put("addGroup", new addGroup()); - processMap_.put("dropGroup", new dropGroup()); - processMap_.put("addZoneIntoGroup", new addZoneIntoGroup()); - processMap_.put("dropZoneFromGroup", new dropZoneFromGroup()); - processMap_.put("getGroup", new getGroup()); - processMap_.put("listGroups", new listGroups()); processMap_.put("createBackup", new createBackup()); processMap_.put("restoreMeta", new restoreMeta()); processMap_.put("addListener", new addListener()); @@ -8470,48 +7814,6 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class balance implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.balance", server_ctx); - balance_args args = new balance_args(); - event_handler_.preRead(handler_ctx, "MetaService.balance"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.balance", args); - balance_result result = new balance_result(); - result.success = iface_.balance(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.balance", result); - oprot.writeMessageBegin(new TMessage("balance", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.balance", result); - } - - } - - private class leaderBalance implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.leaderBalance", server_ctx); - leaderBalance_args args = new leaderBalance_args(); - event_handler_.preRead(handler_ctx, "MetaService.leaderBalance"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.leaderBalance", args); - leaderBalance_result result = new leaderBalance_result(); - result.success = iface_.leaderBalance(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.leaderBalance", result); - oprot.writeMessageBegin(new TMessage("leaderBalance", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.leaderBalance", result); - } - - } - private class regConfig implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -8806,132 +8108,6 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class addGroup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.addGroup", server_ctx); - addGroup_args args = new addGroup_args(); - event_handler_.preRead(handler_ctx, "MetaService.addGroup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.addGroup", args); - addGroup_result result = new addGroup_result(); - result.success = iface_.addGroup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.addGroup", result); - oprot.writeMessageBegin(new TMessage("addGroup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.addGroup", result); - } - - } - - private class dropGroup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.dropGroup", server_ctx); - dropGroup_args args = new dropGroup_args(); - event_handler_.preRead(handler_ctx, "MetaService.dropGroup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.dropGroup", args); - dropGroup_result result = new dropGroup_result(); - result.success = iface_.dropGroup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.dropGroup", result); - oprot.writeMessageBegin(new TMessage("dropGroup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.dropGroup", result); - } - - } - - private class addZoneIntoGroup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.addZoneIntoGroup", server_ctx); - addZoneIntoGroup_args args = new addZoneIntoGroup_args(); - event_handler_.preRead(handler_ctx, "MetaService.addZoneIntoGroup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.addZoneIntoGroup", args); - addZoneIntoGroup_result result = new addZoneIntoGroup_result(); - result.success = iface_.addZoneIntoGroup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.addZoneIntoGroup", result); - oprot.writeMessageBegin(new TMessage("addZoneIntoGroup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.addZoneIntoGroup", result); - } - - } - - private class dropZoneFromGroup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.dropZoneFromGroup", server_ctx); - dropZoneFromGroup_args args = new dropZoneFromGroup_args(); - event_handler_.preRead(handler_ctx, "MetaService.dropZoneFromGroup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.dropZoneFromGroup", args); - dropZoneFromGroup_result result = new dropZoneFromGroup_result(); - result.success = iface_.dropZoneFromGroup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.dropZoneFromGroup", result); - oprot.writeMessageBegin(new TMessage("dropZoneFromGroup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.dropZoneFromGroup", result); - } - - } - - private class getGroup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.getGroup", server_ctx); - getGroup_args args = new getGroup_args(); - event_handler_.preRead(handler_ctx, "MetaService.getGroup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.getGroup", args); - getGroup_result result = new getGroup_result(); - result.success = iface_.getGroup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.getGroup", result); - oprot.writeMessageBegin(new TMessage("getGroup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.getGroup", result); - } - - } - - private class listGroups implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.listGroups", server_ctx); - listGroups_args args = new listGroups_args(); - event_handler_.preRead(handler_ctx, "MetaService.listGroups"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.listGroups", args); - listGroups_result result = new listGroups_result(); - result.success = iface_.listGroups(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.listGroups", result); - oprot.writeMessageBegin(new TMessage("listGroups", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.listGroups", result); - } - - } - private class createBackup implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -29406,11 +28582,11 @@ public void validate() throws TException { } - public static class balance_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("balance_args"); + public static class regConfig_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("regConfig_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public BalanceReq req; + public RegConfigReq req; public static final int REQ = 1; // isset id assignments @@ -29420,19 +28596,19 @@ public static class balance_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, BalanceReq.class))); + new StructMetaData(TType.STRUCT, RegConfigReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(balance_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(regConfig_args.class, metaDataMap); } - public balance_args() { + public regConfig_args() { } - public balance_args( - BalanceReq req) { + public regConfig_args( + RegConfigReq req) { this(); this.req = req; } @@ -29440,21 +28616,21 @@ public balance_args( /** * Performs a deep copy on other. */ - public balance_args(balance_args other) { + public regConfig_args(regConfig_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public balance_args deepCopy() { - return new balance_args(this); + public regConfig_args deepCopy() { + return new regConfig_args(this); } - public BalanceReq getReq() { + public RegConfigReq getReq() { return this.req; } - public balance_args setReq(BalanceReq req) { + public regConfig_args setReq(RegConfigReq req) { this.req = req; return this; } @@ -29480,7 +28656,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((BalanceReq)__value); + setReq((RegConfigReq)__value); } break; @@ -29505,9 +28681,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof balance_args)) + if (!(_that instanceof regConfig_args)) return false; - balance_args that = (balance_args)_that; + regConfig_args that = (regConfig_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -29519,29 +28695,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } - @Override - public int compareTo(balance_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -29555,7 +28708,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new BalanceReq(); + this.req = new RegConfigReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29597,7 +28750,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("balance_args"); + StringBuilder sb = new StringBuilder("regConfig_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29624,11 +28777,11 @@ public void validate() throws TException { } - public static class balance_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("balance_result"); + public static class regConfig_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("regConfig_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public BalanceResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -29638,19 +28791,19 @@ public static class balance_result implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, BalanceResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(balance_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(regConfig_result.class, metaDataMap); } - public balance_result() { + public regConfig_result() { } - public balance_result( - BalanceResp success) { + public regConfig_result( + ExecResp success) { this(); this.success = success; } @@ -29658,21 +28811,21 @@ public balance_result( /** * Performs a deep copy on other. */ - public balance_result(balance_result other) { + public regConfig_result(regConfig_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public balance_result deepCopy() { - return new balance_result(this); + public regConfig_result deepCopy() { + return new regConfig_result(this); } - public BalanceResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public balance_result setSuccess(BalanceResp success) { + public regConfig_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -29698,7 +28851,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((BalanceResp)__value); + setSuccess((ExecResp)__value); } break; @@ -29723,9 +28876,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof balance_result)) + if (!(_that instanceof regConfig_result)) return false; - balance_result that = (balance_result)_that; + regConfig_result that = (regConfig_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -29738,7 +28891,7 @@ public int hashCode() { } @Override - public int compareTo(balance_result other) { + public int compareTo(regConfig_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29773,7 +28926,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new BalanceResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29814,7 +28967,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("balance_result"); + StringBuilder sb = new StringBuilder("regConfig_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29841,11 +28994,11 @@ public void validate() throws TException { } - public static class leaderBalance_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("leaderBalance_args"); + public static class getConfig_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("getConfig_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public LeaderBalanceReq req; + public GetConfigReq req; public static final int REQ = 1; // isset id assignments @@ -29855,19 +29008,19 @@ public static class leaderBalance_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, LeaderBalanceReq.class))); + new StructMetaData(TType.STRUCT, GetConfigReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(leaderBalance_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getConfig_args.class, metaDataMap); } - public leaderBalance_args() { + public getConfig_args() { } - public leaderBalance_args( - LeaderBalanceReq req) { + public getConfig_args( + GetConfigReq req) { this(); this.req = req; } @@ -29875,21 +29028,21 @@ public leaderBalance_args( /** * Performs a deep copy on other. */ - public leaderBalance_args(leaderBalance_args other) { + public getConfig_args(getConfig_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public leaderBalance_args deepCopy() { - return new leaderBalance_args(this); + public getConfig_args deepCopy() { + return new getConfig_args(this); } - public LeaderBalanceReq getReq() { + public GetConfigReq getReq() { return this.req; } - public leaderBalance_args setReq(LeaderBalanceReq req) { + public getConfig_args setReq(GetConfigReq req) { this.req = req; return this; } @@ -29915,7 +29068,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((LeaderBalanceReq)__value); + setReq((GetConfigReq)__value); } break; @@ -29940,9 +29093,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof leaderBalance_args)) + if (!(_that instanceof getConfig_args)) return false; - leaderBalance_args that = (leaderBalance_args)_that; + getConfig_args that = (getConfig_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -29954,29 +29107,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } - @Override - public int compareTo(leaderBalance_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -29990,7 +29120,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new LeaderBalanceReq(); + this.req = new GetConfigReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -30032,7 +29162,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("leaderBalance_args"); + StringBuilder sb = new StringBuilder("getConfig_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -30059,11 +29189,11 @@ public void validate() throws TException { } - public static class leaderBalance_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("leaderBalance_result"); + public static class getConfig_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("getConfig_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetConfigResp success; public static final int SUCCESS = 0; // isset id assignments @@ -30073,19 +29203,19 @@ public static class leaderBalance_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetConfigResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(leaderBalance_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getConfig_result.class, metaDataMap); } - public leaderBalance_result() { + public getConfig_result() { } - public leaderBalance_result( - ExecResp success) { + public getConfig_result( + GetConfigResp success) { this(); this.success = success; } @@ -30093,21 +29223,21 @@ public leaderBalance_result( /** * Performs a deep copy on other. */ - public leaderBalance_result(leaderBalance_result other) { + public getConfig_result(getConfig_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public leaderBalance_result deepCopy() { - return new leaderBalance_result(this); + public getConfig_result deepCopy() { + return new getConfig_result(this); } - public ExecResp getSuccess() { + public GetConfigResp getSuccess() { return this.success; } - public leaderBalance_result setSuccess(ExecResp success) { + public getConfig_result setSuccess(GetConfigResp success) { this.success = success; return this; } @@ -30133,7 +29263,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetConfigResp)__value); } break; @@ -30158,9 +29288,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof leaderBalance_result)) + if (!(_that instanceof getConfig_result)) return false; - leaderBalance_result that = (leaderBalance_result)_that; + getConfig_result that = (getConfig_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -30172,29 +29302,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } - @Override - public int compareTo(leaderBalance_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -30208,7 +29315,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetConfigResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -30249,7 +29356,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("leaderBalance_result"); + StringBuilder sb = new StringBuilder("getConfig_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -30276,11 +29383,11 @@ public void validate() throws TException { } - public static class regConfig_args implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("regConfig_args"); + public static class setConfig_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("setConfig_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RegConfigReq req; + public SetConfigReq req; public static final int REQ = 1; // isset id assignments @@ -30290,19 +29397,19 @@ public static class regConfig_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RegConfigReq.class))); + new StructMetaData(TType.STRUCT, SetConfigReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(regConfig_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(setConfig_args.class, metaDataMap); } - public regConfig_args() { + public setConfig_args() { } - public regConfig_args( - RegConfigReq req) { + public setConfig_args( + SetConfigReq req) { this(); this.req = req; } @@ -30310,21 +29417,21 @@ public regConfig_args( /** * Performs a deep copy on other. */ - public regConfig_args(regConfig_args other) { + public setConfig_args(setConfig_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public regConfig_args deepCopy() { - return new regConfig_args(this); + public setConfig_args deepCopy() { + return new setConfig_args(this); } - public RegConfigReq getReq() { + public SetConfigReq getReq() { return this.req; } - public regConfig_args setReq(RegConfigReq req) { + public setConfig_args setReq(SetConfigReq req) { this.req = req; return this; } @@ -30350,7 +29457,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RegConfigReq)__value); + setReq((SetConfigReq)__value); } break; @@ -30375,9 +29482,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof regConfig_args)) + if (!(_that instanceof setConfig_args)) return false; - regConfig_args that = (regConfig_args)_that; + setConfig_args that = (setConfig_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -30402,7 +29509,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RegConfigReq(); + this.req = new SetConfigReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -30444,7 +29551,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("regConfig_args"); + StringBuilder sb = new StringBuilder("setConfig_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -30471,8 +29578,8 @@ public void validate() throws TException { } - public static class regConfig_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("regConfig_result"); + public static class setConfig_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("setConfig_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -30490,13 +29597,13 @@ public static class regConfig_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(regConfig_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(setConfig_result.class, metaDataMap); } - public regConfig_result() { + public setConfig_result() { } - public regConfig_result( + public setConfig_result( ExecResp success) { this(); this.success = success; @@ -30505,21 +29612,21 @@ public regConfig_result( /** * Performs a deep copy on other. */ - public regConfig_result(regConfig_result other) { + public setConfig_result(setConfig_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public regConfig_result deepCopy() { - return new regConfig_result(this); + public setConfig_result deepCopy() { + return new setConfig_result(this); } public ExecResp getSuccess() { return this.success; } - public regConfig_result setSuccess(ExecResp success) { + public setConfig_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -30570,9 +29677,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof regConfig_result)) + if (!(_that instanceof setConfig_result)) return false; - regConfig_result that = (regConfig_result)_that; + setConfig_result that = (setConfig_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -30585,7 +29692,7 @@ public int hashCode() { } @Override - public int compareTo(regConfig_result other) { + public int compareTo(setConfig_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -30661,7 +29768,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("regConfig_result"); + StringBuilder sb = new StringBuilder("setConfig_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -30688,11 +29795,11 @@ public void validate() throws TException { } - public static class getConfig_args implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("getConfig_args"); + public static class listConfigs_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listConfigs_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetConfigReq req; + public ListConfigsReq req; public static final int REQ = 1; // isset id assignments @@ -30702,19 +29809,19 @@ public static class getConfig_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetConfigReq.class))); + new StructMetaData(TType.STRUCT, ListConfigsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getConfig_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listConfigs_args.class, metaDataMap); } - public getConfig_args() { + public listConfigs_args() { } - public getConfig_args( - GetConfigReq req) { + public listConfigs_args( + ListConfigsReq req) { this(); this.req = req; } @@ -30722,21 +29829,21 @@ public getConfig_args( /** * Performs a deep copy on other. */ - public getConfig_args(getConfig_args other) { + public listConfigs_args(listConfigs_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getConfig_args deepCopy() { - return new getConfig_args(this); + public listConfigs_args deepCopy() { + return new listConfigs_args(this); } - public GetConfigReq getReq() { + public ListConfigsReq getReq() { return this.req; } - public getConfig_args setReq(GetConfigReq req) { + public listConfigs_args setReq(ListConfigsReq req) { this.req = req; return this; } @@ -30762,7 +29869,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetConfigReq)__value); + setReq((ListConfigsReq)__value); } break; @@ -30787,9 +29894,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getConfig_args)) + if (!(_that instanceof listConfigs_args)) return false; - getConfig_args that = (getConfig_args)_that; + listConfigs_args that = (listConfigs_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -30801,6 +29908,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } + @Override + public int compareTo(listConfigs_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -30814,7 +29944,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetConfigReq(); + this.req = new ListConfigsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -30856,7 +29986,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getConfig_args"); + StringBuilder sb = new StringBuilder("listConfigs_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -30883,11 +30013,11 @@ public void validate() throws TException { } - public static class getConfig_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("getConfig_result"); + public static class listConfigs_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("listConfigs_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetConfigResp success; + public ListConfigsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -30897,19 +30027,19 @@ public static class getConfig_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetConfigResp.class))); + new StructMetaData(TType.STRUCT, ListConfigsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getConfig_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listConfigs_result.class, metaDataMap); } - public getConfig_result() { + public listConfigs_result() { } - public getConfig_result( - GetConfigResp success) { + public listConfigs_result( + ListConfigsResp success) { this(); this.success = success; } @@ -30917,21 +30047,21 @@ public getConfig_result( /** * Performs a deep copy on other. */ - public getConfig_result(getConfig_result other) { + public listConfigs_result(listConfigs_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getConfig_result deepCopy() { - return new getConfig_result(this); + public listConfigs_result deepCopy() { + return new listConfigs_result(this); } - public GetConfigResp getSuccess() { + public ListConfigsResp getSuccess() { return this.success; } - public getConfig_result setSuccess(GetConfigResp success) { + public listConfigs_result setSuccess(ListConfigsResp success) { this.success = success; return this; } @@ -30957,7 +30087,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetConfigResp)__value); + setSuccess((ListConfigsResp)__value); } break; @@ -30982,9 +30112,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getConfig_result)) + if (!(_that instanceof listConfigs_result)) return false; - getConfig_result that = (getConfig_result)_that; + listConfigs_result that = (listConfigs_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -31009,7 +30139,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetConfigResp(); + this.success = new ListConfigsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -31050,7 +30180,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getConfig_result"); + StringBuilder sb = new StringBuilder("listConfigs_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31077,11 +30207,11 @@ public void validate() throws TException { } - public static class setConfig_args implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("setConfig_args"); + public static class createSnapshot_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSnapshot_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public SetConfigReq req; + public CreateSnapshotReq req; public static final int REQ = 1; // isset id assignments @@ -31091,19 +30221,19 @@ public static class setConfig_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, SetConfigReq.class))); + new StructMetaData(TType.STRUCT, CreateSnapshotReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(setConfig_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSnapshot_args.class, metaDataMap); } - public setConfig_args() { + public createSnapshot_args() { } - public setConfig_args( - SetConfigReq req) { + public createSnapshot_args( + CreateSnapshotReq req) { this(); this.req = req; } @@ -31111,21 +30241,21 @@ public setConfig_args( /** * Performs a deep copy on other. */ - public setConfig_args(setConfig_args other) { + public createSnapshot_args(createSnapshot_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public setConfig_args deepCopy() { - return new setConfig_args(this); + public createSnapshot_args deepCopy() { + return new createSnapshot_args(this); } - public SetConfigReq getReq() { + public CreateSnapshotReq getReq() { return this.req; } - public setConfig_args setReq(SetConfigReq req) { + public createSnapshot_args setReq(CreateSnapshotReq req) { this.req = req; return this; } @@ -31151,7 +30281,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((SetConfigReq)__value); + setReq((CreateSnapshotReq)__value); } break; @@ -31176,9 +30306,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof setConfig_args)) + if (!(_that instanceof createSnapshot_args)) return false; - setConfig_args that = (setConfig_args)_that; + createSnapshot_args that = (createSnapshot_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -31190,6 +30320,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } + @Override + public int compareTo(createSnapshot_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -31203,7 +30356,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new SetConfigReq(); + this.req = new CreateSnapshotReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -31245,7 +30398,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("setConfig_args"); + StringBuilder sb = new StringBuilder("createSnapshot_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31272,8 +30425,8 @@ public void validate() throws TException { } - public static class setConfig_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("setConfig_result"); + public static class createSnapshot_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSnapshot_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -31291,13 +30444,13 @@ public static class setConfig_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(setConfig_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSnapshot_result.class, metaDataMap); } - public setConfig_result() { + public createSnapshot_result() { } - public setConfig_result( + public createSnapshot_result( ExecResp success) { this(); this.success = success; @@ -31306,21 +30459,21 @@ public setConfig_result( /** * Performs a deep copy on other. */ - public setConfig_result(setConfig_result other) { + public createSnapshot_result(createSnapshot_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public setConfig_result deepCopy() { - return new setConfig_result(this); + public createSnapshot_result deepCopy() { + return new createSnapshot_result(this); } public ExecResp getSuccess() { return this.success; } - public setConfig_result setSuccess(ExecResp success) { + public createSnapshot_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -31371,9 +30524,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof setConfig_result)) + if (!(_that instanceof createSnapshot_result)) return false; - setConfig_result that = (setConfig_result)_that; + createSnapshot_result that = (createSnapshot_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -31386,7 +30539,7 @@ public int hashCode() { } @Override - public int compareTo(setConfig_result other) { + public int compareTo(createSnapshot_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -31462,7 +30615,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("setConfig_result"); + StringBuilder sb = new StringBuilder("createSnapshot_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31489,11 +30642,11 @@ public void validate() throws TException { } - public static class listConfigs_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listConfigs_args"); + public static class dropSnapshot_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropSnapshot_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListConfigsReq req; + public DropSnapshotReq req; public static final int REQ = 1; // isset id assignments @@ -31503,19 +30656,19 @@ public static class listConfigs_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListConfigsReq.class))); + new StructMetaData(TType.STRUCT, DropSnapshotReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listConfigs_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropSnapshot_args.class, metaDataMap); } - public listConfigs_args() { + public dropSnapshot_args() { } - public listConfigs_args( - ListConfigsReq req) { + public dropSnapshot_args( + DropSnapshotReq req) { this(); this.req = req; } @@ -31523,21 +30676,21 @@ public listConfigs_args( /** * Performs a deep copy on other. */ - public listConfigs_args(listConfigs_args other) { + public dropSnapshot_args(dropSnapshot_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listConfigs_args deepCopy() { - return new listConfigs_args(this); + public dropSnapshot_args deepCopy() { + return new dropSnapshot_args(this); } - public ListConfigsReq getReq() { + public DropSnapshotReq getReq() { return this.req; } - public listConfigs_args setReq(ListConfigsReq req) { + public dropSnapshot_args setReq(DropSnapshotReq req) { this.req = req; return this; } @@ -31563,7 +30716,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListConfigsReq)__value); + setReq((DropSnapshotReq)__value); } break; @@ -31588,9 +30741,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listConfigs_args)) + if (!(_that instanceof dropSnapshot_args)) return false; - listConfigs_args that = (listConfigs_args)_that; + dropSnapshot_args that = (dropSnapshot_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -31603,7 +30756,7 @@ public int hashCode() { } @Override - public int compareTo(listConfigs_args other) { + public int compareTo(dropSnapshot_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -31638,7 +30791,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListConfigsReq(); + this.req = new DropSnapshotReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -31680,7 +30833,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listConfigs_args"); + StringBuilder sb = new StringBuilder("dropSnapshot_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31707,11 +30860,11 @@ public void validate() throws TException { } - public static class listConfigs_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("listConfigs_result"); + public static class dropSnapshot_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropSnapshot_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListConfigsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -31721,19 +30874,19 @@ public static class listConfigs_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListConfigsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listConfigs_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropSnapshot_result.class, metaDataMap); } - public listConfigs_result() { + public dropSnapshot_result() { } - public listConfigs_result( - ListConfigsResp success) { + public dropSnapshot_result( + ExecResp success) { this(); this.success = success; } @@ -31741,21 +30894,21 @@ public listConfigs_result( /** * Performs a deep copy on other. */ - public listConfigs_result(listConfigs_result other) { + public dropSnapshot_result(dropSnapshot_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listConfigs_result deepCopy() { - return new listConfigs_result(this); + public dropSnapshot_result deepCopy() { + return new dropSnapshot_result(this); } - public ListConfigsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listConfigs_result setSuccess(ListConfigsResp success) { + public dropSnapshot_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -31781,7 +30934,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListConfigsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -31806,9 +30959,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listConfigs_result)) + if (!(_that instanceof dropSnapshot_result)) return false; - listConfigs_result that = (listConfigs_result)_that; + dropSnapshot_result that = (dropSnapshot_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -31820,6 +30973,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } + @Override + public int compareTo(dropSnapshot_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -31833,7 +31009,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListConfigsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -31874,7 +31050,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listConfigs_result"); + StringBuilder sb = new StringBuilder("dropSnapshot_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31901,11 +31077,11 @@ public void validate() throws TException { } - public static class createSnapshot_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSnapshot_args"); + public static class listSnapshots_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSnapshots_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateSnapshotReq req; + public ListSnapshotsReq req; public static final int REQ = 1; // isset id assignments @@ -31915,19 +31091,19 @@ public static class createSnapshot_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateSnapshotReq.class))); + new StructMetaData(TType.STRUCT, ListSnapshotsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSnapshot_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSnapshots_args.class, metaDataMap); } - public createSnapshot_args() { + public listSnapshots_args() { } - public createSnapshot_args( - CreateSnapshotReq req) { + public listSnapshots_args( + ListSnapshotsReq req) { this(); this.req = req; } @@ -31935,21 +31111,21 @@ public createSnapshot_args( /** * Performs a deep copy on other. */ - public createSnapshot_args(createSnapshot_args other) { + public listSnapshots_args(listSnapshots_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createSnapshot_args deepCopy() { - return new createSnapshot_args(this); + public listSnapshots_args deepCopy() { + return new listSnapshots_args(this); } - public CreateSnapshotReq getReq() { + public ListSnapshotsReq getReq() { return this.req; } - public createSnapshot_args setReq(CreateSnapshotReq req) { + public listSnapshots_args setReq(ListSnapshotsReq req) { this.req = req; return this; } @@ -31975,7 +31151,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateSnapshotReq)__value); + setReq((ListSnapshotsReq)__value); } break; @@ -32000,9 +31176,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSnapshot_args)) + if (!(_that instanceof listSnapshots_args)) return false; - createSnapshot_args that = (createSnapshot_args)_that; + listSnapshots_args that = (listSnapshots_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -32015,7 +31191,7 @@ public int hashCode() { } @Override - public int compareTo(createSnapshot_args other) { + public int compareTo(listSnapshots_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32050,7 +31226,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateSnapshotReq(); + this.req = new ListSnapshotsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32092,7 +31268,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSnapshot_args"); + StringBuilder sb = new StringBuilder("listSnapshots_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32119,11 +31295,11 @@ public void validate() throws TException { } - public static class createSnapshot_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSnapshot_result"); + public static class listSnapshots_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSnapshots_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListSnapshotsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -32133,19 +31309,19 @@ public static class createSnapshot_result implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListSnapshotsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSnapshot_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSnapshots_result.class, metaDataMap); } - public createSnapshot_result() { + public listSnapshots_result() { } - public createSnapshot_result( - ExecResp success) { + public listSnapshots_result( + ListSnapshotsResp success) { this(); this.success = success; } @@ -32153,21 +31329,21 @@ public createSnapshot_result( /** * Performs a deep copy on other. */ - public createSnapshot_result(createSnapshot_result other) { + public listSnapshots_result(listSnapshots_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createSnapshot_result deepCopy() { - return new createSnapshot_result(this); + public listSnapshots_result deepCopy() { + return new listSnapshots_result(this); } - public ExecResp getSuccess() { + public ListSnapshotsResp getSuccess() { return this.success; } - public createSnapshot_result setSuccess(ExecResp success) { + public listSnapshots_result setSuccess(ListSnapshotsResp success) { this.success = success; return this; } @@ -32193,7 +31369,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListSnapshotsResp)__value); } break; @@ -32218,9 +31394,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSnapshot_result)) + if (!(_that instanceof listSnapshots_result)) return false; - createSnapshot_result that = (createSnapshot_result)_that; + listSnapshots_result that = (listSnapshots_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -32233,7 +31409,7 @@ public int hashCode() { } @Override - public int compareTo(createSnapshot_result other) { + public int compareTo(listSnapshots_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32268,7 +31444,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListSnapshotsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32309,7 +31485,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSnapshot_result"); + StringBuilder sb = new StringBuilder("listSnapshots_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32336,11 +31512,11 @@ public void validate() throws TException { } - public static class dropSnapshot_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropSnapshot_args"); + public static class runAdminJob_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("runAdminJob_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropSnapshotReq req; + public AdminJobReq req; public static final int REQ = 1; // isset id assignments @@ -32350,19 +31526,19 @@ public static class dropSnapshot_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropSnapshotReq.class))); + new StructMetaData(TType.STRUCT, AdminJobReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropSnapshot_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(runAdminJob_args.class, metaDataMap); } - public dropSnapshot_args() { + public runAdminJob_args() { } - public dropSnapshot_args( - DropSnapshotReq req) { + public runAdminJob_args( + AdminJobReq req) { this(); this.req = req; } @@ -32370,21 +31546,21 @@ public dropSnapshot_args( /** * Performs a deep copy on other. */ - public dropSnapshot_args(dropSnapshot_args other) { + public runAdminJob_args(runAdminJob_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropSnapshot_args deepCopy() { - return new dropSnapshot_args(this); + public runAdminJob_args deepCopy() { + return new runAdminJob_args(this); } - public DropSnapshotReq getReq() { + public AdminJobReq getReq() { return this.req; } - public dropSnapshot_args setReq(DropSnapshotReq req) { + public runAdminJob_args setReq(AdminJobReq req) { this.req = req; return this; } @@ -32410,7 +31586,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropSnapshotReq)__value); + setReq((AdminJobReq)__value); } break; @@ -32435,9 +31611,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropSnapshot_args)) + if (!(_that instanceof runAdminJob_args)) return false; - dropSnapshot_args that = (dropSnapshot_args)_that; + runAdminJob_args that = (runAdminJob_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -32450,7 +31626,7 @@ public int hashCode() { } @Override - public int compareTo(dropSnapshot_args other) { + public int compareTo(runAdminJob_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32485,7 +31661,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropSnapshotReq(); + this.req = new AdminJobReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32527,7 +31703,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropSnapshot_args"); + StringBuilder sb = new StringBuilder("runAdminJob_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32554,11 +31730,11 @@ public void validate() throws TException { } - public static class dropSnapshot_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropSnapshot_result"); + public static class runAdminJob_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("runAdminJob_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public AdminJobResp success; public static final int SUCCESS = 0; // isset id assignments @@ -32568,19 +31744,19 @@ public static class dropSnapshot_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, AdminJobResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropSnapshot_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(runAdminJob_result.class, metaDataMap); } - public dropSnapshot_result() { + public runAdminJob_result() { } - public dropSnapshot_result( - ExecResp success) { + public runAdminJob_result( + AdminJobResp success) { this(); this.success = success; } @@ -32588,21 +31764,21 @@ public dropSnapshot_result( /** * Performs a deep copy on other. */ - public dropSnapshot_result(dropSnapshot_result other) { + public runAdminJob_result(runAdminJob_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropSnapshot_result deepCopy() { - return new dropSnapshot_result(this); + public runAdminJob_result deepCopy() { + return new runAdminJob_result(this); } - public ExecResp getSuccess() { + public AdminJobResp getSuccess() { return this.success; } - public dropSnapshot_result setSuccess(ExecResp success) { + public runAdminJob_result setSuccess(AdminJobResp success) { this.success = success; return this; } @@ -32628,7 +31804,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((AdminJobResp)__value); } break; @@ -32653,9 +31829,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropSnapshot_result)) + if (!(_that instanceof runAdminJob_result)) return false; - dropSnapshot_result that = (dropSnapshot_result)_that; + runAdminJob_result that = (runAdminJob_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -32668,7 +31844,7 @@ public int hashCode() { } @Override - public int compareTo(dropSnapshot_result other) { + public int compareTo(runAdminJob_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32703,7 +31879,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new AdminJobResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32744,7 +31920,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropSnapshot_result"); + StringBuilder sb = new StringBuilder("runAdminJob_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32771,11 +31947,11 @@ public void validate() throws TException { } - public static class listSnapshots_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSnapshots_args"); + public static class addZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListSnapshotsReq req; + public AddZoneReq req; public static final int REQ = 1; // isset id assignments @@ -32785,19 +31961,19 @@ public static class listSnapshots_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSnapshotsReq.class))); + new StructMetaData(TType.STRUCT, AddZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSnapshots_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addZone_args.class, metaDataMap); } - public listSnapshots_args() { + public addZone_args() { } - public listSnapshots_args( - ListSnapshotsReq req) { + public addZone_args( + AddZoneReq req) { this(); this.req = req; } @@ -32805,21 +31981,21 @@ public listSnapshots_args( /** * Performs a deep copy on other. */ - public listSnapshots_args(listSnapshots_args other) { + public addZone_args(addZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listSnapshots_args deepCopy() { - return new listSnapshots_args(this); + public addZone_args deepCopy() { + return new addZone_args(this); } - public ListSnapshotsReq getReq() { + public AddZoneReq getReq() { return this.req; } - public listSnapshots_args setReq(ListSnapshotsReq req) { + public addZone_args setReq(AddZoneReq req) { this.req = req; return this; } @@ -32845,7 +32021,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListSnapshotsReq)__value); + setReq((AddZoneReq)__value); } break; @@ -32870,9 +32046,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSnapshots_args)) + if (!(_that instanceof addZone_args)) return false; - listSnapshots_args that = (listSnapshots_args)_that; + addZone_args that = (addZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -32885,7 +32061,7 @@ public int hashCode() { } @Override - public int compareTo(listSnapshots_args other) { + public int compareTo(addZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32920,7 +32096,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListSnapshotsReq(); + this.req = new AddZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32962,7 +32138,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSnapshots_args"); + StringBuilder sb = new StringBuilder("addZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32989,11 +32165,11 @@ public void validate() throws TException { } - public static class listSnapshots_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSnapshots_result"); + public static class addZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListSnapshotsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -33003,19 +32179,19 @@ public static class listSnapshots_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSnapshotsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSnapshots_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addZone_result.class, metaDataMap); } - public listSnapshots_result() { + public addZone_result() { } - public listSnapshots_result( - ListSnapshotsResp success) { + public addZone_result( + ExecResp success) { this(); this.success = success; } @@ -33023,21 +32199,21 @@ public listSnapshots_result( /** * Performs a deep copy on other. */ - public listSnapshots_result(listSnapshots_result other) { + public addZone_result(addZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listSnapshots_result deepCopy() { - return new listSnapshots_result(this); + public addZone_result deepCopy() { + return new addZone_result(this); } - public ListSnapshotsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listSnapshots_result setSuccess(ListSnapshotsResp success) { + public addZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -33063,7 +32239,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListSnapshotsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -33088,9 +32264,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSnapshots_result)) + if (!(_that instanceof addZone_result)) return false; - listSnapshots_result that = (listSnapshots_result)_that; + addZone_result that = (addZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -33103,7 +32279,7 @@ public int hashCode() { } @Override - public int compareTo(listSnapshots_result other) { + public int compareTo(addZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33138,7 +32314,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListSnapshotsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33179,7 +32355,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSnapshots_result"); + StringBuilder sb = new StringBuilder("addZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33206,11 +32382,11 @@ public void validate() throws TException { } - public static class runAdminJob_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("runAdminJob_args"); + public static class dropZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AdminJobReq req; + public DropZoneReq req; public static final int REQ = 1; // isset id assignments @@ -33220,19 +32396,19 @@ public static class runAdminJob_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AdminJobReq.class))); + new StructMetaData(TType.STRUCT, DropZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(runAdminJob_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropZone_args.class, metaDataMap); } - public runAdminJob_args() { + public dropZone_args() { } - public runAdminJob_args( - AdminJobReq req) { + public dropZone_args( + DropZoneReq req) { this(); this.req = req; } @@ -33240,21 +32416,21 @@ public runAdminJob_args( /** * Performs a deep copy on other. */ - public runAdminJob_args(runAdminJob_args other) { + public dropZone_args(dropZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public runAdminJob_args deepCopy() { - return new runAdminJob_args(this); + public dropZone_args deepCopy() { + return new dropZone_args(this); } - public AdminJobReq getReq() { + public DropZoneReq getReq() { return this.req; } - public runAdminJob_args setReq(AdminJobReq req) { + public dropZone_args setReq(DropZoneReq req) { this.req = req; return this; } @@ -33280,7 +32456,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AdminJobReq)__value); + setReq((DropZoneReq)__value); } break; @@ -33305,9 +32481,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof runAdminJob_args)) + if (!(_that instanceof dropZone_args)) return false; - runAdminJob_args that = (runAdminJob_args)_that; + dropZone_args that = (dropZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -33320,7 +32496,7 @@ public int hashCode() { } @Override - public int compareTo(runAdminJob_args other) { + public int compareTo(dropZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33355,7 +32531,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AdminJobReq(); + this.req = new DropZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33397,7 +32573,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("runAdminJob_args"); + StringBuilder sb = new StringBuilder("dropZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33424,11 +32600,11 @@ public void validate() throws TException { } - public static class runAdminJob_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("runAdminJob_result"); + public static class dropZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public AdminJobResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -33438,19 +32614,19 @@ public static class runAdminJob_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AdminJobResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(runAdminJob_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropZone_result.class, metaDataMap); } - public runAdminJob_result() { + public dropZone_result() { } - public runAdminJob_result( - AdminJobResp success) { + public dropZone_result( + ExecResp success) { this(); this.success = success; } @@ -33458,21 +32634,21 @@ public runAdminJob_result( /** * Performs a deep copy on other. */ - public runAdminJob_result(runAdminJob_result other) { + public dropZone_result(dropZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public runAdminJob_result deepCopy() { - return new runAdminJob_result(this); + public dropZone_result deepCopy() { + return new dropZone_result(this); } - public AdminJobResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public runAdminJob_result setSuccess(AdminJobResp success) { + public dropZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -33498,7 +32674,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((AdminJobResp)__value); + setSuccess((ExecResp)__value); } break; @@ -33523,9 +32699,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof runAdminJob_result)) + if (!(_that instanceof dropZone_result)) return false; - runAdminJob_result that = (runAdminJob_result)_that; + dropZone_result that = (dropZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -33538,7 +32714,7 @@ public int hashCode() { } @Override - public int compareTo(runAdminJob_result other) { + public int compareTo(dropZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33573,7 +32749,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new AdminJobResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33614,7 +32790,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("runAdminJob_result"); + StringBuilder sb = new StringBuilder("dropZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33641,11 +32817,11 @@ public void validate() throws TException { } - public static class addZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZone_args"); + public static class addHostIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddZoneReq req; + public AddHostIntoZoneReq req; public static final int REQ = 1; // isset id assignments @@ -33655,19 +32831,19 @@ public static class addZone_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddZoneReq.class))); + new StructMetaData(TType.STRUCT, AddHostIntoZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostIntoZone_args.class, metaDataMap); } - public addZone_args() { + public addHostIntoZone_args() { } - public addZone_args( - AddZoneReq req) { + public addHostIntoZone_args( + AddHostIntoZoneReq req) { this(); this.req = req; } @@ -33675,21 +32851,21 @@ public addZone_args( /** * Performs a deep copy on other. */ - public addZone_args(addZone_args other) { + public addHostIntoZone_args(addHostIntoZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addZone_args deepCopy() { - return new addZone_args(this); + public addHostIntoZone_args deepCopy() { + return new addHostIntoZone_args(this); } - public AddZoneReq getReq() { + public AddHostIntoZoneReq getReq() { return this.req; } - public addZone_args setReq(AddZoneReq req) { + public addHostIntoZone_args setReq(AddHostIntoZoneReq req) { this.req = req; return this; } @@ -33715,7 +32891,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddZoneReq)__value); + setReq((AddHostIntoZoneReq)__value); } break; @@ -33740,9 +32916,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addZone_args)) + if (!(_that instanceof addHostIntoZone_args)) return false; - addZone_args that = (addZone_args)_that; + addHostIntoZone_args that = (addHostIntoZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -33755,7 +32931,7 @@ public int hashCode() { } @Override - public int compareTo(addZone_args other) { + public int compareTo(addHostIntoZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33790,7 +32966,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddZoneReq(); + this.req = new AddHostIntoZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33832,7 +33008,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZone_args"); + StringBuilder sb = new StringBuilder("addHostIntoZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33859,8 +33035,8 @@ public void validate() throws TException { } - public static class addZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZone_result"); + public static class addHostIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -33878,13 +33054,13 @@ public static class addZone_result implements TBase, java.io.Serializable, Clone } static { - FieldMetaData.addStructMetaDataMap(addZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostIntoZone_result.class, metaDataMap); } - public addZone_result() { + public addHostIntoZone_result() { } - public addZone_result( + public addHostIntoZone_result( ExecResp success) { this(); this.success = success; @@ -33893,21 +33069,21 @@ public addZone_result( /** * Performs a deep copy on other. */ - public addZone_result(addZone_result other) { + public addHostIntoZone_result(addHostIntoZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addZone_result deepCopy() { - return new addZone_result(this); + public addHostIntoZone_result deepCopy() { + return new addHostIntoZone_result(this); } public ExecResp getSuccess() { return this.success; } - public addZone_result setSuccess(ExecResp success) { + public addHostIntoZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -33958,9 +33134,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addZone_result)) + if (!(_that instanceof addHostIntoZone_result)) return false; - addZone_result that = (addZone_result)_that; + addHostIntoZone_result that = (addHostIntoZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -33973,7 +33149,7 @@ public int hashCode() { } @Override - public int compareTo(addZone_result other) { + public int compareTo(addHostIntoZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -34049,7 +33225,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZone_result"); + StringBuilder sb = new StringBuilder("addHostIntoZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -34076,11 +33252,11 @@ public void validate() throws TException { } - public static class dropZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropZone_args"); + public static class dropHostFromZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropZoneReq req; + public DropHostFromZoneReq req; public static final int REQ = 1; // isset id assignments @@ -34090,19 +33266,19 @@ public static class dropZone_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropZoneReq.class))); + new StructMetaData(TType.STRUCT, DropHostFromZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHostFromZone_args.class, metaDataMap); } - public dropZone_args() { + public dropHostFromZone_args() { } - public dropZone_args( - DropZoneReq req) { + public dropHostFromZone_args( + DropHostFromZoneReq req) { this(); this.req = req; } @@ -34110,21 +33286,21 @@ public dropZone_args( /** * Performs a deep copy on other. */ - public dropZone_args(dropZone_args other) { + public dropHostFromZone_args(dropHostFromZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropZone_args deepCopy() { - return new dropZone_args(this); + public dropHostFromZone_args deepCopy() { + return new dropHostFromZone_args(this); } - public DropZoneReq getReq() { + public DropHostFromZoneReq getReq() { return this.req; } - public dropZone_args setReq(DropZoneReq req) { + public dropHostFromZone_args setReq(DropHostFromZoneReq req) { this.req = req; return this; } @@ -34150,7 +33326,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropZoneReq)__value); + setReq((DropHostFromZoneReq)__value); } break; @@ -34175,9 +33351,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropZone_args)) + if (!(_that instanceof dropHostFromZone_args)) return false; - dropZone_args that = (dropZone_args)_that; + dropHostFromZone_args that = (dropHostFromZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -34190,7 +33366,7 @@ public int hashCode() { } @Override - public int compareTo(dropZone_args other) { + public int compareTo(dropHostFromZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -34225,7 +33401,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropZoneReq(); + this.req = new DropHostFromZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -34267,7 +33443,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropZone_args"); + StringBuilder sb = new StringBuilder("dropHostFromZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -34294,8 +33470,8 @@ public void validate() throws TException { } - public static class dropZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropZone_result"); + public static class dropHostFromZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -34313,13 +33489,13 @@ public static class dropZone_result implements TBase, java.io.Serializable, Clon } static { - FieldMetaData.addStructMetaDataMap(dropZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHostFromZone_result.class, metaDataMap); } - public dropZone_result() { + public dropHostFromZone_result() { } - public dropZone_result( + public dropHostFromZone_result( ExecResp success) { this(); this.success = success; @@ -34328,21 +33504,21 @@ public dropZone_result( /** * Performs a deep copy on other. */ - public dropZone_result(dropZone_result other) { + public dropHostFromZone_result(dropHostFromZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropZone_result deepCopy() { - return new dropZone_result(this); + public dropHostFromZone_result deepCopy() { + return new dropHostFromZone_result(this); } public ExecResp getSuccess() { return this.success; } - public dropZone_result setSuccess(ExecResp success) { + public dropHostFromZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -34393,9 +33569,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropZone_result)) + if (!(_that instanceof dropHostFromZone_result)) return false; - dropZone_result that = (dropZone_result)_that; + dropHostFromZone_result that = (dropHostFromZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -34408,7 +33584,7 @@ public int hashCode() { } @Override - public int compareTo(dropZone_result other) { + public int compareTo(dropHostFromZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -34484,7 +33660,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropZone_result"); + StringBuilder sb = new StringBuilder("dropHostFromZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -34511,11 +33687,11 @@ public void validate() throws TException { } - public static class addHostIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_args"); + public static class getZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddHostIntoZoneReq req; + public GetZoneReq req; public static final int REQ = 1; // isset id assignments @@ -34525,19 +33701,19 @@ public static class addHostIntoZone_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddHostIntoZoneReq.class))); + new StructMetaData(TType.STRUCT, GetZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addHostIntoZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getZone_args.class, metaDataMap); } - public addHostIntoZone_args() { + public getZone_args() { } - public addHostIntoZone_args( - AddHostIntoZoneReq req) { + public getZone_args( + GetZoneReq req) { this(); this.req = req; } @@ -34545,21 +33721,21 @@ public addHostIntoZone_args( /** * Performs a deep copy on other. */ - public addHostIntoZone_args(addHostIntoZone_args other) { + public getZone_args(getZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addHostIntoZone_args deepCopy() { - return new addHostIntoZone_args(this); + public getZone_args deepCopy() { + return new getZone_args(this); } - public AddHostIntoZoneReq getReq() { + public GetZoneReq getReq() { return this.req; } - public addHostIntoZone_args setReq(AddHostIntoZoneReq req) { + public getZone_args setReq(GetZoneReq req) { this.req = req; return this; } @@ -34585,7 +33761,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddHostIntoZoneReq)__value); + setReq((GetZoneReq)__value); } break; @@ -34610,9 +33786,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostIntoZone_args)) + if (!(_that instanceof getZone_args)) return false; - addHostIntoZone_args that = (addHostIntoZone_args)_that; + getZone_args that = (getZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -34625,7 +33801,7 @@ public int hashCode() { } @Override - public int compareTo(addHostIntoZone_args other) { + public int compareTo(getZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -34660,7 +33836,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddHostIntoZoneReq(); + this.req = new GetZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -34702,7 +33878,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostIntoZone_args"); + StringBuilder sb = new StringBuilder("getZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -34729,11 +33905,11 @@ public void validate() throws TException { } - public static class addHostIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_result"); + public static class getZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetZoneResp success; public static final int SUCCESS = 0; // isset id assignments @@ -34743,19 +33919,19 @@ public static class addHostIntoZone_result implements TBase, java.io.Serializabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetZoneResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addHostIntoZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getZone_result.class, metaDataMap); } - public addHostIntoZone_result() { + public getZone_result() { } - public addHostIntoZone_result( - ExecResp success) { + public getZone_result( + GetZoneResp success) { this(); this.success = success; } @@ -34763,21 +33939,21 @@ public addHostIntoZone_result( /** * Performs a deep copy on other. */ - public addHostIntoZone_result(addHostIntoZone_result other) { + public getZone_result(getZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addHostIntoZone_result deepCopy() { - return new addHostIntoZone_result(this); + public getZone_result deepCopy() { + return new getZone_result(this); } - public ExecResp getSuccess() { + public GetZoneResp getSuccess() { return this.success; } - public addHostIntoZone_result setSuccess(ExecResp success) { + public getZone_result setSuccess(GetZoneResp success) { this.success = success; return this; } @@ -34803,7 +33979,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetZoneResp)__value); } break; @@ -34828,9 +34004,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostIntoZone_result)) + if (!(_that instanceof getZone_result)) return false; - addHostIntoZone_result that = (addHostIntoZone_result)_that; + getZone_result that = (getZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -34843,7 +34019,7 @@ public int hashCode() { } @Override - public int compareTo(addHostIntoZone_result other) { + public int compareTo(getZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -34878,7 +34054,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetZoneResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -34919,7 +34095,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostIntoZone_result"); + StringBuilder sb = new StringBuilder("getZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -34946,11 +34122,11 @@ public void validate() throws TException { } - public static class dropHostFromZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_args"); + public static class listZones_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listZones_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropHostFromZoneReq req; + public ListZonesReq req; public static final int REQ = 1; // isset id assignments @@ -34960,19 +34136,19 @@ public static class dropHostFromZone_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropHostFromZoneReq.class))); + new StructMetaData(TType.STRUCT, ListZonesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropHostFromZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listZones_args.class, metaDataMap); } - public dropHostFromZone_args() { + public listZones_args() { } - public dropHostFromZone_args( - DropHostFromZoneReq req) { + public listZones_args( + ListZonesReq req) { this(); this.req = req; } @@ -34980,21 +34156,21 @@ public dropHostFromZone_args( /** * Performs a deep copy on other. */ - public dropHostFromZone_args(dropHostFromZone_args other) { + public listZones_args(listZones_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropHostFromZone_args deepCopy() { - return new dropHostFromZone_args(this); + public listZones_args deepCopy() { + return new listZones_args(this); } - public DropHostFromZoneReq getReq() { + public ListZonesReq getReq() { return this.req; } - public dropHostFromZone_args setReq(DropHostFromZoneReq req) { + public listZones_args setReq(ListZonesReq req) { this.req = req; return this; } @@ -35020,7 +34196,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropHostFromZoneReq)__value); + setReq((ListZonesReq)__value); } break; @@ -35045,9 +34221,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropHostFromZone_args)) + if (!(_that instanceof listZones_args)) return false; - dropHostFromZone_args that = (dropHostFromZone_args)_that; + listZones_args that = (listZones_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -35060,7 +34236,7 @@ public int hashCode() { } @Override - public int compareTo(dropHostFromZone_args other) { + public int compareTo(listZones_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -35095,7 +34271,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropHostFromZoneReq(); + this.req = new ListZonesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -35137,7 +34313,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHostFromZone_args"); + StringBuilder sb = new StringBuilder("listZones_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -35164,11 +34340,11 @@ public void validate() throws TException { } - public static class dropHostFromZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_result"); + public static class listZones_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listZones_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListZonesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -35178,19 +34354,19 @@ public static class dropHostFromZone_result implements TBase, java.io.Serializab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListZonesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropHostFromZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listZones_result.class, metaDataMap); } - public dropHostFromZone_result() { + public listZones_result() { } - public dropHostFromZone_result( - ExecResp success) { + public listZones_result( + ListZonesResp success) { this(); this.success = success; } @@ -35198,21 +34374,21 @@ public dropHostFromZone_result( /** * Performs a deep copy on other. */ - public dropHostFromZone_result(dropHostFromZone_result other) { + public listZones_result(listZones_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropHostFromZone_result deepCopy() { - return new dropHostFromZone_result(this); + public listZones_result deepCopy() { + return new listZones_result(this); } - public ExecResp getSuccess() { + public ListZonesResp getSuccess() { return this.success; } - public dropHostFromZone_result setSuccess(ExecResp success) { + public listZones_result setSuccess(ListZonesResp success) { this.success = success; return this; } @@ -35238,3487 +34414,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof dropHostFromZone_result)) - return false; - dropHostFromZone_result that = (dropHostFromZone_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(dropHostFromZone_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHostFromZone_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class getZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getZone_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public GetZoneReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetZoneReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(getZone_args.class, metaDataMap); - } - - public getZone_args() { - } - - public getZone_args( - GetZoneReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public getZone_args(getZone_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public getZone_args deepCopy() { - return new getZone_args(this); - } - - public GetZoneReq getReq() { - return this.req; - } - - public getZone_args setReq(GetZoneReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((GetZoneReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof getZone_args)) - return false; - getZone_args that = (getZone_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(getZone_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new GetZoneReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getZone_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class getZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getZone_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public GetZoneResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetZoneResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(getZone_result.class, metaDataMap); - } - - public getZone_result() { - } - - public getZone_result( - GetZoneResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public getZone_result(getZone_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public getZone_result deepCopy() { - return new getZone_result(this); - } - - public GetZoneResp getSuccess() { - return this.success; - } - - public getZone_result setSuccess(GetZoneResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((GetZoneResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof getZone_result)) - return false; - getZone_result that = (getZone_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(getZone_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new GetZoneResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getZone_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listZones_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listZones_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public ListZonesReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListZonesReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listZones_args.class, metaDataMap); - } - - public listZones_args() { - } - - public listZones_args( - ListZonesReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public listZones_args(listZones_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public listZones_args deepCopy() { - return new listZones_args(this); - } - - public ListZonesReq getReq() { - return this.req; - } - - public listZones_args setReq(ListZonesReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((ListZonesReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listZones_args)) - return false; - listZones_args that = (listZones_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(listZones_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new ListZonesReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listZones_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listZones_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listZones_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ListZonesResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListZonesResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listZones_result.class, metaDataMap); - } - - public listZones_result() { - } - - public listZones_result( - ListZonesResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public listZones_result(listZones_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public listZones_result deepCopy() { - return new listZones_result(this); - } - - public ListZonesResp getSuccess() { - return this.success; - } - - public listZones_result setSuccess(ListZonesResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ListZonesResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listZones_result)) - return false; - listZones_result that = (listZones_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(listZones_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ListZonesResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listZones_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class addGroup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addGroup_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public AddGroupReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddGroupReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(addGroup_args.class, metaDataMap); - } - - public addGroup_args() { - } - - public addGroup_args( - AddGroupReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public addGroup_args(addGroup_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public addGroup_args deepCopy() { - return new addGroup_args(this); - } - - public AddGroupReq getReq() { - return this.req; - } - - public addGroup_args setReq(AddGroupReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((AddGroupReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof addGroup_args)) - return false; - addGroup_args that = (addGroup_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(addGroup_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new AddGroupReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addGroup_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class addGroup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addGroup_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(addGroup_result.class, metaDataMap); - } - - public addGroup_result() { - } - - public addGroup_result( - ExecResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public addGroup_result(addGroup_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public addGroup_result deepCopy() { - return new addGroup_result(this); - } - - public ExecResp getSuccess() { - return this.success; - } - - public addGroup_result setSuccess(ExecResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof addGroup_result)) - return false; - addGroup_result that = (addGroup_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(addGroup_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addGroup_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class dropGroup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropGroup_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public DropGroupReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropGroupReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(dropGroup_args.class, metaDataMap); - } - - public dropGroup_args() { - } - - public dropGroup_args( - DropGroupReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public dropGroup_args(dropGroup_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public dropGroup_args deepCopy() { - return new dropGroup_args(this); - } - - public DropGroupReq getReq() { - return this.req; - } - - public dropGroup_args setReq(DropGroupReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((DropGroupReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof dropGroup_args)) - return false; - dropGroup_args that = (dropGroup_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(dropGroup_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new DropGroupReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropGroup_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class dropGroup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropGroup_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(dropGroup_result.class, metaDataMap); - } - - public dropGroup_result() { - } - - public dropGroup_result( - ExecResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public dropGroup_result(dropGroup_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public dropGroup_result deepCopy() { - return new dropGroup_result(this); - } - - public ExecResp getSuccess() { - return this.success; - } - - public dropGroup_result setSuccess(ExecResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof dropGroup_result)) - return false; - dropGroup_result that = (dropGroup_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(dropGroup_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropGroup_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class addZoneIntoGroup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZoneIntoGroup_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public AddZoneIntoGroupReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddZoneIntoGroupReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(addZoneIntoGroup_args.class, metaDataMap); - } - - public addZoneIntoGroup_args() { - } - - public addZoneIntoGroup_args( - AddZoneIntoGroupReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public addZoneIntoGroup_args(addZoneIntoGroup_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public addZoneIntoGroup_args deepCopy() { - return new addZoneIntoGroup_args(this); - } - - public AddZoneIntoGroupReq getReq() { - return this.req; - } - - public addZoneIntoGroup_args setReq(AddZoneIntoGroupReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((AddZoneIntoGroupReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof addZoneIntoGroup_args)) - return false; - addZoneIntoGroup_args that = (addZoneIntoGroup_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(addZoneIntoGroup_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new AddZoneIntoGroupReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZoneIntoGroup_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class addZoneIntoGroup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZoneIntoGroup_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(addZoneIntoGroup_result.class, metaDataMap); - } - - public addZoneIntoGroup_result() { - } - - public addZoneIntoGroup_result( - ExecResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public addZoneIntoGroup_result(addZoneIntoGroup_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public addZoneIntoGroup_result deepCopy() { - return new addZoneIntoGroup_result(this); - } - - public ExecResp getSuccess() { - return this.success; - } - - public addZoneIntoGroup_result setSuccess(ExecResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof addZoneIntoGroup_result)) - return false; - addZoneIntoGroup_result that = (addZoneIntoGroup_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(addZoneIntoGroup_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZoneIntoGroup_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class dropZoneFromGroup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropZoneFromGroup_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public DropZoneFromGroupReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropZoneFromGroupReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(dropZoneFromGroup_args.class, metaDataMap); - } - - public dropZoneFromGroup_args() { - } - - public dropZoneFromGroup_args( - DropZoneFromGroupReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public dropZoneFromGroup_args(dropZoneFromGroup_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public dropZoneFromGroup_args deepCopy() { - return new dropZoneFromGroup_args(this); - } - - public DropZoneFromGroupReq getReq() { - return this.req; - } - - public dropZoneFromGroup_args setReq(DropZoneFromGroupReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((DropZoneFromGroupReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof dropZoneFromGroup_args)) - return false; - dropZoneFromGroup_args that = (dropZoneFromGroup_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(dropZoneFromGroup_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new DropZoneFromGroupReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropZoneFromGroup_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class dropZoneFromGroup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropZoneFromGroup_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(dropZoneFromGroup_result.class, metaDataMap); - } - - public dropZoneFromGroup_result() { - } - - public dropZoneFromGroup_result( - ExecResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public dropZoneFromGroup_result(dropZoneFromGroup_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public dropZoneFromGroup_result deepCopy() { - return new dropZoneFromGroup_result(this); - } - - public ExecResp getSuccess() { - return this.success; - } - - public dropZoneFromGroup_result setSuccess(ExecResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof dropZoneFromGroup_result)) - return false; - dropZoneFromGroup_result that = (dropZoneFromGroup_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(dropZoneFromGroup_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropZoneFromGroup_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class getGroup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getGroup_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public GetGroupReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetGroupReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(getGroup_args.class, metaDataMap); - } - - public getGroup_args() { - } - - public getGroup_args( - GetGroupReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public getGroup_args(getGroup_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public getGroup_args deepCopy() { - return new getGroup_args(this); - } - - public GetGroupReq getReq() { - return this.req; - } - - public getGroup_args setReq(GetGroupReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((GetGroupReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof getGroup_args)) - return false; - getGroup_args that = (getGroup_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(getGroup_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new GetGroupReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getGroup_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class getGroup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getGroup_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public GetGroupResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetGroupResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(getGroup_result.class, metaDataMap); - } - - public getGroup_result() { - } - - public getGroup_result( - GetGroupResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public getGroup_result(getGroup_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public getGroup_result deepCopy() { - return new getGroup_result(this); - } - - public GetGroupResp getSuccess() { - return this.success; - } - - public getGroup_result setSuccess(GetGroupResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((GetGroupResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof getGroup_result)) - return false; - getGroup_result that = (getGroup_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(getGroup_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new GetGroupResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getGroup_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listGroups_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listGroups_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public ListGroupsReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListGroupsReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listGroups_args.class, metaDataMap); - } - - public listGroups_args() { - } - - public listGroups_args( - ListGroupsReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public listGroups_args(listGroups_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public listGroups_args deepCopy() { - return new listGroups_args(this); - } - - public ListGroupsReq getReq() { - return this.req; - } - - public listGroups_args setReq(ListGroupsReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((ListGroupsReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listGroups_args)) - return false; - listGroups_args that = (listGroups_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(listGroups_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new ListGroupsReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listGroups_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listGroups_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listGroups_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ListGroupsResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListGroupsResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listGroups_result.class, metaDataMap); - } - - public listGroups_result() { - } - - public listGroups_result( - ListGroupsResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public listGroups_result(listGroups_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public listGroups_result deepCopy() { - return new listGroups_result(this); - } - - public ListGroupsResp getSuccess() { - return this.success; - } - - public listGroups_result setSuccess(ListGroupsResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ListGroupsResp)__value); + setSuccess((ListZonesResp)__value); } break; @@ -38743,9 +34439,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listGroups_result)) + if (!(_that instanceof listZones_result)) return false; - listGroups_result that = (listGroups_result)_that; + listZones_result that = (listZones_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -38758,7 +34454,7 @@ public int hashCode() { } @Override - public int compareTo(listGroups_result other) { + public int compareTo(listZones_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38793,7 +34489,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListGroupsResp(); + this.success = new ListZonesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38834,7 +34530,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listGroups_result"); + StringBuilder sb = new StringBuilder("listZones_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java b/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java new file mode 100644 index 000000000..8ef493cd1 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java @@ -0,0 +1,285 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class PartitionList implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("PartitionList"); + private static final TField PART_LIST_FIELD_DESC = new TField("part_list", TType.LIST, (short)1); + + public List part_list; + public static final int PART_LIST = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(PART_LIST, new FieldMetaData("part_list", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.I32)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(PartitionList.class, metaDataMap); + } + + public PartitionList() { + } + + public PartitionList( + List part_list) { + this(); + this.part_list = part_list; + } + + public static class Builder { + private List part_list; + + public Builder() { + } + + public Builder setPart_list(final List part_list) { + this.part_list = part_list; + return this; + } + + public PartitionList build() { + PartitionList result = new PartitionList(); + result.setPart_list(this.part_list); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public PartitionList(PartitionList other) { + if (other.isSetPart_list()) { + this.part_list = TBaseHelper.deepCopy(other.part_list); + } + } + + public PartitionList deepCopy() { + return new PartitionList(this); + } + + public List getPart_list() { + return this.part_list; + } + + public PartitionList setPart_list(List part_list) { + this.part_list = part_list; + return this; + } + + public void unsetPart_list() { + this.part_list = null; + } + + // Returns true if field part_list is set (has been assigned a value) and false otherwise + public boolean isSetPart_list() { + return this.part_list != null; + } + + public void setPart_listIsSet(boolean __value) { + if (!__value) { + this.part_list = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case PART_LIST: + if (__value == null) { + unsetPart_list(); + } else { + setPart_list((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case PART_LIST: + return getPart_list(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof PartitionList)) + return false; + PartitionList that = (PartitionList)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetPart_list(), that.isSetPart_list(), this.part_list, that.part_list)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {part_list}); + } + + @Override + public int compareTo(PartitionList other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetPart_list()).compareTo(other.isSetPart_list()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(part_list, other.part_list); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case PART_LIST: + if (__field.type == TType.LIST) { + { + TList _list140 = iprot.readListBegin(); + this.part_list = new ArrayList(Math.max(0, _list140.size)); + for (int _i141 = 0; + (_list140.size < 0) ? iprot.peekList() : (_i141 < _list140.size); + ++_i141) + { + int _elem142; + _elem142 = iprot.readI32(); + this.part_list.add(_elem142); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.part_list != null) { + oprot.writeFieldBegin(PART_LIST_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.I32, this.part_list.size())); + for (int _iter143 : this.part_list) { + oprot.writeI32(_iter143); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("PartitionList"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("part_list"); + sb.append(space); + sb.append(":").append(space); + if (this.getPart_list() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getPart_list(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java index 8b9c3fefc..54437a9a1 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list182 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list182.size)); - for (int _i183 = 0; - (_list182.size < 0) ? iprot.peekList() : (_i183 < _list182.size); - ++_i183) + TList _list188 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list188.size)); + for (int _i189 = 0; + (_list188.size < 0) ? iprot.peekList() : (_i189 < _list188.size); + ++_i189) { - ConfigItem _elem184; - _elem184 = new ConfigItem(); - _elem184.read(iprot); - this.items.add(_elem184); + ConfigItem _elem190; + _elem190 = new ConfigItem(); + _elem190.read(iprot); + this.items.add(_elem190); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter185 : this.items) { - _iter185.write(oprot); + for (ConfigItem _iter191 : this.items) { + _iter191.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java index 7db9e47a5..650ba0c1b 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java @@ -261,15 +261,15 @@ public void read(TProtocol iprot) throws TException { case FILES: if (__field.type == TType.LIST) { { - TList _list263 = iprot.readListBegin(); - this.files = new ArrayList(Math.max(0, _list263.size)); - for (int _i264 = 0; - (_list263.size < 0) ? iprot.peekList() : (_i264 < _list263.size); - ++_i264) + TList _list253 = iprot.readListBegin(); + this.files = new ArrayList(Math.max(0, _list253.size)); + for (int _i254 = 0; + (_list253.size < 0) ? iprot.peekList() : (_i254 < _list253.size); + ++_i254) { - byte[] _elem265; - _elem265 = iprot.readBinary(); - this.files.add(_elem265); + byte[] _elem255; + _elem255 = iprot.readBinary(); + this.files.add(_elem255); } iprot.readListEnd(); } @@ -280,16 +280,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list266 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list266.size)); - for (int _i267 = 0; - (_list266.size < 0) ? iprot.peekList() : (_i267 < _list266.size); - ++_i267) + TList _list256 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list256.size)); + for (int _i257 = 0; + (_list256.size < 0) ? iprot.peekList() : (_i257 < _list256.size); + ++_i257) { - HostPair _elem268; - _elem268 = new HostPair(); - _elem268.read(iprot); - this.hosts.add(_elem268); + HostPair _elem258; + _elem258 = new HostPair(); + _elem258.read(iprot); + this.hosts.add(_elem258); } iprot.readListEnd(); } @@ -318,8 +318,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.files.size())); - for (byte[] _iter269 : this.files) { - oprot.writeBinary(_iter269); + for (byte[] _iter259 : this.files) { + oprot.writeBinary(_iter259); } oprot.writeListEnd(); } @@ -329,8 +329,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (HostPair _iter270 : this.hosts) { - _iter270.write(oprot); + for (HostPair _iter260 : this.hosts) { + _iter260.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Session.java b/client/src/main/generated/com/vesoft/nebula/meta/Session.java index 92376799b..b31bc3e05 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Session.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Session.java @@ -738,18 +738,18 @@ public void read(TProtocol iprot) throws TException { case CONFIGS: if (__field.type == TType.MAP) { { - TMap _map288 = iprot.readMapBegin(); - this.configs = new HashMap(Math.max(0, 2*_map288.size)); - for (int _i289 = 0; - (_map288.size < 0) ? iprot.peekMap() : (_i289 < _map288.size); - ++_i289) + TMap _map278 = iprot.readMapBegin(); + this.configs = new HashMap(Math.max(0, 2*_map278.size)); + for (int _i279 = 0; + (_map278.size < 0) ? iprot.peekMap() : (_i279 < _map278.size); + ++_i279) { - byte[] _key290; - com.vesoft.nebula.Value _val291; - _key290 = iprot.readBinary(); - _val291 = new com.vesoft.nebula.Value(); - _val291.read(iprot); - this.configs.put(_key290, _val291); + byte[] _key280; + com.vesoft.nebula.Value _val281; + _key280 = iprot.readBinary(); + _val281 = new com.vesoft.nebula.Value(); + _val281.read(iprot); + this.configs.put(_key280, _val281); } iprot.readMapEnd(); } @@ -760,18 +760,18 @@ public void read(TProtocol iprot) throws TException { case QUERIES: if (__field.type == TType.MAP) { { - TMap _map292 = iprot.readMapBegin(); - this.queries = new HashMap(Math.max(0, 2*_map292.size)); - for (int _i293 = 0; - (_map292.size < 0) ? iprot.peekMap() : (_i293 < _map292.size); - ++_i293) + TMap _map282 = iprot.readMapBegin(); + this.queries = new HashMap(Math.max(0, 2*_map282.size)); + for (int _i283 = 0; + (_map282.size < 0) ? iprot.peekMap() : (_i283 < _map282.size); + ++_i283) { - long _key294; - QueryDesc _val295; - _key294 = iprot.readI64(); - _val295 = new QueryDesc(); - _val295.read(iprot); - this.queries.put(_key294, _val295); + long _key284; + QueryDesc _val285; + _key284 = iprot.readI64(); + _val285 = new QueryDesc(); + _val285.read(iprot); + this.queries.put(_key284, _val285); } iprot.readMapEnd(); } @@ -832,9 +832,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CONFIGS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.configs.size())); - for (Map.Entry _iter296 : this.configs.entrySet()) { - oprot.writeBinary(_iter296.getKey()); - _iter296.getValue().write(oprot); + for (Map.Entry _iter286 : this.configs.entrySet()) { + oprot.writeBinary(_iter286.getKey()); + _iter286.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -844,9 +844,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, this.queries.size())); - for (Map.Entry _iter297 : this.queries.entrySet()) { - oprot.writeI64(_iter297.getKey()); - _iter297.getValue().write(oprot); + for (Map.Entry _iter287 : this.queries.entrySet()) { + oprot.writeI64(_iter287.getKey()); + _iter287.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java index 763afc89b..23d2be1f7 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java @@ -279,16 +279,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list271 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list271.size)); - for (int _i272 = 0; - (_list271.size < 0) ? iprot.peekList() : (_i272 < _list271.size); - ++_i272) + TList _list261 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list261.size)); + for (int _i262 = 0; + (_list261.size < 0) ? iprot.peekList() : (_i262 < _list261.size); + ++_i262) { - FTClient _elem273; - _elem273 = new FTClient(); - _elem273.read(iprot); - this.clients.add(_elem273); + FTClient _elem263; + _elem263 = new FTClient(); + _elem263.read(iprot); + this.clients.add(_elem263); } iprot.readListEnd(); } @@ -322,8 +322,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter274 : this.clients) { - _iter274.write(oprot); + for (FTClient _iter264 : this.clients) { + _iter264.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java index 2a8b3870b..c266908c5 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java @@ -268,16 +268,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list246 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list246.size)); - for (int _i247 = 0; - (_list246.size < 0) ? iprot.peekList() : (_i247 < _list246.size); - ++_i247) + TList _list236 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list236.size)); + for (int _i237 = 0; + (_list236.size < 0) ? iprot.peekList() : (_i237 < _list236.size); + ++_i237) { - BackupInfo _elem248; - _elem248 = new BackupInfo(); - _elem248.read(iprot); - this.info.add(_elem248); + BackupInfo _elem238; + _elem238 = new BackupInfo(); + _elem238.read(iprot); + this.info.add(_elem238); } iprot.readListEnd(); } @@ -311,8 +311,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (BackupInfo _iter249 : this.info) { - _iter249.write(oprot); + for (BackupInfo _iter239 : this.info) { + _iter239.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java index e5f646301..c49ea50de 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list298 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list298.size)); - for (int _i299 = 0; - (_list298.size < 0) ? iprot.peekList() : (_i299 < _list298.size); - ++_i299) + TList _list288 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list288.size)); + for (int _i289 = 0; + (_list288.size < 0) ? iprot.peekList() : (_i289 < _list288.size); + ++_i289) { - Session _elem300; - _elem300 = new Session(); - _elem300.read(iprot); - this.sessions.add(_elem300); + Session _elem290; + _elem290 = new Session(); + _elem290.read(iprot); + this.sessions.add(_elem290); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter301 : this.sessions) { - _iter301.write(oprot); + for (Session _iter291 : this.sessions) { + _iter291.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java index be4ef2522..b752bfc5a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java @@ -352,32 +352,32 @@ public void read(TProtocol iprot) throws TException { case KILLED_QUERIES: if (__field.type == TType.MAP) { { - TMap _map302 = iprot.readMapBegin(); - this.killed_queries = new HashMap>(Math.max(0, 2*_map302.size)); - for (int _i303 = 0; - (_map302.size < 0) ? iprot.peekMap() : (_i303 < _map302.size); - ++_i303) + TMap _map292 = iprot.readMapBegin(); + this.killed_queries = new HashMap>(Math.max(0, 2*_map292.size)); + for (int _i293 = 0; + (_map292.size < 0) ? iprot.peekMap() : (_i293 < _map292.size); + ++_i293) { - long _key304; - Map _val305; - _key304 = iprot.readI64(); + long _key294; + Map _val295; + _key294 = iprot.readI64(); { - TMap _map306 = iprot.readMapBegin(); - _val305 = new HashMap(Math.max(0, 2*_map306.size)); - for (int _i307 = 0; - (_map306.size < 0) ? iprot.peekMap() : (_i307 < _map306.size); - ++_i307) + TMap _map296 = iprot.readMapBegin(); + _val295 = new HashMap(Math.max(0, 2*_map296.size)); + for (int _i297 = 0; + (_map296.size < 0) ? iprot.peekMap() : (_i297 < _map296.size); + ++_i297) { - long _key308; - QueryDesc _val309; - _key308 = iprot.readI64(); - _val309 = new QueryDesc(); - _val309.read(iprot); - _val305.put(_key308, _val309); + long _key298; + QueryDesc _val299; + _key298 = iprot.readI64(); + _val299 = new QueryDesc(); + _val299.read(iprot); + _val295.put(_key298, _val299); } iprot.readMapEnd(); } - this.killed_queries.put(_key304, _val305); + this.killed_queries.put(_key294, _val295); } iprot.readMapEnd(); } @@ -416,13 +416,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILLED_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.MAP, this.killed_queries.size())); - for (Map.Entry> _iter310 : this.killed_queries.entrySet()) { - oprot.writeI64(_iter310.getKey()); + for (Map.Entry> _iter300 : this.killed_queries.entrySet()) { + oprot.writeI64(_iter300.getKey()); { - oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter310.getValue().size())); - for (Map.Entry _iter311 : _iter310.getValue().entrySet()) { - oprot.writeI64(_iter311.getKey()); - _iter311.getValue().write(oprot); + oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter300.getValue().size())); + for (Map.Entry _iter301 : _iter300.getValue().entrySet()) { + oprot.writeI64(_iter301.getKey()); + _iter301.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java index 384c0e95c..1251c12d4 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java @@ -27,9 +27,12 @@ public class VerifyClientVersionReq implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionReq"); private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)1); + private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)2); public byte[] version; + public com.vesoft.nebula.HostAddr host; public static final int VERSION = 1; + public static final int HOST = 2; // isset id assignments @@ -39,6 +42,8 @@ public class VerifyClientVersionReq implements TBase, java.io.Serializable, Clon Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.REQUIRED, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(HOST, new FieldMetaData("host", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -57,8 +62,17 @@ public VerifyClientVersionReq( this.version = version; } + public VerifyClientVersionReq( + byte[] version, + com.vesoft.nebula.HostAddr host) { + this(); + this.version = version; + this.host = host; + } + public static class Builder { private byte[] version; + private com.vesoft.nebula.HostAddr host; public Builder() { } @@ -68,9 +82,15 @@ public Builder setVersion(final byte[] version) { return this; } + public Builder setHost(final com.vesoft.nebula.HostAddr host) { + this.host = host; + return this; + } + public VerifyClientVersionReq build() { VerifyClientVersionReq result = new VerifyClientVersionReq(); result.setVersion(this.version); + result.setHost(this.host); return result; } } @@ -86,6 +106,9 @@ public VerifyClientVersionReq(VerifyClientVersionReq other) { if (other.isSetVersion()) { this.version = TBaseHelper.deepCopy(other.version); } + if (other.isSetHost()) { + this.host = TBaseHelper.deepCopy(other.host); + } } public VerifyClientVersionReq deepCopy() { @@ -116,6 +139,30 @@ public void setVersionIsSet(boolean __value) { } } + public com.vesoft.nebula.HostAddr getHost() { + return this.host; + } + + public VerifyClientVersionReq setHost(com.vesoft.nebula.HostAddr host) { + this.host = host; + return this; + } + + public void unsetHost() { + this.host = null; + } + + // Returns true if field host is set (has been assigned a value) and false otherwise + public boolean isSetHost() { + return this.host != null; + } + + public void setHostIsSet(boolean __value) { + if (!__value) { + this.host = null; + } + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case VERSION: @@ -126,6 +173,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case HOST: + if (__value == null) { + unsetHost(); + } else { + setHost((com.vesoft.nebula.HostAddr)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -136,6 +191,9 @@ public Object getFieldValue(int fieldID) { case VERSION: return getVersion(); + case HOST: + return getHost(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -153,12 +211,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetHost(), that.isSetHost(), this.host, that.host)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {version}); + return Arrays.deepHashCode(new Object[] {version, host}); } @Override @@ -181,6 +241,14 @@ public int compareTo(VerifyClientVersionReq other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetHost()).compareTo(other.isSetHost()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(host, other.host); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -202,6 +270,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case HOST: + if (__field.type == TType.STRUCT) { + this.host = new com.vesoft.nebula.HostAddr(); + this.host.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -224,6 +300,11 @@ public void write(TProtocol oprot) throws TException { oprot.writeBinary(this.version); oprot.writeFieldEnd(); } + if (this.host != null) { + oprot.writeFieldBegin(HOST_FIELD_DESC); + this.host.write(oprot); + oprot.writeFieldEnd(); + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -259,6 +340,17 @@ public String toString(int indent, boolean prettyPrint) { if (this.getVersion().length > 128) sb.append(" ..."); } first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("host"); + sb.append(space); + sb.append(":").append(space); + if (this.getHost() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getHost(), indent + 1, prettyPrint)); + } + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java index 72195cf07..1b25c1fb2 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java @@ -267,16 +267,16 @@ public void read(TProtocol iprot) throws TException { case NODES: if (__field.type == TType.LIST) { { - TList _list210 = iprot.readListBegin(); - this.nodes = new ArrayList(Math.max(0, _list210.size)); - for (int _i211 = 0; - (_list210.size < 0) ? iprot.peekList() : (_i211 < _list210.size); - ++_i211) + TList _list216 = iprot.readListBegin(); + this.nodes = new ArrayList(Math.max(0, _list216.size)); + for (int _i217 = 0; + (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); + ++_i217) { - com.vesoft.nebula.HostAddr _elem212; - _elem212 = new com.vesoft.nebula.HostAddr(); - _elem212.read(iprot); - this.nodes.add(_elem212); + com.vesoft.nebula.HostAddr _elem218; + _elem218 = new com.vesoft.nebula.HostAddr(); + _elem218.read(iprot); + this.nodes.add(_elem218); } iprot.readListEnd(); } @@ -310,8 +310,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(NODES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.nodes.size())); - for (com.vesoft.nebula.HostAddr _iter213 : this.nodes) { - _iter213.write(oprot); + for (com.vesoft.nebula.HostAddr _iter219 : this.nodes) { + _iter219.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java b/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java index 55a0410fe..2720fc58c 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/AddPartReq.java @@ -419,16 +419,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list221 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list221.size)); - for (int _i222 = 0; - (_list221.size < 0) ? iprot.peekList() : (_i222 < _list221.size); - ++_i222) + TList _list252 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list252.size)); + for (int _i253 = 0; + (_list252.size < 0) ? iprot.peekList() : (_i253 < _list252.size); + ++_i253) { - com.vesoft.nebula.HostAddr _elem223; - _elem223 = new com.vesoft.nebula.HostAddr(); - _elem223.read(iprot); - this.peers.add(_elem223); + com.vesoft.nebula.HostAddr _elem254; + _elem254 = new com.vesoft.nebula.HostAddr(); + _elem254.read(iprot); + this.peers.add(_elem254); } iprot.readListEnd(); } @@ -466,8 +466,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter224 : this.peers) { - _iter224.write(oprot); + for (com.vesoft.nebula.HostAddr _iter255 : this.peers) { + _iter255.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java index 24ef64348..35d79c774 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java @@ -486,30 +486,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map292 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map292.size)); - for (int _i293 = 0; - (_map292.size < 0) ? iprot.peekMap() : (_i293 < _map292.size); - ++_i293) + TMap _map291 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map291.size)); + for (int _i292 = 0; + (_map291.size < 0) ? iprot.peekMap() : (_i292 < _map291.size); + ++_i292) { - int _key294; - List _val295; - _key294 = iprot.readI32(); + int _key293; + List _val294; + _key293 = iprot.readI32(); { - TList _list296 = iprot.readListBegin(); - _val295 = new ArrayList(Math.max(0, _list296.size)); - for (int _i297 = 0; - (_list296.size < 0) ? iprot.peekList() : (_i297 < _list296.size); - ++_i297) + TList _list295 = iprot.readListBegin(); + _val294 = new ArrayList(Math.max(0, _list295.size)); + for (int _i296 = 0; + (_list295.size < 0) ? iprot.peekList() : (_i296 < _list295.size); + ++_i296) { - NewEdge _elem298; - _elem298 = new NewEdge(); - _elem298.read(iprot); - _val295.add(_elem298); + NewEdge _elem297; + _elem297 = new NewEdge(); + _elem297.read(iprot); + _val294.add(_elem297); } iprot.readListEnd(); } - this.parts.put(_key294, _val295); + this.parts.put(_key293, _val294); } iprot.readMapEnd(); } @@ -520,15 +520,15 @@ public void read(TProtocol iprot) throws TException { case PROP_NAMES: if (__field.type == TType.LIST) { { - TList _list299 = iprot.readListBegin(); - this.prop_names = new ArrayList(Math.max(0, _list299.size)); - for (int _i300 = 0; - (_list299.size < 0) ? iprot.peekList() : (_i300 < _list299.size); - ++_i300) + TList _list298 = iprot.readListBegin(); + this.prop_names = new ArrayList(Math.max(0, _list298.size)); + for (int _i299 = 0; + (_list298.size < 0) ? iprot.peekList() : (_i299 < _list298.size); + ++_i299) { - byte[] _elem301; - _elem301 = iprot.readBinary(); - this.prop_names.add(_elem301); + byte[] _elem300; + _elem300 = iprot.readBinary(); + this.prop_names.add(_elem300); } iprot.readListEnd(); } @@ -584,12 +584,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter302 : this.parts.entrySet()) { - oprot.writeI32(_iter302.getKey()); + for (Map.Entry> _iter301 : this.parts.entrySet()) { + oprot.writeI32(_iter301.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter302.getValue().size())); - for (NewEdge _iter303 : _iter302.getValue()) { - _iter303.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter301.getValue().size())); + for (NewEdge _iter302 : _iter301.getValue()) { + _iter302.write(oprot); } oprot.writeListEnd(); } @@ -602,8 +602,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROP_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.prop_names.size())); - for (byte[] _iter304 : this.prop_names) { - oprot.writeBinary(_iter304); + for (byte[] _iter303 : this.prop_names) { + oprot.writeBinary(_iter303); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java index a59c6066e..b02f2c92b 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java @@ -454,15 +454,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list305 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list305.size)); - for (int _i306 = 0; - (_list305.size < 0) ? iprot.peekList() : (_i306 < _list305.size); - ++_i306) + TList _list304 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list304.size)); + for (int _i305 = 0; + (_list304.size < 0) ? iprot.peekList() : (_i305 < _list304.size); + ++_i305) { - int _elem307; - _elem307 = iprot.readI32(); - this.parts.add(_elem307); + int _elem306; + _elem306 = iprot.readI32(); + this.parts.add(_elem306); } iprot.readListEnd(); } @@ -507,8 +507,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter308 : this.parts) { - oprot.writeI32(_iter308); + for (int _iter307 : this.parts) { + oprot.writeI32(_iter307); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java index 6f79c0c30..9cb193b9b 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java @@ -347,16 +347,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list234 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list234.size)); - for (int _i235 = 0; - (_list234.size < 0) ? iprot.peekList() : (_i235 < _list234.size); - ++_i235) + TList _list265 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list265.size)); + for (int _i266 = 0; + (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); + ++_i266) { - com.vesoft.nebula.HostAddr _elem236; - _elem236 = new com.vesoft.nebula.HostAddr(); - _elem236.read(iprot); - this.peers.add(_elem236); + com.vesoft.nebula.HostAddr _elem267; + _elem267 = new com.vesoft.nebula.HostAddr(); + _elem267.read(iprot); + this.peers.add(_elem267); } iprot.readListEnd(); } @@ -391,8 +391,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter237 : this.peers) { - _iter237.write(oprot); + for (com.vesoft.nebula.HostAddr _iter268 : this.peers) { + _iter268.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java index 0a945b9b1..e26defcb8 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java @@ -274,16 +274,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list242 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list242.size)); - for (int _i243 = 0; - (_list242.size < 0) ? iprot.peekList() : (_i243 < _list242.size); - ++_i243) + TList _list273 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list273.size)); + for (int _i274 = 0; + (_list273.size < 0) ? iprot.peekList() : (_i274 < _list273.size); + ++_i274) { - com.vesoft.nebula.CheckpointInfo _elem244; - _elem244 = new com.vesoft.nebula.CheckpointInfo(); - _elem244.read(iprot); - this.info.add(_elem244); + com.vesoft.nebula.CheckpointInfo _elem275; + _elem275 = new com.vesoft.nebula.CheckpointInfo(); + _elem275.read(iprot); + this.info.add(_elem275); } iprot.readListEnd(); } @@ -317,8 +317,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter245 : this.info) { - _iter245.write(oprot); + for (com.vesoft.nebula.CheckpointInfo _iter276 : this.info) { + _iter276.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java index 6b4bfaecd..28e298ee6 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java @@ -276,29 +276,29 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTS: if (__field.type == TType.MAP) { { - TMap _map225 = iprot.readMapBegin(); - this.leader_parts = new HashMap>(Math.max(0, 2*_map225.size)); - for (int _i226 = 0; - (_map225.size < 0) ? iprot.peekMap() : (_i226 < _map225.size); - ++_i226) + TMap _map256 = iprot.readMapBegin(); + this.leader_parts = new HashMap>(Math.max(0, 2*_map256.size)); + for (int _i257 = 0; + (_map256.size < 0) ? iprot.peekMap() : (_i257 < _map256.size); + ++_i257) { - int _key227; - List _val228; - _key227 = iprot.readI32(); + int _key258; + List _val259; + _key258 = iprot.readI32(); { - TList _list229 = iprot.readListBegin(); - _val228 = new ArrayList(Math.max(0, _list229.size)); - for (int _i230 = 0; - (_list229.size < 0) ? iprot.peekList() : (_i230 < _list229.size); - ++_i230) + TList _list260 = iprot.readListBegin(); + _val259 = new ArrayList(Math.max(0, _list260.size)); + for (int _i261 = 0; + (_list260.size < 0) ? iprot.peekList() : (_i261 < _list260.size); + ++_i261) { - int _elem231; - _elem231 = iprot.readI32(); - _val228.add(_elem231); + int _elem262; + _elem262 = iprot.readI32(); + _val259.add(_elem262); } iprot.readListEnd(); } - this.leader_parts.put(_key227, _val228); + this.leader_parts.put(_key258, _val259); } iprot.readMapEnd(); } @@ -332,12 +332,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.leader_parts.size())); - for (Map.Entry> _iter232 : this.leader_parts.entrySet()) { - oprot.writeI32(_iter232.getKey()); + for (Map.Entry> _iter263 : this.leader_parts.entrySet()) { + oprot.writeI32(_iter263.getKey()); { - oprot.writeListBegin(new TList(TType.I32, _iter232.getValue().size())); - for (int _iter233 : _iter232.getValue()) { - oprot.writeI32(_iter233); + oprot.writeListBegin(new TList(TType.I32, _iter263.getValue().size())); + for (int _iter264 : _iter263.getValue()) { + oprot.writeI32(_iter264); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java index c5be51355..3cfcc78f6 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java @@ -49,9 +49,9 @@ public interface Iface { public UpdateResponse updateEdge(UpdateEdgeRequest req) throws TException; - public ScanVertexResponse scanVertex(ScanVertexRequest req) throws TException; + public ScanResponse scanVertex(ScanVertexRequest req) throws TException; - public ScanEdgeResponse scanEdge(ScanEdgeRequest req) throws TException; + public ScanResponse scanEdge(ScanEdgeRequest req) throws TException; public GetUUIDResp getUUID(GetUUIDReq req) throws TException; @@ -63,6 +63,12 @@ public interface Iface { public ExecResponse chainAddEdges(AddEdgesRequest req) throws TException; + public KVGetResponse get(KVGetRequest req) throws TException; + + public ExecResponse put(KVPutRequest req) throws TException; + + public ExecResponse remove(KVRemoveRequest req) throws TException; + } public interface AsyncIface { @@ -99,6 +105,12 @@ public interface AsyncIface { public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler) throws TException; + public void get(KVGetRequest req, AsyncMethodCallback resultHandler) throws TException; + + public void put(KVPutRequest req, AsyncMethodCallback resultHandler) throws TException; + + public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler) throws TException; + } public static class Client extends EventHandlerBase implements Iface, TClientIf { @@ -535,7 +547,7 @@ public UpdateResponse recv_updateEdge() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "updateEdge failed: unknown result"); } - public ScanVertexResponse scanVertex(ScanVertexRequest req) throws TException + public ScanResponse scanVertex(ScanVertexRequest req) throws TException { ContextStack ctx = getContextStack("GraphStorageService.scanVertex", null); this.setContextStack(ctx); @@ -557,7 +569,7 @@ public void send_scanVertex(ScanVertexRequest req) throws TException return; } - public ScanVertexResponse recv_scanVertex() throws TException + public ScanResponse recv_scanVertex() throws TException { ContextStack ctx = super.getContextStack(); long bytes; @@ -580,7 +592,7 @@ public ScanVertexResponse recv_scanVertex() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "scanVertex failed: unknown result"); } - public ScanEdgeResponse scanEdge(ScanEdgeRequest req) throws TException + public ScanResponse scanEdge(ScanEdgeRequest req) throws TException { ContextStack ctx = getContextStack("GraphStorageService.scanEdge", null); this.setContextStack(ctx); @@ -602,7 +614,7 @@ public void send_scanEdge(ScanEdgeRequest req) throws TException return; } - public ScanEdgeResponse recv_scanEdge() throws TException + public ScanResponse recv_scanEdge() throws TException { ContextStack ctx = super.getContextStack(); long bytes; @@ -850,6 +862,141 @@ public ExecResponse recv_chainAddEdges() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "chainAddEdges failed: unknown result"); } + public KVGetResponse get(KVGetRequest req) throws TException + { + ContextStack ctx = getContextStack("GraphStorageService.get", null); + this.setContextStack(ctx); + send_get(req); + return recv_get(); + } + + public void send_get(KVGetRequest req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphStorageService.get", null); + oprot_.writeMessageBegin(new TMessage("get", TMessageType.CALL, seqid_)); + get_args args = new get_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphStorageService.get", args); + return; + } + + public KVGetResponse recv_get() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphStorageService.get"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + get_result result = new get_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphStorageService.get", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "get failed: unknown result"); + } + + public ExecResponse put(KVPutRequest req) throws TException + { + ContextStack ctx = getContextStack("GraphStorageService.put", null); + this.setContextStack(ctx); + send_put(req); + return recv_put(); + } + + public void send_put(KVPutRequest req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphStorageService.put", null); + oprot_.writeMessageBegin(new TMessage("put", TMessageType.CALL, seqid_)); + put_args args = new put_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphStorageService.put", args); + return; + } + + public ExecResponse recv_put() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphStorageService.put"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + put_result result = new put_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphStorageService.put", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "put failed: unknown result"); + } + + public ExecResponse remove(KVRemoveRequest req) throws TException + { + ContextStack ctx = getContextStack("GraphStorageService.remove", null); + this.setContextStack(ctx); + send_remove(req); + return recv_remove(); + } + + public void send_remove(KVRemoveRequest req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphStorageService.remove", null); + oprot_.writeMessageBegin(new TMessage("remove", TMessageType.CALL, seqid_)); + remove_args args = new remove_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphStorageService.remove", args); + return; + } + + public ExecResponse recv_remove() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphStorageService.remove"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + remove_result result = new remove_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphStorageService.remove", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "remove failed: unknown result"); + } + } public static class AsyncClient extends TAsyncClient implements AsyncIface { public static class Factory implements TAsyncClientFactory { @@ -868,17 +1015,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler328) throws TException { + public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler330) throws TException { checkReady(); - getNeighbors_call method_call = new getNeighbors_call(req, resultHandler328, this, ___protocolFactory, ___transport); + getNeighbors_call method_call = new getNeighbors_call(req, resultHandler330, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getNeighbors_call extends TAsyncMethodCall { private GetNeighborsRequest req; - public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler329, TAsyncClient client325, TProtocolFactory protocolFactory326, TNonblockingTransport transport327) throws TException { - super(client325, protocolFactory326, transport327, resultHandler329, false); + public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler331, TAsyncClient client327, TProtocolFactory protocolFactory328, TNonblockingTransport transport329) throws TException { + super(client327, protocolFactory328, transport329, resultHandler331, false); this.req = req; } @@ -900,17 +1047,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler333) throws TException { + public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler335) throws TException { checkReady(); - getProps_call method_call = new getProps_call(req, resultHandler333, this, ___protocolFactory, ___transport); + getProps_call method_call = new getProps_call(req, resultHandler335, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getProps_call extends TAsyncMethodCall { private GetPropRequest req; - public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler334, TAsyncClient client330, TProtocolFactory protocolFactory331, TNonblockingTransport transport332) throws TException { - super(client330, protocolFactory331, transport332, resultHandler334, false); + public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler336, TAsyncClient client332, TProtocolFactory protocolFactory333, TNonblockingTransport transport334) throws TException { + super(client332, protocolFactory333, transport334, resultHandler336, false); this.req = req; } @@ -932,17 +1079,17 @@ public GetPropResponse getResult() throws TException { } } - public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler338) throws TException { + public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler340) throws TException { checkReady(); - addVertices_call method_call = new addVertices_call(req, resultHandler338, this, ___protocolFactory, ___transport); + addVertices_call method_call = new addVertices_call(req, resultHandler340, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addVertices_call extends TAsyncMethodCall { private AddVerticesRequest req; - public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler339, TAsyncClient client335, TProtocolFactory protocolFactory336, TNonblockingTransport transport337) throws TException { - super(client335, protocolFactory336, transport337, resultHandler339, false); + public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler341, TAsyncClient client337, TProtocolFactory protocolFactory338, TNonblockingTransport transport339) throws TException { + super(client337, protocolFactory338, transport339, resultHandler341, false); this.req = req; } @@ -964,17 +1111,17 @@ public ExecResponse getResult() throws TException { } } - public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler343) throws TException { + public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler345) throws TException { checkReady(); - addEdges_call method_call = new addEdges_call(req, resultHandler343, this, ___protocolFactory, ___transport); + addEdges_call method_call = new addEdges_call(req, resultHandler345, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler344, TAsyncClient client340, TProtocolFactory protocolFactory341, TNonblockingTransport transport342) throws TException { - super(client340, protocolFactory341, transport342, resultHandler344, false); + public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler346, TAsyncClient client342, TProtocolFactory protocolFactory343, TNonblockingTransport transport344) throws TException { + super(client342, protocolFactory343, transport344, resultHandler346, false); this.req = req; } @@ -996,17 +1143,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler348) throws TException { + public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler350) throws TException { checkReady(); - deleteEdges_call method_call = new deleteEdges_call(req, resultHandler348, this, ___protocolFactory, ___transport); + deleteEdges_call method_call = new deleteEdges_call(req, resultHandler350, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteEdges_call extends TAsyncMethodCall { private DeleteEdgesRequest req; - public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler349, TAsyncClient client345, TProtocolFactory protocolFactory346, TNonblockingTransport transport347) throws TException { - super(client345, protocolFactory346, transport347, resultHandler349, false); + public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler351, TAsyncClient client347, TProtocolFactory protocolFactory348, TNonblockingTransport transport349) throws TException { + super(client347, protocolFactory348, transport349, resultHandler351, false); this.req = req; } @@ -1028,17 +1175,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler353) throws TException { + public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler355) throws TException { checkReady(); - deleteVertices_call method_call = new deleteVertices_call(req, resultHandler353, this, ___protocolFactory, ___transport); + deleteVertices_call method_call = new deleteVertices_call(req, resultHandler355, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteVertices_call extends TAsyncMethodCall { private DeleteVerticesRequest req; - public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler354, TAsyncClient client350, TProtocolFactory protocolFactory351, TNonblockingTransport transport352) throws TException { - super(client350, protocolFactory351, transport352, resultHandler354, false); + public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler356, TAsyncClient client352, TProtocolFactory protocolFactory353, TNonblockingTransport transport354) throws TException { + super(client352, protocolFactory353, transport354, resultHandler356, false); this.req = req; } @@ -1060,17 +1207,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler358) throws TException { + public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler360) throws TException { checkReady(); - deleteTags_call method_call = new deleteTags_call(req, resultHandler358, this, ___protocolFactory, ___transport); + deleteTags_call method_call = new deleteTags_call(req, resultHandler360, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteTags_call extends TAsyncMethodCall { private DeleteTagsRequest req; - public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler359, TAsyncClient client355, TProtocolFactory protocolFactory356, TNonblockingTransport transport357) throws TException { - super(client355, protocolFactory356, transport357, resultHandler359, false); + public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler361, TAsyncClient client357, TProtocolFactory protocolFactory358, TNonblockingTransport transport359) throws TException { + super(client357, protocolFactory358, transport359, resultHandler361, false); this.req = req; } @@ -1092,17 +1239,17 @@ public ExecResponse getResult() throws TException { } } - public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler363) throws TException { + public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler365) throws TException { checkReady(); - updateVertex_call method_call = new updateVertex_call(req, resultHandler363, this, ___protocolFactory, ___transport); + updateVertex_call method_call = new updateVertex_call(req, resultHandler365, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateVertex_call extends TAsyncMethodCall { private UpdateVertexRequest req; - public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler364, TAsyncClient client360, TProtocolFactory protocolFactory361, TNonblockingTransport transport362) throws TException { - super(client360, protocolFactory361, transport362, resultHandler364, false); + public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler366, TAsyncClient client362, TProtocolFactory protocolFactory363, TNonblockingTransport transport364) throws TException { + super(client362, protocolFactory363, transport364, resultHandler366, false); this.req = req; } @@ -1124,17 +1271,17 @@ public UpdateResponse getResult() throws TException { } } - public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler368) throws TException { + public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler370) throws TException { checkReady(); - updateEdge_call method_call = new updateEdge_call(req, resultHandler368, this, ___protocolFactory, ___transport); + updateEdge_call method_call = new updateEdge_call(req, resultHandler370, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler369, TAsyncClient client365, TProtocolFactory protocolFactory366, TNonblockingTransport transport367) throws TException { - super(client365, protocolFactory366, transport367, resultHandler369, false); + public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler371, TAsyncClient client367, TProtocolFactory protocolFactory368, TNonblockingTransport transport369) throws TException { + super(client367, protocolFactory368, transport369, resultHandler371, false); this.req = req; } @@ -1156,17 +1303,17 @@ public UpdateResponse getResult() throws TException { } } - public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler373) throws TException { + public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler375) throws TException { checkReady(); - scanVertex_call method_call = new scanVertex_call(req, resultHandler373, this, ___protocolFactory, ___transport); + scanVertex_call method_call = new scanVertex_call(req, resultHandler375, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanVertex_call extends TAsyncMethodCall { private ScanVertexRequest req; - public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler374, TAsyncClient client370, TProtocolFactory protocolFactory371, TNonblockingTransport transport372) throws TException { - super(client370, protocolFactory371, transport372, resultHandler374, false); + public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler376, TAsyncClient client372, TProtocolFactory protocolFactory373, TNonblockingTransport transport374) throws TException { + super(client372, protocolFactory373, transport374, resultHandler376, false); this.req = req; } @@ -1178,7 +1325,7 @@ public void write_args(TProtocol prot) throws TException { prot.writeMessageEnd(); } - public ScanVertexResponse getResult() throws TException { + public ScanResponse getResult() throws TException { if (getState() != State.RESPONSE_READ) { throw new IllegalStateException("Method call not finished!"); } @@ -1188,17 +1335,17 @@ public ScanVertexResponse getResult() throws TException { } } - public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler378) throws TException { + public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler380) throws TException { checkReady(); - scanEdge_call method_call = new scanEdge_call(req, resultHandler378, this, ___protocolFactory, ___transport); + scanEdge_call method_call = new scanEdge_call(req, resultHandler380, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanEdge_call extends TAsyncMethodCall { private ScanEdgeRequest req; - public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler379, TAsyncClient client375, TProtocolFactory protocolFactory376, TNonblockingTransport transport377) throws TException { - super(client375, protocolFactory376, transport377, resultHandler379, false); + public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler381, TAsyncClient client377, TProtocolFactory protocolFactory378, TNonblockingTransport transport379) throws TException { + super(client377, protocolFactory378, transport379, resultHandler381, false); this.req = req; } @@ -1210,7 +1357,7 @@ public void write_args(TProtocol prot) throws TException { prot.writeMessageEnd(); } - public ScanEdgeResponse getResult() throws TException { + public ScanResponse getResult() throws TException { if (getState() != State.RESPONSE_READ) { throw new IllegalStateException("Method call not finished!"); } @@ -1220,17 +1367,17 @@ public ScanEdgeResponse getResult() throws TException { } } - public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler383) throws TException { + public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler385) throws TException { checkReady(); - getUUID_call method_call = new getUUID_call(req, resultHandler383, this, ___protocolFactory, ___transport); + getUUID_call method_call = new getUUID_call(req, resultHandler385, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUUID_call extends TAsyncMethodCall { private GetUUIDReq req; - public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler384, TAsyncClient client380, TProtocolFactory protocolFactory381, TNonblockingTransport transport382) throws TException { - super(client380, protocolFactory381, transport382, resultHandler384, false); + public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler386, TAsyncClient client382, TProtocolFactory protocolFactory383, TNonblockingTransport transport384) throws TException { + super(client382, protocolFactory383, transport384, resultHandler386, false); this.req = req; } @@ -1252,17 +1399,17 @@ public GetUUIDResp getResult() throws TException { } } - public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler388) throws TException { + public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler390) throws TException { checkReady(); - lookupIndex_call method_call = new lookupIndex_call(req, resultHandler388, this, ___protocolFactory, ___transport); + lookupIndex_call method_call = new lookupIndex_call(req, resultHandler390, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupIndex_call extends TAsyncMethodCall { private LookupIndexRequest req; - public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler389, TAsyncClient client385, TProtocolFactory protocolFactory386, TNonblockingTransport transport387) throws TException { - super(client385, protocolFactory386, transport387, resultHandler389, false); + public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler391, TAsyncClient client387, TProtocolFactory protocolFactory388, TNonblockingTransport transport389) throws TException { + super(client387, protocolFactory388, transport389, resultHandler391, false); this.req = req; } @@ -1284,17 +1431,17 @@ public LookupIndexResp getResult() throws TException { } } - public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler393) throws TException { + public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler395) throws TException { checkReady(); - lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler393, this, ___protocolFactory, ___transport); + lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler395, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupAndTraverse_call extends TAsyncMethodCall { private LookupAndTraverseRequest req; - public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler394, TAsyncClient client390, TProtocolFactory protocolFactory391, TNonblockingTransport transport392) throws TException { - super(client390, protocolFactory391, transport392, resultHandler394, false); + public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler396, TAsyncClient client392, TProtocolFactory protocolFactory393, TNonblockingTransport transport394) throws TException { + super(client392, protocolFactory393, transport394, resultHandler396, false); this.req = req; } @@ -1316,17 +1463,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler398) throws TException { + public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler400) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler398, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler400, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler399, TAsyncClient client395, TProtocolFactory protocolFactory396, TNonblockingTransport transport397) throws TException { - super(client395, protocolFactory396, transport397, resultHandler399, false); + public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler401, TAsyncClient client397, TProtocolFactory protocolFactory398, TNonblockingTransport transport399) throws TException { + super(client397, protocolFactory398, transport399, resultHandler401, false); this.req = req; } @@ -1348,17 +1495,17 @@ public UpdateResponse getResult() throws TException { } } - public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler403) throws TException { + public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler405) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler403, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler405, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler404, TAsyncClient client400, TProtocolFactory protocolFactory401, TNonblockingTransport transport402) throws TException { - super(client400, protocolFactory401, transport402, resultHandler404, false); + public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler406, TAsyncClient client402, TProtocolFactory protocolFactory403, TNonblockingTransport transport404) throws TException { + super(client402, protocolFactory403, transport404, resultHandler406, false); this.req = req; } @@ -1380,6 +1527,102 @@ public ExecResponse getResult() throws TException { } } + public void get(KVGetRequest req, AsyncMethodCallback resultHandler410) throws TException { + checkReady(); + get_call method_call = new get_call(req, resultHandler410, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class get_call extends TAsyncMethodCall { + private KVGetRequest req; + public get_call(KVGetRequest req, AsyncMethodCallback resultHandler411, TAsyncClient client407, TProtocolFactory protocolFactory408, TNonblockingTransport transport409) throws TException { + super(client407, protocolFactory408, transport409, resultHandler411, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("get", TMessageType.CALL, 0)); + get_args args = new get_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public KVGetResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_get(); + } + } + + public void put(KVPutRequest req, AsyncMethodCallback resultHandler415) throws TException { + checkReady(); + put_call method_call = new put_call(req, resultHandler415, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class put_call extends TAsyncMethodCall { + private KVPutRequest req; + public put_call(KVPutRequest req, AsyncMethodCallback resultHandler416, TAsyncClient client412, TProtocolFactory protocolFactory413, TNonblockingTransport transport414) throws TException { + super(client412, protocolFactory413, transport414, resultHandler416, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("put", TMessageType.CALL, 0)); + put_args args = new put_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_put(); + } + } + + public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler420) throws TException { + checkReady(); + remove_call method_call = new remove_call(req, resultHandler420, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class remove_call extends TAsyncMethodCall { + private KVRemoveRequest req; + public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler421, TAsyncClient client417, TProtocolFactory protocolFactory418, TNonblockingTransport transport419) throws TException { + super(client417, protocolFactory418, transport419, resultHandler421, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("remove", TMessageType.CALL, 0)); + remove_args args = new remove_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_remove(); + } + } + } public static class Processor implements TProcessor { @@ -1404,6 +1647,9 @@ public Processor(Iface iface) processMap_.put("lookupAndTraverse", new lookupAndTraverse()); processMap_.put("chainUpdateEdge", new chainUpdateEdge()); processMap_.put("chainAddEdges", new chainAddEdges()); + processMap_.put("get", new get()); + processMap_.put("put", new put()); + processMap_.put("remove", new remove()); } protected static interface ProcessFunction { @@ -1772,6 +2018,69 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class get implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphStorageService.get", server_ctx); + get_args args = new get_args(); + event_handler_.preRead(handler_ctx, "GraphStorageService.get"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphStorageService.get", args); + get_result result = new get_result(); + result.success = iface_.get(args.req); + event_handler_.preWrite(handler_ctx, "GraphStorageService.get", result); + oprot.writeMessageBegin(new TMessage("get", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphStorageService.get", result); + } + + } + + private class put implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphStorageService.put", server_ctx); + put_args args = new put_args(); + event_handler_.preRead(handler_ctx, "GraphStorageService.put"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphStorageService.put", args); + put_result result = new put_result(); + result.success = iface_.put(args.req); + event_handler_.preWrite(handler_ctx, "GraphStorageService.put", result); + oprot.writeMessageBegin(new TMessage("put", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphStorageService.put", result); + } + + } + + private class remove implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphStorageService.remove", server_ctx); + remove_args args = new remove_args(); + event_handler_.preRead(handler_ctx, "GraphStorageService.remove"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphStorageService.remove", args); + remove_result result = new remove_result(); + result.success = iface_.remove(args.req); + event_handler_.preWrite(handler_ctx, "GraphStorageService.remove", result); + oprot.writeMessageBegin(new TMessage("remove", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphStorageService.remove", result); + } + + } + } public static class getNeighbors_args implements TBase, java.io.Serializable, Cloneable { @@ -5612,7 +5921,7 @@ public static class scanVertex_result implements TBase, java.io.Serializable, Cl private static final TStruct STRUCT_DESC = new TStruct("scanVertex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ScanVertexResponse success; + public ScanResponse success; public static final int SUCCESS = 0; // isset id assignments @@ -5622,7 +5931,7 @@ public static class scanVertex_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ScanVertexResponse.class))); + new StructMetaData(TType.STRUCT, ScanResponse.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -5634,7 +5943,7 @@ public scanVertex_result() { } public scanVertex_result( - ScanVertexResponse success) { + ScanResponse success) { this(); this.success = success; } @@ -5652,11 +5961,11 @@ public scanVertex_result deepCopy() { return new scanVertex_result(this); } - public ScanVertexResponse getSuccess() { + public ScanResponse getSuccess() { return this.success; } - public scanVertex_result setSuccess(ScanVertexResponse success) { + public scanVertex_result setSuccess(ScanResponse success) { this.success = success; return this; } @@ -5682,7 +5991,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ScanVertexResponse)__value); + setSuccess((ScanResponse)__value); } break; @@ -5734,7 +6043,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ScanVertexResponse(); + this.success = new ScanResponse(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -6024,7 +6333,7 @@ public static class scanEdge_result implements TBase, java.io.Serializable, Clon private static final TStruct STRUCT_DESC = new TStruct("scanEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ScanEdgeResponse success; + public ScanResponse success; public static final int SUCCESS = 0; // isset id assignments @@ -6034,7 +6343,7 @@ public static class scanEdge_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ScanEdgeResponse.class))); + new StructMetaData(TType.STRUCT, ScanResponse.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -6046,7 +6355,7 @@ public scanEdge_result() { } public scanEdge_result( - ScanEdgeResponse success) { + ScanResponse success) { this(); this.success = success; } @@ -6064,11 +6373,11 @@ public scanEdge_result deepCopy() { return new scanEdge_result(this); } - public ScanEdgeResponse getSuccess() { + public ScanResponse getSuccess() { return this.success; } - public scanEdge_result setSuccess(ScanEdgeResponse success) { + public scanEdge_result setSuccess(ScanResponse success) { this.success = success; return this; } @@ -6094,7 +6403,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ScanEdgeResponse)__value); + setSuccess((ScanResponse)__value); } break; @@ -6146,7 +6455,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ScanEdgeResponse(); + this.success = new ScanResponse(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -8205,4 +8514,1309 @@ public void validate() throws TException { } + public static class get_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("get_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public KVGetRequest req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, KVGetRequest.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(get_args.class, metaDataMap); + } + + public get_args() { + } + + public get_args( + KVGetRequest req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public get_args(get_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public get_args deepCopy() { + return new get_args(this); + } + + public KVGetRequest getReq() { + return this.req; + } + + public get_args setReq(KVGetRequest req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((KVGetRequest)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof get_args)) + return false; + get_args that = (get_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(get_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new KVGetRequest(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("get_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class get_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("get_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public KVGetResponse success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, KVGetResponse.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(get_result.class, metaDataMap); + } + + public get_result() { + } + + public get_result( + KVGetResponse success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public get_result(get_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public get_result deepCopy() { + return new get_result(this); + } + + public KVGetResponse getSuccess() { + return this.success; + } + + public get_result setSuccess(KVGetResponse success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((KVGetResponse)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof get_result)) + return false; + get_result that = (get_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(get_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new KVGetResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("get_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class put_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("put_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public KVPutRequest req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, KVPutRequest.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(put_args.class, metaDataMap); + } + + public put_args() { + } + + public put_args( + KVPutRequest req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public put_args(put_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public put_args deepCopy() { + return new put_args(this); + } + + public KVPutRequest getReq() { + return this.req; + } + + public put_args setReq(KVPutRequest req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((KVPutRequest)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof put_args)) + return false; + put_args that = (put_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(put_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new KVPutRequest(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("put_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class put_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("put_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ExecResponse success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ExecResponse.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(put_result.class, metaDataMap); + } + + public put_result() { + } + + public put_result( + ExecResponse success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public put_result(put_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public put_result deepCopy() { + return new put_result(this); + } + + public ExecResponse getSuccess() { + return this.success; + } + + public put_result setSuccess(ExecResponse success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ExecResponse)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof put_result)) + return false; + put_result that = (put_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(put_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ExecResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("put_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class remove_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("remove_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public KVRemoveRequest req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, KVRemoveRequest.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(remove_args.class, metaDataMap); + } + + public remove_args() { + } + + public remove_args( + KVRemoveRequest req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public remove_args(remove_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public remove_args deepCopy() { + return new remove_args(this); + } + + public KVRemoveRequest getReq() { + return this.req; + } + + public remove_args setReq(KVRemoveRequest req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((KVRemoveRequest)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof remove_args)) + return false; + remove_args that = (remove_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(remove_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new KVRemoveRequest(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("remove_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class remove_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("remove_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ExecResponse success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ExecResponse.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(remove_result.class, metaDataMap); + } + + public remove_result() { + } + + public remove_result( + ExecResponse success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public remove_result(remove_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public remove_result deepCopy() { + return new remove_result(this); + } + + public ExecResponse getSuccess() { + return this.success; + } + + public remove_result setSuccess(ExecResponse success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ExecResponse)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof remove_result)) + return false; + remove_result that = (remove_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(remove_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ExecResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("remove_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java index ae3ee00b2..f687d603f 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java @@ -182,17 +182,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler524) throws TException { + public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler523) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler524, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler523, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private ChainAddEdgesRequest req; - public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler525, TAsyncClient client521, TProtocolFactory protocolFactory522, TNonblockingTransport transport523) throws TException { - super(client521, protocolFactory522, transport523, resultHandler525, false); + public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler524, TAsyncClient client520, TProtocolFactory protocolFactory521, TNonblockingTransport transport522) throws TException { + super(client520, protocolFactory521, transport522, resultHandler524, false); this.req = req; } @@ -214,17 +214,17 @@ public ExecResponse getResult() throws TException { } } - public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler529) throws TException { + public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler528) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler529, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler528, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private ChainUpdateEdgeRequest req; - public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler530, TAsyncClient client526, TProtocolFactory protocolFactory527, TNonblockingTransport transport528) throws TException { - super(client526, protocolFactory527, transport528, resultHandler530, false); + public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler529, TAsyncClient client525, TProtocolFactory protocolFactory526, TNonblockingTransport transport527) throws TException { + super(client525, protocolFactory526, transport527, resultHandler529, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java index 357a6fe2b..a54234d85 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java @@ -419,17 +419,17 @@ public void read(TProtocol iprot) throws TException { case TERM_OF_PARTS: if (__field.type == TType.MAP) { { - TMap _map278 = iprot.readMapBegin(); - this.term_of_parts = new HashMap(Math.max(0, 2*_map278.size)); - for (int _i279 = 0; - (_map278.size < 0) ? iprot.peekMap() : (_i279 < _map278.size); - ++_i279) + TMap _map277 = iprot.readMapBegin(); + this.term_of_parts = new HashMap(Math.max(0, 2*_map277.size)); + for (int _i278 = 0; + (_map277.size < 0) ? iprot.peekMap() : (_i278 < _map277.size); + ++_i278) { - int _key280; - long _val281; - _key280 = iprot.readI32(); - _val281 = iprot.readI64(); - this.term_of_parts.put(_key280, _val281); + int _key279; + long _val280; + _key279 = iprot.readI32(); + _val280 = iprot.readI64(); + this.term_of_parts.put(_key279, _val280); } iprot.readMapEnd(); } @@ -456,29 +456,29 @@ public void read(TProtocol iprot) throws TException { case EDGE_VER: if (__field.type == TType.MAP) { { - TMap _map282 = iprot.readMapBegin(); - this.edge_ver = new HashMap>(Math.max(0, 2*_map282.size)); - for (int _i283 = 0; - (_map282.size < 0) ? iprot.peekMap() : (_i283 < _map282.size); - ++_i283) + TMap _map281 = iprot.readMapBegin(); + this.edge_ver = new HashMap>(Math.max(0, 2*_map281.size)); + for (int _i282 = 0; + (_map281.size < 0) ? iprot.peekMap() : (_i282 < _map281.size); + ++_i282) { - int _key284; - List _val285; - _key284 = iprot.readI32(); + int _key283; + List _val284; + _key283 = iprot.readI32(); { - TList _list286 = iprot.readListBegin(); - _val285 = new ArrayList(Math.max(0, _list286.size)); - for (int _i287 = 0; - (_list286.size < 0) ? iprot.peekList() : (_i287 < _list286.size); - ++_i287) + TList _list285 = iprot.readListBegin(); + _val284 = new ArrayList(Math.max(0, _list285.size)); + for (int _i286 = 0; + (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); + ++_i286) { - long _elem288; - _elem288 = iprot.readI64(); - _val285.add(_elem288); + long _elem287; + _elem287 = iprot.readI64(); + _val284.add(_elem287); } iprot.readListEnd(); } - this.edge_ver.put(_key284, _val285); + this.edge_ver.put(_key283, _val284); } iprot.readMapEnd(); } @@ -510,9 +510,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TERM_OF_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.I64, this.term_of_parts.size())); - for (Map.Entry _iter289 : this.term_of_parts.entrySet()) { - oprot.writeI32(_iter289.getKey()); - oprot.writeI64(_iter289.getValue()); + for (Map.Entry _iter288 : this.term_of_parts.entrySet()) { + oprot.writeI32(_iter288.getKey()); + oprot.writeI64(_iter288.getValue()); } oprot.writeMapEnd(); } @@ -537,12 +537,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGE_VER_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.edge_ver.size())); - for (Map.Entry> _iter290 : this.edge_ver.entrySet()) { - oprot.writeI32(_iter290.getKey()); + for (Map.Entry> _iter289 : this.edge_ver.entrySet()) { + oprot.writeI32(_iter289.getKey()); { - oprot.writeListBegin(new TList(TType.I64, _iter290.getValue().size())); - for (long _iter291 : _iter290.getValue()) { - oprot.writeI64(_iter291); + oprot.writeListBegin(new TList(TType.I64, _iter289.getValue().size())); + for (long _iter290 : _iter289.getValue()) { + oprot.writeI64(_iter290); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java index 641b74622..b8bb8ba85 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVGetRequest.java @@ -341,29 +341,29 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map246 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map246.size)); - for (int _i247 = 0; - (_map246.size < 0) ? iprot.peekMap() : (_i247 < _map246.size); - ++_i247) + TMap _map220 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map220.size)); + for (int _i221 = 0; + (_map220.size < 0) ? iprot.peekMap() : (_i221 < _map220.size); + ++_i221) { - int _key248; - List _val249; - _key248 = iprot.readI32(); + int _key222; + List _val223; + _key222 = iprot.readI32(); { - TList _list250 = iprot.readListBegin(); - _val249 = new ArrayList(Math.max(0, _list250.size)); - for (int _i251 = 0; - (_list250.size < 0) ? iprot.peekList() : (_i251 < _list250.size); - ++_i251) + TList _list224 = iprot.readListBegin(); + _val223 = new ArrayList(Math.max(0, _list224.size)); + for (int _i225 = 0; + (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); + ++_i225) { - byte[] _elem252; - _elem252 = iprot.readBinary(); - _val249.add(_elem252); + byte[] _elem226; + _elem226 = iprot.readBinary(); + _val223.add(_elem226); } iprot.readListEnd(); } - this.parts.put(_key248, _val249); + this.parts.put(_key222, _val223); } iprot.readMapEnd(); } @@ -403,12 +403,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter253 : this.parts.entrySet()) { - oprot.writeI32(_iter253.getKey()); + for (Map.Entry> _iter227 : this.parts.entrySet()) { + oprot.writeI32(_iter227.getKey()); { - oprot.writeListBegin(new TList(TType.STRING, _iter253.getValue().size())); - for (byte[] _iter254 : _iter253.getValue()) { - oprot.writeBinary(_iter254); + oprot.writeListBegin(new TList(TType.STRING, _iter227.getValue().size())); + for (byte[] _iter228 : _iter227.getValue()) { + oprot.writeBinary(_iter228); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java index 34849519a..50fa415e9 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVGetResponse.java @@ -275,17 +275,17 @@ public void read(TProtocol iprot) throws TException { case KEY_VALUES: if (__field.type == TType.MAP) { { - TMap _map255 = iprot.readMapBegin(); - this.key_values = new HashMap(Math.max(0, 2*_map255.size)); - for (int _i256 = 0; - (_map255.size < 0) ? iprot.peekMap() : (_i256 < _map255.size); - ++_i256) + TMap _map229 = iprot.readMapBegin(); + this.key_values = new HashMap(Math.max(0, 2*_map229.size)); + for (int _i230 = 0; + (_map229.size < 0) ? iprot.peekMap() : (_i230 < _map229.size); + ++_i230) { - byte[] _key257; - byte[] _val258; - _key257 = iprot.readBinary(); - _val258 = iprot.readBinary(); - this.key_values.put(_key257, _val258); + byte[] _key231; + byte[] _val232; + _key231 = iprot.readBinary(); + _val232 = iprot.readBinary(); + this.key_values.put(_key231, _val232); } iprot.readMapEnd(); } @@ -319,9 +319,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KEY_VALUES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.key_values.size())); - for (Map.Entry _iter259 : this.key_values.entrySet()) { - oprot.writeBinary(_iter259.getKey()); - oprot.writeBinary(_iter259.getValue()); + for (Map.Entry _iter233 : this.key_values.entrySet()) { + oprot.writeBinary(_iter233.getKey()); + oprot.writeBinary(_iter233.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java index 17ebf8c94..38d9b57fd 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVPutRequest.java @@ -277,30 +277,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map260 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map260.size)); - for (int _i261 = 0; - (_map260.size < 0) ? iprot.peekMap() : (_i261 < _map260.size); - ++_i261) + TMap _map234 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map234.size)); + for (int _i235 = 0; + (_map234.size < 0) ? iprot.peekMap() : (_i235 < _map234.size); + ++_i235) { - int _key262; - List _val263; - _key262 = iprot.readI32(); + int _key236; + List _val237; + _key236 = iprot.readI32(); { - TList _list264 = iprot.readListBegin(); - _val263 = new ArrayList(Math.max(0, _list264.size)); - for (int _i265 = 0; - (_list264.size < 0) ? iprot.peekList() : (_i265 < _list264.size); - ++_i265) + TList _list238 = iprot.readListBegin(); + _val237 = new ArrayList(Math.max(0, _list238.size)); + for (int _i239 = 0; + (_list238.size < 0) ? iprot.peekList() : (_i239 < _list238.size); + ++_i239) { - com.vesoft.nebula.KeyValue _elem266; - _elem266 = new com.vesoft.nebula.KeyValue(); - _elem266.read(iprot); - _val263.add(_elem266); + com.vesoft.nebula.KeyValue _elem240; + _elem240 = new com.vesoft.nebula.KeyValue(); + _elem240.read(iprot); + _val237.add(_elem240); } iprot.readListEnd(); } - this.parts.put(_key262, _val263); + this.parts.put(_key236, _val237); } iprot.readMapEnd(); } @@ -332,12 +332,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter267 : this.parts.entrySet()) { - oprot.writeI32(_iter267.getKey()); + for (Map.Entry> _iter241 : this.parts.entrySet()) { + oprot.writeI32(_iter241.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter267.getValue().size())); - for (com.vesoft.nebula.KeyValue _iter268 : _iter267.getValue()) { - _iter268.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter241.getValue().size())); + for (com.vesoft.nebula.KeyValue _iter242 : _iter241.getValue()) { + _iter242.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java index 3fb9d63f8..8846831ca 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/KVRemoveRequest.java @@ -277,29 +277,29 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map269 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map269.size)); - for (int _i270 = 0; - (_map269.size < 0) ? iprot.peekMap() : (_i270 < _map269.size); - ++_i270) + TMap _map243 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map243.size)); + for (int _i244 = 0; + (_map243.size < 0) ? iprot.peekMap() : (_i244 < _map243.size); + ++_i244) { - int _key271; - List _val272; - _key271 = iprot.readI32(); + int _key245; + List _val246; + _key245 = iprot.readI32(); { - TList _list273 = iprot.readListBegin(); - _val272 = new ArrayList(Math.max(0, _list273.size)); - for (int _i274 = 0; - (_list273.size < 0) ? iprot.peekList() : (_i274 < _list273.size); - ++_i274) + TList _list247 = iprot.readListBegin(); + _val246 = new ArrayList(Math.max(0, _list247.size)); + for (int _i248 = 0; + (_list247.size < 0) ? iprot.peekList() : (_i248 < _list247.size); + ++_i248) { - byte[] _elem275; - _elem275 = iprot.readBinary(); - _val272.add(_elem275); + byte[] _elem249; + _elem249 = iprot.readBinary(); + _val246.add(_elem249); } iprot.readListEnd(); } - this.parts.put(_key271, _val272); + this.parts.put(_key245, _val246); } iprot.readMapEnd(); } @@ -331,12 +331,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter276 : this.parts.entrySet()) { - oprot.writeI32(_iter276.getKey()); + for (Map.Entry> _iter250 : this.parts.entrySet()) { + oprot.writeI32(_iter250.getKey()); { - oprot.writeListBegin(new TList(TType.STRING, _iter276.getValue().size())); - for (byte[] _iter277 : _iter276.getValue()) { - oprot.writeBinary(_iter277); + oprot.writeListBegin(new TList(TType.STRING, _iter250.getValue().size())); + for (byte[] _iter251 : _iter250.getValue()) { + oprot.writeBinary(_iter251); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java index f715bcaa8..c3947fc5e 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java @@ -339,15 +339,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list238 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list238.size)); - for (int _i239 = 0; - (_list238.size < 0) ? iprot.peekList() : (_i239 < _list238.size); - ++_i239) + TList _list269 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list269.size)); + for (int _i270 = 0; + (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); + ++_i270) { - int _elem240; - _elem240 = iprot.readI32(); - this.parts.add(_elem240); + int _elem271; + _elem271 = iprot.readI32(); + this.parts.add(_elem271); } iprot.readListEnd(); } @@ -387,8 +387,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter241 : this.parts) { - oprot.writeI32(_iter241); + for (int _iter272 : this.parts) { + oprot.writeI32(_iter272); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ResponseCommon.java b/client/src/main/generated/com/vesoft/nebula/storage/ResponseCommon.java index 45f84e544..0a2e14d92 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ResponseCommon.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ResponseCommon.java @@ -27,11 +27,11 @@ public class ResponseCommon implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("ResponseCommon"); private static final TField FAILED_PARTS_FIELD_DESC = new TField("failed_parts", TType.LIST, (short)1); - private static final TField LATENCY_IN_US_FIELD_DESC = new TField("latency_in_us", TType.I32, (short)2); + private static final TField LATENCY_IN_US_FIELD_DESC = new TField("latency_in_us", TType.I64, (short)2); private static final TField LATENCY_DETAIL_US_FIELD_DESC = new TField("latency_detail_us", TType.MAP, (short)3); public List failed_parts; - public int latency_in_us; + public long latency_in_us; public Map latency_detail_us; public static final int FAILED_PARTS = 1; public static final int LATENCY_IN_US = 2; @@ -49,7 +49,7 @@ public class ResponseCommon implements TBase, java.io.Serializable, Cloneable, C new ListMetaData(TType.LIST, new StructMetaData(TType.STRUCT, PartitionResult.class)))); tmpMetaDataMap.put(LATENCY_IN_US, new FieldMetaData("latency_in_us", TFieldRequirementType.REQUIRED, - new FieldValueMetaData(TType.I32))); + new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(LATENCY_DETAIL_US, new FieldMetaData("latency_detail_us", TFieldRequirementType.OPTIONAL, new MapMetaData(TType.MAP, new FieldValueMetaData(TType.STRING), @@ -66,7 +66,7 @@ public ResponseCommon() { public ResponseCommon( List failed_parts, - int latency_in_us) { + long latency_in_us) { this(); this.failed_parts = failed_parts; this.latency_in_us = latency_in_us; @@ -75,7 +75,7 @@ public ResponseCommon( public ResponseCommon( List failed_parts, - int latency_in_us, + long latency_in_us, Map latency_detail_us) { this(); this.failed_parts = failed_parts; @@ -86,7 +86,7 @@ public ResponseCommon( public static class Builder { private List failed_parts; - private int latency_in_us; + private long latency_in_us; private Map latency_detail_us; BitSet __optional_isset = new BitSet(1); @@ -99,7 +99,7 @@ public Builder setFailed_parts(final List failed_parts) { return this; } - public Builder setLatency_in_us(final int latency_in_us) { + public Builder setLatency_in_us(final long latency_in_us) { this.latency_in_us = latency_in_us; __optional_isset.set(__LATENCY_IN_US_ISSET_ID, true); return this; @@ -168,11 +168,11 @@ public void setFailed_partsIsSet(boolean __value) { } } - public int getLatency_in_us() { + public long getLatency_in_us() { return this.latency_in_us; } - public ResponseCommon setLatency_in_us(int latency_in_us) { + public ResponseCommon setLatency_in_us(long latency_in_us) { this.latency_in_us = latency_in_us; setLatency_in_usIsSet(true); return this; @@ -230,7 +230,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetLatency_in_us(); } else { - setLatency_in_us((Integer)__value); + setLatency_in_us((Long)__value); } break; @@ -253,7 +253,7 @@ public Object getFieldValue(int fieldID) { return getFailed_parts(); case LATENCY_IN_US: - return new Integer(getLatency_in_us()); + return new Long(getLatency_in_us()); case LATENCY_DETAIL_US: return getLatency_detail_us(); @@ -358,8 +358,8 @@ public void read(TProtocol iprot) throws TException { } break; case LATENCY_IN_US: - if (__field.type == TType.I32) { - this.latency_in_us = iprot.readI32(); + if (__field.type == TType.I64) { + this.latency_in_us = iprot.readI64(); setLatency_in_usIsSet(true); } else { TProtocolUtil.skip(iprot, __field.type); @@ -418,7 +418,7 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } oprot.writeFieldBegin(LATENCY_IN_US_FIELD_DESC); - oprot.writeI32(this.latency_in_us); + oprot.writeI64(this.latency_in_us); oprot.writeFieldEnd(); if (this.latency_detail_us != null) { if (isSetLatency_detail_us()) { diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java index 163c33195..0f3c4fd3a 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeRequest.java @@ -28,7 +28,7 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, private static final TStruct STRUCT_DESC = new TStruct("ScanEdgeRequest"); private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); - private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.STRUCT, (short)3); + private static final TField RETURN_COLUMNS_FIELD_DESC = new TField("return_columns", TType.LIST, (short)3); private static final TField LIMIT_FIELD_DESC = new TField("limit", TType.I64, (short)4); private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)5); private static final TField END_TIME_FIELD_DESC = new TField("end_time", TType.I64, (short)6); @@ -39,7 +39,7 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, public int space_id; public Map parts; - public EdgeProp return_columns; + public List return_columns; public long limit; public long start_time; public long end_time; @@ -78,7 +78,8 @@ public class ScanEdgeRequest implements TBase, java.io.Serializable, Cloneable, new FieldValueMetaData(TType.I32), new StructMetaData(TType.STRUCT, ScanCursor.class)))); tmpMetaDataMap.put(RETURN_COLUMNS, new FieldMetaData("return_columns", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, EdgeProp.class))); + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, EdgeProp.class)))); tmpMetaDataMap.put(LIMIT, new FieldMetaData("limit", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(START_TIME, new FieldMetaData("start_time", TFieldRequirementType.OPTIONAL, @@ -110,7 +111,7 @@ public ScanEdgeRequest() { public ScanEdgeRequest( int space_id, Map parts, - EdgeProp return_columns, + List return_columns, long limit, boolean only_latest_version, boolean enable_read_from_follower) { @@ -130,7 +131,7 @@ public ScanEdgeRequest( public ScanEdgeRequest( int space_id, Map parts, - EdgeProp return_columns, + List return_columns, long limit, long start_time, long end_time, @@ -160,7 +161,7 @@ public ScanEdgeRequest( public static class Builder { private int space_id; private Map parts; - private EdgeProp return_columns; + private List return_columns; private long limit; private long start_time; private long end_time; @@ -185,7 +186,7 @@ public Builder setParts(final Map parts) { return this; } - public Builder setReturn_columns(final EdgeProp return_columns) { + public Builder setReturn_columns(final List return_columns) { this.return_columns = return_columns; return this; } @@ -339,11 +340,11 @@ public void setPartsIsSet(boolean __value) { } } - public EdgeProp getReturn_columns() { + public List getReturn_columns() { return this.return_columns; } - public ScanEdgeRequest setReturn_columns(EdgeProp return_columns) { + public ScanEdgeRequest setReturn_columns(List return_columns) { this.return_columns = return_columns; return this; } @@ -549,7 +550,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReturn_columns(); } else { - setReturn_columns((EdgeProp)__value); + setReturn_columns((List)__value); } break; @@ -806,18 +807,18 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map203 = iprot.readMapBegin(); - this.parts = new HashMap(Math.max(0, 2*_map203.size)); - for (int _i204 = 0; - (_map203.size < 0) ? iprot.peekMap() : (_i204 < _map203.size); - ++_i204) + TMap _map198 = iprot.readMapBegin(); + this.parts = new HashMap(Math.max(0, 2*_map198.size)); + for (int _i199 = 0; + (_map198.size < 0) ? iprot.peekMap() : (_i199 < _map198.size); + ++_i199) { - int _key205; - ScanCursor _val206; - _key205 = iprot.readI32(); - _val206 = new ScanCursor(); - _val206.read(iprot); - this.parts.put(_key205, _val206); + int _key200; + ScanCursor _val201; + _key200 = iprot.readI32(); + _val201 = new ScanCursor(); + _val201.read(iprot); + this.parts.put(_key200, _val201); } iprot.readMapEnd(); } @@ -826,9 +827,21 @@ public void read(TProtocol iprot) throws TException { } break; case RETURN_COLUMNS: - if (__field.type == TType.STRUCT) { - this.return_columns = new EdgeProp(); - this.return_columns.read(iprot); + if (__field.type == TType.LIST) { + { + TList _list202 = iprot.readListBegin(); + this.return_columns = new ArrayList(Math.max(0, _list202.size)); + for (int _i203 = 0; + (_list202.size < 0) ? iprot.peekList() : (_i203 < _list202.size); + ++_i203) + { + EdgeProp _elem204; + _elem204 = new EdgeProp(); + _elem204.read(iprot); + this.return_columns.add(_elem204); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -912,9 +925,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.parts.size())); - for (Map.Entry _iter207 : this.parts.entrySet()) { - oprot.writeI32(_iter207.getKey()); - _iter207.getValue().write(oprot); + for (Map.Entry _iter205 : this.parts.entrySet()) { + oprot.writeI32(_iter205.getKey()); + _iter205.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -922,7 +935,13 @@ public void write(TProtocol oprot) throws TException { } if (this.return_columns != null) { oprot.writeFieldBegin(RETURN_COLUMNS_FIELD_DESC); - this.return_columns.write(oprot); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.return_columns.size())); + for (EdgeProp _iter206 : this.return_columns) { + _iter206.write(oprot); + } + oprot.writeListEnd(); + } oprot.writeFieldEnd(); } oprot.writeFieldBegin(LIMIT_FIELD_DESC); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanResponse.java new file mode 100644 index 000000000..9f3d1e93f --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanResponse.java @@ -0,0 +1,445 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ScanResponse implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ScanResponse"); + private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); + private static final TField PROPS_FIELD_DESC = new TField("props", TType.STRUCT, (short)2); + private static final TField CURSORS_FIELD_DESC = new TField("cursors", TType.MAP, (short)3); + + public ResponseCommon result; + public com.vesoft.nebula.DataSet props; + public Map cursors; + public static final int RESULT = 1; + public static final int PROPS = 2; + public static final int CURSORS = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, + new StructMetaData(TType.STRUCT, ResponseCommon.class))); + tmpMetaDataMap.put(PROPS, new FieldMetaData("props", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); + tmpMetaDataMap.put(CURSORS, new FieldMetaData("cursors", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, ScanCursor.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ScanResponse.class, metaDataMap); + } + + public ScanResponse() { + } + + public ScanResponse( + ResponseCommon result) { + this(); + this.result = result; + } + + public ScanResponse( + ResponseCommon result, + Map cursors) { + this(); + this.result = result; + this.cursors = cursors; + } + + public ScanResponse( + ResponseCommon result, + com.vesoft.nebula.DataSet props, + Map cursors) { + this(); + this.result = result; + this.props = props; + this.cursors = cursors; + } + + public static class Builder { + private ResponseCommon result; + private com.vesoft.nebula.DataSet props; + private Map cursors; + + public Builder() { + } + + public Builder setResult(final ResponseCommon result) { + this.result = result; + return this; + } + + public Builder setProps(final com.vesoft.nebula.DataSet props) { + this.props = props; + return this; + } + + public Builder setCursors(final Map cursors) { + this.cursors = cursors; + return this; + } + + public ScanResponse build() { + ScanResponse result = new ScanResponse(); + result.setResult(this.result); + result.setProps(this.props); + result.setCursors(this.cursors); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ScanResponse(ScanResponse other) { + if (other.isSetResult()) { + this.result = TBaseHelper.deepCopy(other.result); + } + if (other.isSetProps()) { + this.props = TBaseHelper.deepCopy(other.props); + } + if (other.isSetCursors()) { + this.cursors = TBaseHelper.deepCopy(other.cursors); + } + } + + public ScanResponse deepCopy() { + return new ScanResponse(this); + } + + public ResponseCommon getResult() { + return this.result; + } + + public ScanResponse setResult(ResponseCommon result) { + this.result = result; + return this; + } + + public void unsetResult() { + this.result = null; + } + + // Returns true if field result is set (has been assigned a value) and false otherwise + public boolean isSetResult() { + return this.result != null; + } + + public void setResultIsSet(boolean __value) { + if (!__value) { + this.result = null; + } + } + + public com.vesoft.nebula.DataSet getProps() { + return this.props; + } + + public ScanResponse setProps(com.vesoft.nebula.DataSet props) { + this.props = props; + return this; + } + + public void unsetProps() { + this.props = null; + } + + // Returns true if field props is set (has been assigned a value) and false otherwise + public boolean isSetProps() { + return this.props != null; + } + + public void setPropsIsSet(boolean __value) { + if (!__value) { + this.props = null; + } + } + + public Map getCursors() { + return this.cursors; + } + + public ScanResponse setCursors(Map cursors) { + this.cursors = cursors; + return this; + } + + public void unsetCursors() { + this.cursors = null; + } + + // Returns true if field cursors is set (has been assigned a value) and false otherwise + public boolean isSetCursors() { + return this.cursors != null; + } + + public void setCursorsIsSet(boolean __value) { + if (!__value) { + this.cursors = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case RESULT: + if (__value == null) { + unsetResult(); + } else { + setResult((ResponseCommon)__value); + } + break; + + case PROPS: + if (__value == null) { + unsetProps(); + } else { + setProps((com.vesoft.nebula.DataSet)__value); + } + break; + + case CURSORS: + if (__value == null) { + unsetCursors(); + } else { + setCursors((Map)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case RESULT: + return getResult(); + + case PROPS: + return getProps(); + + case CURSORS: + return getCursors(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ScanResponse)) + return false; + ScanResponse that = (ScanResponse)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetProps(), that.isSetProps(), this.props, that.props)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetCursors(), that.isSetCursors(), this.cursors, that.cursors)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {result, props, cursors}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case RESULT: + if (__field.type == TType.STRUCT) { + this.result = new ResponseCommon(); + this.result.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PROPS: + if (__field.type == TType.STRUCT) { + this.props = new com.vesoft.nebula.DataSet(); + this.props.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case CURSORS: + if (__field.type == TType.MAP) { + { + TMap _map207 = iprot.readMapBegin(); + this.cursors = new HashMap(Math.max(0, 2*_map207.size)); + for (int _i208 = 0; + (_map207.size < 0) ? iprot.peekMap() : (_i208 < _map207.size); + ++_i208) + { + int _key209; + ScanCursor _val210; + _key209 = iprot.readI32(); + _val210 = new ScanCursor(); + _val210.read(iprot); + this.cursors.put(_key209, _val210); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.result != null) { + oprot.writeFieldBegin(RESULT_FIELD_DESC); + this.result.write(oprot); + oprot.writeFieldEnd(); + } + if (this.props != null) { + if (isSetProps()) { + oprot.writeFieldBegin(PROPS_FIELD_DESC); + this.props.write(oprot); + oprot.writeFieldEnd(); + } + } + if (this.cursors != null) { + oprot.writeFieldBegin(CURSORS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.cursors.size())); + for (Map.Entry _iter211 : this.cursors.entrySet()) { + oprot.writeI32(_iter211.getKey()); + _iter211.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ScanResponse"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("result"); + sb.append(space); + sb.append(":").append(space); + if (this.getResult() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); + } + first = false; + if (isSetProps()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("props"); + sb.append(space); + sb.append(":").append(space); + if (this.getProps() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getProps(), indent + 1, prettyPrint)); + } + first = false; + } + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("cursors"); + sb.append(space); + sb.append(":").append(space); + if (this.getCursors() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getCursors(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (result == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java index 026a16de0..4374a8cd4 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java @@ -868,17 +868,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler424) throws TException { + public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler441) throws TException { checkReady(); - transLeader_call method_call = new transLeader_call(req, resultHandler424, this, ___protocolFactory, ___transport); + transLeader_call method_call = new transLeader_call(req, resultHandler441, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class transLeader_call extends TAsyncMethodCall { private TransLeaderReq req; - public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler425, TAsyncClient client421, TProtocolFactory protocolFactory422, TNonblockingTransport transport423) throws TException { - super(client421, protocolFactory422, transport423, resultHandler425, false); + public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler442, TAsyncClient client438, TProtocolFactory protocolFactory439, TNonblockingTransport transport440) throws TException { + super(client438, protocolFactory439, transport440, resultHandler442, false); this.req = req; } @@ -900,17 +900,17 @@ public AdminExecResp getResult() throws TException { } } - public void addPart(AddPartReq req, AsyncMethodCallback resultHandler429) throws TException { + public void addPart(AddPartReq req, AsyncMethodCallback resultHandler446) throws TException { checkReady(); - addPart_call method_call = new addPart_call(req, resultHandler429, this, ___protocolFactory, ___transport); + addPart_call method_call = new addPart_call(req, resultHandler446, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addPart_call extends TAsyncMethodCall { private AddPartReq req; - public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler430, TAsyncClient client426, TProtocolFactory protocolFactory427, TNonblockingTransport transport428) throws TException { - super(client426, protocolFactory427, transport428, resultHandler430, false); + public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler447, TAsyncClient client443, TProtocolFactory protocolFactory444, TNonblockingTransport transport445) throws TException { + super(client443, protocolFactory444, transport445, resultHandler447, false); this.req = req; } @@ -932,17 +932,17 @@ public AdminExecResp getResult() throws TException { } } - public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler434) throws TException { + public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler451) throws TException { checkReady(); - addLearner_call method_call = new addLearner_call(req, resultHandler434, this, ___protocolFactory, ___transport); + addLearner_call method_call = new addLearner_call(req, resultHandler451, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addLearner_call extends TAsyncMethodCall { private AddLearnerReq req; - public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler435, TAsyncClient client431, TProtocolFactory protocolFactory432, TNonblockingTransport transport433) throws TException { - super(client431, protocolFactory432, transport433, resultHandler435, false); + public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler452, TAsyncClient client448, TProtocolFactory protocolFactory449, TNonblockingTransport transport450) throws TException { + super(client448, protocolFactory449, transport450, resultHandler452, false); this.req = req; } @@ -964,17 +964,17 @@ public AdminExecResp getResult() throws TException { } } - public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler439) throws TException { + public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler456) throws TException { checkReady(); - removePart_call method_call = new removePart_call(req, resultHandler439, this, ___protocolFactory, ___transport); + removePart_call method_call = new removePart_call(req, resultHandler456, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removePart_call extends TAsyncMethodCall { private RemovePartReq req; - public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler440, TAsyncClient client436, TProtocolFactory protocolFactory437, TNonblockingTransport transport438) throws TException { - super(client436, protocolFactory437, transport438, resultHandler440, false); + public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler457, TAsyncClient client453, TProtocolFactory protocolFactory454, TNonblockingTransport transport455) throws TException { + super(client453, protocolFactory454, transport455, resultHandler457, false); this.req = req; } @@ -996,17 +996,17 @@ public AdminExecResp getResult() throws TException { } } - public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler444) throws TException { + public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler461) throws TException { checkReady(); - memberChange_call method_call = new memberChange_call(req, resultHandler444, this, ___protocolFactory, ___transport); + memberChange_call method_call = new memberChange_call(req, resultHandler461, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class memberChange_call extends TAsyncMethodCall { private MemberChangeReq req; - public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler445, TAsyncClient client441, TProtocolFactory protocolFactory442, TNonblockingTransport transport443) throws TException { - super(client441, protocolFactory442, transport443, resultHandler445, false); + public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler462, TAsyncClient client458, TProtocolFactory protocolFactory459, TNonblockingTransport transport460) throws TException { + super(client458, protocolFactory459, transport460, resultHandler462, false); this.req = req; } @@ -1028,17 +1028,17 @@ public AdminExecResp getResult() throws TException { } } - public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler449) throws TException { + public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler466) throws TException { checkReady(); - waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler449, this, ___protocolFactory, ___transport); + waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler466, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class waitingForCatchUpData_call extends TAsyncMethodCall { private CatchUpDataReq req; - public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler450, TAsyncClient client446, TProtocolFactory protocolFactory447, TNonblockingTransport transport448) throws TException { - super(client446, protocolFactory447, transport448, resultHandler450, false); + public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler467, TAsyncClient client463, TProtocolFactory protocolFactory464, TNonblockingTransport transport465) throws TException { + super(client463, protocolFactory464, transport465, resultHandler467, false); this.req = req; } @@ -1060,17 +1060,17 @@ public AdminExecResp getResult() throws TException { } } - public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler454) throws TException { + public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler471) throws TException { checkReady(); - createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler454, this, ___protocolFactory, ___transport); + createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler471, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createCheckpoint_call extends TAsyncMethodCall { private CreateCPRequest req; - public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler455, TAsyncClient client451, TProtocolFactory protocolFactory452, TNonblockingTransport transport453) throws TException { - super(client451, protocolFactory452, transport453, resultHandler455, false); + public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler472, TAsyncClient client468, TProtocolFactory protocolFactory469, TNonblockingTransport transport470) throws TException { + super(client468, protocolFactory469, transport470, resultHandler472, false); this.req = req; } @@ -1092,17 +1092,17 @@ public CreateCPResp getResult() throws TException { } } - public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler459) throws TException { + public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler476) throws TException { checkReady(); - dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler459, this, ___protocolFactory, ___transport); + dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler476, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropCheckpoint_call extends TAsyncMethodCall { private DropCPRequest req; - public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler460, TAsyncClient client456, TProtocolFactory protocolFactory457, TNonblockingTransport transport458) throws TException { - super(client456, protocolFactory457, transport458, resultHandler460, false); + public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler477, TAsyncClient client473, TProtocolFactory protocolFactory474, TNonblockingTransport transport475) throws TException { + super(client473, protocolFactory474, transport475, resultHandler477, false); this.req = req; } @@ -1124,17 +1124,17 @@ public AdminExecResp getResult() throws TException { } } - public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler464) throws TException { + public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler481) throws TException { checkReady(); - blockingWrites_call method_call = new blockingWrites_call(req, resultHandler464, this, ___protocolFactory, ___transport); + blockingWrites_call method_call = new blockingWrites_call(req, resultHandler481, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class blockingWrites_call extends TAsyncMethodCall { private BlockingSignRequest req; - public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler465, TAsyncClient client461, TProtocolFactory protocolFactory462, TNonblockingTransport transport463) throws TException { - super(client461, protocolFactory462, transport463, resultHandler465, false); + public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler482, TAsyncClient client478, TProtocolFactory protocolFactory479, TNonblockingTransport transport480) throws TException { + super(client478, protocolFactory479, transport480, resultHandler482, false); this.req = req; } @@ -1156,17 +1156,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler469) throws TException { + public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler486) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler469, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler486, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler470, TAsyncClient client466, TProtocolFactory protocolFactory467, TNonblockingTransport transport468) throws TException { - super(client466, protocolFactory467, transport468, resultHandler470, false); + public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler487, TAsyncClient client483, TProtocolFactory protocolFactory484, TNonblockingTransport transport485) throws TException { + super(client483, protocolFactory484, transport485, resultHandler487, false); this.req = req; } @@ -1188,17 +1188,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler474) throws TException { + public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler491) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler474, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler491, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler475, TAsyncClient client471, TProtocolFactory protocolFactory472, TNonblockingTransport transport473) throws TException { - super(client471, protocolFactory472, transport473, resultHandler475, false); + public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler492, TAsyncClient client488, TProtocolFactory protocolFactory489, TNonblockingTransport transport490) throws TException { + super(client488, protocolFactory489, transport490, resultHandler492, false); this.req = req; } @@ -1220,17 +1220,17 @@ public AdminExecResp getResult() throws TException { } } - public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler479) throws TException { + public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler496) throws TException { checkReady(); - getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler479, this, ___protocolFactory, ___transport); + getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler496, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getLeaderParts_call extends TAsyncMethodCall { private GetLeaderReq req; - public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler480, TAsyncClient client476, TProtocolFactory protocolFactory477, TNonblockingTransport transport478) throws TException { - super(client476, protocolFactory477, transport478, resultHandler480, false); + public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler497, TAsyncClient client493, TProtocolFactory protocolFactory494, TNonblockingTransport transport495) throws TException { + super(client493, protocolFactory494, transport495, resultHandler497, false); this.req = req; } @@ -1252,17 +1252,17 @@ public GetLeaderPartsResp getResult() throws TException { } } - public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler484) throws TException { + public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler501) throws TException { checkReady(); - checkPeers_call method_call = new checkPeers_call(req, resultHandler484, this, ___protocolFactory, ___transport); + checkPeers_call method_call = new checkPeers_call(req, resultHandler501, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class checkPeers_call extends TAsyncMethodCall { private CheckPeersReq req; - public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler485, TAsyncClient client481, TProtocolFactory protocolFactory482, TNonblockingTransport transport483) throws TException { - super(client481, protocolFactory482, transport483, resultHandler485, false); + public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler502, TAsyncClient client498, TProtocolFactory protocolFactory499, TNonblockingTransport transport500) throws TException { + super(client498, protocolFactory499, transport500, resultHandler502, false); this.req = req; } @@ -1284,17 +1284,17 @@ public AdminExecResp getResult() throws TException { } } - public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler489) throws TException { + public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler506) throws TException { checkReady(); - addAdminTask_call method_call = new addAdminTask_call(req, resultHandler489, this, ___protocolFactory, ___transport); + addAdminTask_call method_call = new addAdminTask_call(req, resultHandler506, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addAdminTask_call extends TAsyncMethodCall { private AddAdminTaskRequest req; - public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler490, TAsyncClient client486, TProtocolFactory protocolFactory487, TNonblockingTransport transport488) throws TException { - super(client486, protocolFactory487, transport488, resultHandler490, false); + public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler507, TAsyncClient client503, TProtocolFactory protocolFactory504, TNonblockingTransport transport505) throws TException { + super(client503, protocolFactory504, transport505, resultHandler507, false); this.req = req; } @@ -1316,17 +1316,17 @@ public AdminExecResp getResult() throws TException { } } - public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler494) throws TException { + public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler511) throws TException { checkReady(); - stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler494, this, ___protocolFactory, ___transport); + stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler511, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class stopAdminTask_call extends TAsyncMethodCall { private StopAdminTaskRequest req; - public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler495, TAsyncClient client491, TProtocolFactory protocolFactory492, TNonblockingTransport transport493) throws TException { - super(client491, protocolFactory492, transport493, resultHandler495, false); + public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler512, TAsyncClient client508, TProtocolFactory protocolFactory509, TNonblockingTransport transport510) throws TException { + super(client508, protocolFactory509, transport510, resultHandler512, false); this.req = req; } @@ -1348,17 +1348,17 @@ public AdminExecResp getResult() throws TException { } } - public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler499) throws TException { + public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler516) throws TException { checkReady(); - listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler499, this, ___protocolFactory, ___transport); + listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler516, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listClusterInfo_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler500, TAsyncClient client496, TProtocolFactory protocolFactory497, TNonblockingTransport transport498) throws TException { - super(client496, protocolFactory497, transport498, resultHandler500, false); + public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler517, TAsyncClient client513, TProtocolFactory protocolFactory514, TNonblockingTransport transport515) throws TException { + super(client513, protocolFactory514, transport515, resultHandler517, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java b/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java index 7ba6a574d..e7997f34c 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/TaskPara.java @@ -28,14 +28,14 @@ public class TaskPara implements TBase, java.io.Serializable, Cloneable, Compara private static final TStruct STRUCT_DESC = new TStruct("TaskPara"); private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); private static final TField PARTS_FIELD_DESC = new TField("parts", TType.LIST, (short)2); - private static final TField TASK_SPECFIC_PARAS_FIELD_DESC = new TField("task_specfic_paras", TType.LIST, (short)3); + private static final TField TASK_SPECIFIC_PARAS_FIELD_DESC = new TField("task_specific_paras", TType.LIST, (short)3); public int space_id; public List parts; - public List task_specfic_paras; + public List task_specific_paras; public static final int SPACE_ID = 1; public static final int PARTS = 2; - public static final int TASK_SPECFIC_PARAS = 3; + public static final int TASK_SPECIFIC_PARAS = 3; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; @@ -50,7 +50,7 @@ public class TaskPara implements TBase, java.io.Serializable, Cloneable, Compara tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.OPTIONAL, new ListMetaData(TType.LIST, new FieldValueMetaData(TType.I32)))); - tmpMetaDataMap.put(TASK_SPECFIC_PARAS, new FieldMetaData("task_specfic_paras", TFieldRequirementType.OPTIONAL, + tmpMetaDataMap.put(TASK_SPECIFIC_PARAS, new FieldMetaData("task_specific_paras", TFieldRequirementType.OPTIONAL, new ListMetaData(TType.LIST, new FieldValueMetaData(TType.STRING)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -73,18 +73,18 @@ public TaskPara( public TaskPara( int space_id, List parts, - List task_specfic_paras) { + List task_specific_paras) { this(); this.space_id = space_id; setSpace_idIsSet(true); this.parts = parts; - this.task_specfic_paras = task_specfic_paras; + this.task_specific_paras = task_specific_paras; } public static class Builder { private int space_id; private List parts; - private List task_specfic_paras; + private List task_specific_paras; BitSet __optional_isset = new BitSet(1); @@ -102,8 +102,8 @@ public Builder setParts(final List parts) { return this; } - public Builder setTask_specfic_paras(final List task_specfic_paras) { - this.task_specfic_paras = task_specfic_paras; + public Builder setTask_specific_paras(final List task_specific_paras) { + this.task_specific_paras = task_specific_paras; return this; } @@ -113,7 +113,7 @@ public TaskPara build() { result.setSpace_id(this.space_id); } result.setParts(this.parts); - result.setTask_specfic_paras(this.task_specfic_paras); + result.setTask_specific_paras(this.task_specific_paras); return result; } } @@ -132,8 +132,8 @@ public TaskPara(TaskPara other) { if (other.isSetParts()) { this.parts = TBaseHelper.deepCopy(other.parts); } - if (other.isSetTask_specfic_paras()) { - this.task_specfic_paras = TBaseHelper.deepCopy(other.task_specfic_paras); + if (other.isSetTask_specific_paras()) { + this.task_specific_paras = TBaseHelper.deepCopy(other.task_specific_paras); } } @@ -188,27 +188,27 @@ public void setPartsIsSet(boolean __value) { } } - public List getTask_specfic_paras() { - return this.task_specfic_paras; + public List getTask_specific_paras() { + return this.task_specific_paras; } - public TaskPara setTask_specfic_paras(List task_specfic_paras) { - this.task_specfic_paras = task_specfic_paras; + public TaskPara setTask_specific_paras(List task_specific_paras) { + this.task_specific_paras = task_specific_paras; return this; } - public void unsetTask_specfic_paras() { - this.task_specfic_paras = null; + public void unsetTask_specific_paras() { + this.task_specific_paras = null; } - // Returns true if field task_specfic_paras is set (has been assigned a value) and false otherwise - public boolean isSetTask_specfic_paras() { - return this.task_specfic_paras != null; + // Returns true if field task_specific_paras is set (has been assigned a value) and false otherwise + public boolean isSetTask_specific_paras() { + return this.task_specific_paras != null; } - public void setTask_specfic_parasIsSet(boolean __value) { + public void setTask_specific_parasIsSet(boolean __value) { if (!__value) { - this.task_specfic_paras = null; + this.task_specific_paras = null; } } @@ -231,11 +231,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case TASK_SPECFIC_PARAS: + case TASK_SPECIFIC_PARAS: if (__value == null) { - unsetTask_specfic_paras(); + unsetTask_specific_paras(); } else { - setTask_specfic_paras((List)__value); + setTask_specific_paras((List)__value); } break; @@ -252,8 +252,8 @@ public Object getFieldValue(int fieldID) { case PARTS: return getParts(); - case TASK_SPECFIC_PARAS: - return getTask_specfic_paras(); + case TASK_SPECIFIC_PARAS: + return getTask_specific_paras(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -274,14 +274,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } - if (!TBaseHelper.equalsSlow(this.isSetTask_specfic_paras(), that.isSetTask_specfic_paras(), this.task_specfic_paras, that.task_specfic_paras)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetTask_specific_paras(), that.isSetTask_specific_paras(), this.task_specific_paras, that.task_specific_paras)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, parts, task_specfic_paras}); + return Arrays.deepHashCode(new Object[] {space_id, parts, task_specific_paras}); } @Override @@ -312,11 +312,11 @@ public int compareTo(TaskPara other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetTask_specfic_paras()).compareTo(other.isSetTask_specfic_paras()); + lastComparison = Boolean.valueOf(isSetTask_specific_paras()).compareTo(other.isSetTask_specific_paras()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(task_specfic_paras, other.task_specfic_paras); + lastComparison = TBaseHelper.compareTo(task_specific_paras, other.task_specific_paras); if (lastComparison != 0) { return lastComparison; } @@ -345,15 +345,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list213 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list213.size)); - for (int _i214 = 0; - (_list213.size < 0) ? iprot.peekList() : (_i214 < _list213.size); - ++_i214) + TList _list212 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list212.size)); + for (int _i213 = 0; + (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); + ++_i213) { - int _elem215; - _elem215 = iprot.readI32(); - this.parts.add(_elem215); + int _elem214; + _elem214 = iprot.readI32(); + this.parts.add(_elem214); } iprot.readListEnd(); } @@ -361,18 +361,18 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case TASK_SPECFIC_PARAS: + case TASK_SPECIFIC_PARAS: if (__field.type == TType.LIST) { { - TList _list216 = iprot.readListBegin(); - this.task_specfic_paras = new ArrayList(Math.max(0, _list216.size)); - for (int _i217 = 0; - (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); - ++_i217) + TList _list215 = iprot.readListBegin(); + this.task_specific_paras = new ArrayList(Math.max(0, _list215.size)); + for (int _i216 = 0; + (_list215.size < 0) ? iprot.peekList() : (_i216 < _list215.size); + ++_i216) { - byte[] _elem218; - _elem218 = iprot.readBinary(); - this.task_specfic_paras.add(_elem218); + byte[] _elem217; + _elem217 = iprot.readBinary(); + this.task_specific_paras.add(_elem217); } iprot.readListEnd(); } @@ -405,21 +405,21 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter219 : this.parts) { - oprot.writeI32(_iter219); + for (int _iter218 : this.parts) { + oprot.writeI32(_iter218); } oprot.writeListEnd(); } oprot.writeFieldEnd(); } } - if (this.task_specfic_paras != null) { - if (isSetTask_specfic_paras()) { - oprot.writeFieldBegin(TASK_SPECFIC_PARAS_FIELD_DESC); + if (this.task_specific_paras != null) { + if (isSetTask_specific_paras()) { + oprot.writeFieldBegin(TASK_SPECIFIC_PARAS_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.STRING, this.task_specfic_paras.size())); - for (byte[] _iter220 : this.task_specfic_paras) { - oprot.writeBinary(_iter220); + oprot.writeListBegin(new TList(TType.STRING, this.task_specific_paras.size())); + for (byte[] _iter219 : this.task_specific_paras) { + oprot.writeBinary(_iter219); } oprot.writeListEnd(); } @@ -466,17 +466,17 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } - if (isSetTask_specfic_paras()) + if (isSetTask_specific_paras()) { if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("task_specfic_paras"); + sb.append("task_specific_paras"); sb.append(space); sb.append(":").append(space); - if (this.getTask_specfic_paras() == null) { + if (this.getTask_specific_paras() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getTask_specfic_paras(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getTask_specific_paras(), indent + 1, prettyPrint)); } first = false; } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java index a8a8c71dc..3c0eae429 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/ResultSet.java @@ -201,7 +201,7 @@ public String getComment() { * get latency of the query execute time * @return int */ - public int getLatency() { + public long getLatency() { return response.latency_in_us; } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java index a3884cea5..6794818b5 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java @@ -19,6 +19,7 @@ import com.vesoft.nebula.storage.GraphStorageService; import com.vesoft.nebula.storage.ScanEdgeRequest; import com.vesoft.nebula.storage.ScanEdgeResponse; +import com.vesoft.nebula.storage.ScanResponse; import com.vesoft.nebula.storage.ScanVertexRequest; import com.vesoft.nebula.storage.ScanVertexResponse; import com.vesoft.nebula.util.SslUtil; @@ -73,11 +74,11 @@ protected GraphStorageConnection open(HostAddress address, int timeout, boolean } - public ScanVertexResponse scanVertex(ScanVertexRequest request) throws TException { + public ScanResponse scanVertex(ScanVertexRequest request) throws TException { return client.scanVertex(request); } - public ScanEdgeResponse scanEdge(ScanEdgeRequest request) throws TException { + public ScanResponse scanEdge(ScanEdgeRequest request) throws TException { return client.scanEdge(request); } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java index d4444f6f1..0f8be86c6 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/StorageClient.java @@ -1035,11 +1035,12 @@ private ScanEdgeResultIterator scanEdge(String spaceName, long edgeId = getEdgeId(spaceName, edgeName); EdgeProp edgeCols = new EdgeProp((int) edgeId, props); + List edgeProps = Arrays.asList(edgeCols); ScanEdgeRequest request = new ScanEdgeRequest(); request .setSpace_id(getSpaceId(spaceName)) - .setReturn_columns(edgeCols) + .setReturn_columns(edgeProps) .setLimit(limit) .setStart_time(startTime) .setEnd_time(endTime) diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java b/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java index 3fdade027..5b058c700 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/processor/EdgeProcessor.java @@ -31,13 +31,25 @@ public static List constructEdgeRow(List dataSets, String deco if (values.size() < 3) { LOGGER.error("values size error for row: " + row.toString()); } else { - Value srcId = values.get(0); - Value dstId = values.get(1); - Value rank = values.get(2); + Value srcId = null; + Value dstId = null; + Value rank = null; Map props = Maps.newHashMap(); - for (int i = 3; i < values.size(); i++) { - String colName = new String(colNames.get(i)).split("\\.")[1]; - props.put(colName, new ValueWrapper(values.get(i), decodeType)); + for (int i = 0; i < values.size(); i++) { + String colName = new String(colNames.get(i)); + if (!colName.contains(".")) { + continue; + } + if ("_src".equals(colName.split("\\.")[1])) { + srcId = values.get(i); + } else if ("_dst".equals(colName.split("\\.")[1])) { + dstId = values.get(i); + } else if ("_rank".equals(colName.split("\\.")[1])) { + rank = values.get(i); + } else { + props.put(colName.split("\\.")[1], + new ValueWrapper(values.get(i), decodeType)); + } } EdgeRow edgeRow = new EdgeRow(new ValueWrapper(srcId, decodeType), new ValueWrapper(dstId, decodeType), rank.getIVal(), props); diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java b/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java index 7dbc63018..5415c243c 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/processor/VertexProcessor.java @@ -32,11 +32,19 @@ public static Map constructVertexRow(List data if (values.size() < 1) { LOGGER.error("values size error for row: " + row.toString()); } else { - Value vid = values.get(0); + Value vid = null; Map props = Maps.newHashMap(); - for (int i = 1; i < values.size(); i++) { - String colName = new String(colNames.get(i)).split("\\.")[1]; - props.put(colName, new ValueWrapper(values.get(i), decodeType)); + for (int i = 0; i < values.size(); i++) { + String colName = new String(colNames.get(i)); + if (!colName.contains(".")) { + continue; + } + if ("_vid".equals(colName.split("\\.")[1])) { + vid = values.get(i); + } else { + props.put(colName.split("\\.")[1], + new ValueWrapper(values.get(i), decodeType)); + } } VertexRow vertexRow = new VertexRow(new ValueWrapper(vid, decodeType), props); vidVertices.put(new ValueWrapper(vid, decodeType), vertexRow); @@ -54,7 +62,8 @@ public static List constructVertexTableRow(List dataSet for (Row row : rows) { List values = row.getValues(); List props = new ArrayList<>(); - for (int i = 0; i < values.size(); i++) { + // the first prop returned by server is vid, which is also contained in other cols. + for (int i = 1; i < values.size(); i++) { props.add(new ValueWrapper(values.get(i), decodeType)); } vertexRows.add(new VertexTableRow(props)); diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java index 4d6f5f7d8..6387d5455 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java @@ -15,11 +15,12 @@ public class PartScanInfo implements Serializable { private int part; private HostAddress leader; - private ScanCursor cursor = null; + private ScanCursor cursor; public PartScanInfo(int part, HostAddress leader) { this.part = part; this.leader = leader; + cursor = new ScanCursor(true, "".getBytes()); } public int getPart() { diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java index e2a98d461..eec686bf7 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResult.java @@ -157,8 +157,11 @@ private void constructPropNames() { if (propNames.isEmpty()) { List colNames = dataSets.get(0).getColumn_names(); for (byte[] colName : colNames) { - String name = new String(colName).split("\\.")[1]; - propNames.add(name); + String propName = new String(colName); + if (!propName.contains(".")) { + continue; + } + propNames.add(propName.split("\\.")[1]); } } } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java index 7c6d5c935..b221ef9f8 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java @@ -17,6 +17,7 @@ import com.vesoft.nebula.storage.ScanCursor; import com.vesoft.nebula.storage.ScanEdgeRequest; import com.vesoft.nebula.storage.ScanEdgeResponse; +import com.vesoft.nebula.storage.ScanResponse; import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; @@ -73,7 +74,7 @@ public ScanEdgeResult next() throws Exception { threadPool = Executors.newFixedThreadPool(addresses.size()); for (HostAddress addr : addresses) { threadPool.submit(() -> { - ScanEdgeResponse response; + ScanResponse response; PartScanInfo partInfo = partScanQueue.getPart(addr); // no part need to scan if (partInfo == null) { @@ -115,7 +116,7 @@ public ScanEdgeResult next() throws Exception { if (isSuccessful(response)) { handleSucceedResult(existSuccess, response, partInfo); - results.add(response.getEdge_data()); + results.add(response.getProps()); } if (response.getResult() != null) { @@ -159,36 +160,6 @@ public ScanEdgeResult next() throws Exception { } - private boolean isSuccessful(ScanEdgeResponse response) { - return response.result.failed_parts.size() == 0; - } - - private void handleSucceedResult(AtomicInteger existSuccess, ScanEdgeResponse response, - PartScanInfo partInfo) { - existSuccess.addAndGet(1); - if (!response.getCursors().get(partInfo.getPart()).has_next) { - partScanQueue.dropPart(partInfo); - } else { - partInfo.setCursor(response.getCursors().get(partInfo.getPart())); - } - } - - private void handleFailedResult(ScanEdgeResponse response, PartScanInfo partInfo, - List exceptions) { - for (PartitionResult partResult : response.getResult().getFailed_parts()) { - if (partResult.code == ErrorCode.E_LEADER_CHANGED) { - freshLeader(spaceName, partInfo.getPart(), partResult.getLeader()); - partInfo.setLeader(getLeader(partResult.getLeader())); - } else { - int code = partResult.getCode().getValue(); - LOGGER.error(String.format("part scan failed, error code=%d", code)); - partScanQueue.dropPart(partInfo); - exceptions.add(new Exception(String.format("part scan, error code=%d", code))); - } - } - } - - /** * builder to build {@link ScanEdgeResultIterator} */ diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java index 01327d38a..efd8e9612 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java @@ -5,16 +5,20 @@ package com.vesoft.nebula.client.storage.scan; +import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.HostAddr; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.meta.MetaManager; import com.vesoft.nebula.client.meta.exception.ExecuteFailedException; import com.vesoft.nebula.client.storage.StorageConnPool; +import com.vesoft.nebula.storage.PartitionResult; +import com.vesoft.nebula.storage.ScanResponse; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; +import java.util.concurrent.atomic.AtomicInteger; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -94,4 +98,33 @@ protected void throwExceptions(List exceptions) throws ExecuteFailedE } throw new ExecuteFailedException("no parts succeed, error message: " + errorMsg.toString()); } + + protected boolean isSuccessful(ScanResponse response) { + return response != null && response.result.failed_parts.size() <= 0; + } + + protected void handleSucceedResult(AtomicInteger existSuccess, ScanResponse response, + PartScanInfo partInfo) { + existSuccess.addAndGet(1); + if (!response.getCursors().get(partInfo.getPart()).has_next) { + partScanQueue.dropPart(partInfo); + } else { + partInfo.setCursor(response.getCursors().get(partInfo.getPart())); + } + } + + protected void handleFailedResult(ScanResponse response, PartScanInfo partInfo, + List exceptions) { + for (PartitionResult partResult : response.getResult().getFailed_parts()) { + if (partResult.code == ErrorCode.E_LEADER_CHANGED) { + freshLeader(spaceName, partInfo.getPart(), partResult.getLeader()); + partInfo.setLeader(getLeader(partResult.getLeader())); + } else { + int code = partResult.getCode().getValue(); + LOGGER.error(String.format("part scan failed, error code=%d", code)); + partScanQueue.dropPart(partInfo); + exceptions.add(new Exception(String.format("part scan, error code=%d", code))); + } + } + } } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java index 2bb72faf9..8b15218ef 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResult.java @@ -193,8 +193,11 @@ private void constructPropNames() { if (propNames.isEmpty()) { List colNames = dataSets.get(0).getColumn_names(); for (byte[] colName : colNames) { - String name = new String(colName).split("\\.")[1]; - propNames.add(name); + String propName = new String(colName); + if (!propName.contains(".")) { + continue; + } + propNames.add(propName.split("\\.")[1]); } } } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java index 1444b1785..10fa498c4 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java @@ -15,8 +15,8 @@ import com.vesoft.nebula.client.storage.data.ScanStatus; import com.vesoft.nebula.storage.PartitionResult; import com.vesoft.nebula.storage.ScanCursor; +import com.vesoft.nebula.storage.ScanResponse; import com.vesoft.nebula.storage.ScanVertexRequest; -import com.vesoft.nebula.storage.ScanVertexResponse; import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; @@ -76,7 +76,7 @@ public ScanVertexResult next() throws Exception { for (HostAddress addr : addresses) { threadPool.submit(() -> { - ScanVertexResponse response; + ScanResponse response; PartScanInfo partInfo = partScanQueue.getPart(addr); // no part need to scan if (partInfo == null) { @@ -117,7 +117,7 @@ public ScanVertexResult next() throws Exception { if (isSuccessful(response)) { handleSucceedResult(existSuccess, response, partInfo); - results.add(response.getVertex_data()); + results.add(response.getProps()); } if (response.getResult() != null) { @@ -160,34 +160,7 @@ public ScanVertexResult next() throws Exception { } - private boolean isSuccessful(ScanVertexResponse response) { - return response != null && response.result.failed_parts.size() <= 0; - } - - private void handleSucceedResult(AtomicInteger existSuccess, ScanVertexResponse response, - PartScanInfo partInfo) { - existSuccess.addAndGet(1); - if (!response.getCursors().get(partInfo.getPart()).has_next) { - partScanQueue.dropPart(partInfo); - } else { - partInfo.setCursor(response.getCursors().get(partInfo.getPart())); - } - } - private void handleFailedResult(ScanVertexResponse response, PartScanInfo partInfo, - List exceptions) { - for (PartitionResult partResult : response.getResult().getFailed_parts()) { - if (partResult.code == ErrorCode.E_LEADER_CHANGED) { - freshLeader(spaceName, partInfo.getPart(), partResult.getLeader()); - partInfo.setLeader(getLeader(partResult.getLeader())); - } else { - int code = partResult.getCode().getValue(); - LOGGER.error(String.format("part scan failed, error code=%d", code)); - partScanQueue.dropPart(partInfo); - exceptions.add(new Exception(String.format("part scan, error code=%d", code))); - } - } - } /** diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index 03bdb5615..326b18e78 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -60,7 +60,7 @@ public void setUp() throws Exception { + "CREATE TAG INDEX IF NOT EXISTS person_name_index ON person(name(8));" + "CREATE TAG IF NOT EXISTS any_shape(geo geography);"); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); - TimeUnit.SECONDS.sleep(6); + TimeUnit.SECONDS.sleep(10); String insertVertexes = "INSERT VERTEX person(name, age, grade,friends, book_num, " + "birthday, start_school, morning, property," + "is_girl, child_name, expend, first_out_city) VALUES " @@ -445,7 +445,7 @@ public void tesDataset() { "CREATE TAG IF NOT EXISTS player(name string, age int);" + "CREATE EDGE IF NOT EXISTS like(likeness int);"); Assert.assertTrue(result.getErrorMessage(), result.isSucceeded()); - TimeUnit.SECONDS.sleep(6); + TimeUnit.SECONDS.sleep(10); result = session.execute( "INSERT VERTEX player(name, age) values \"a\":(\"a\", 1); " + "INSERT VERTEX player(name, age) values \"b\":(\"b\", 2); " @@ -463,10 +463,11 @@ public void tesDataset() { + "INSERT EDGE like(likeness) values \"g\" -> \"c\":(10);"); Assert.assertTrue(result.getErrorMessage(), result.isSucceeded()); result = session.execute( - "FIND NOLOOP PATH FROM \"a\" TO \"c\" OVER like BIDIRECT UPTO 5 STEPS"); + "FIND NOLOOP PATH FROM \"a\" TO \"c\" OVER like BIDIRECT UPTO 5 STEPS " + + "YIELD path as p"); Assert.assertTrue(result.getErrorMessage(), result.isSucceeded()); Assert.assertEquals(4, result.rowsSize()); - String expectString = "ColumnName: [path], " + String expectString = "ColumnName: [p], " + "Rows: [(\"a\" )-[:like@0{}]->(\"g\" )-[:like@0{}]->(\"c\" ), " + "(\"a\" )<-[:like@0{}]-(\"d\" )-[:like@0{}]->(\"c\" ), " + "(\"a\" )<-[:like@0{}]-(\"b\" )<-[:like@0{}]-(\"c\" ), " diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java index f75d5860e..a6fd52658 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockStorageData.java @@ -29,7 +29,7 @@ public static void initGraph() { NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); nebulaPoolConfig.setMaxConnSize(100); - List addresses = Arrays.asList(new HostAddress("127.0.0.1", 9671)); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 9669)); NebulaPool pool = new NebulaPool(); Session session = null; try { @@ -39,7 +39,7 @@ public static void initGraph() { ResultSet resp = session.execute(createSpace()); try { - Thread.sleep(5000); + Thread.sleep(10000); } catch (InterruptedException e) { e.printStackTrace(); } @@ -119,7 +119,7 @@ public static void mockCASslData() { ResultSet resp = session.execute(createSpaceCa()); try { - Thread.sleep(6000); + Thread.sleep(10000); } catch (InterruptedException e) { e.printStackTrace(); } @@ -160,7 +160,7 @@ public static void mockSelfSslData() { ResultSet resp = session.execute(createSpaceSelf()); try { - Thread.sleep(5000); + Thread.sleep(10000); } catch (InterruptedException e) { e.printStackTrace(); } diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java index 284a36201..17e95e8e8 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/MockUtil.java @@ -23,6 +23,7 @@ public class MockUtil { public static List mockVertexDataSets() { List columnNames = new ArrayList<>(); + columnNames.add("_vid".getBytes()); columnNames.add("person._vid".getBytes()); columnNames.add("person.boolean_col1".getBytes()); columnNames.add("person.long_col2".getBytes()); @@ -35,6 +36,7 @@ public static List mockVertexDataSets() { // row 1 List values1 = new ArrayList<>(); values1.add(Value.sVal("Tom".getBytes())); + values1.add(Value.sVal("Tom".getBytes())); values1.add(Value.bVal(true)); values1.add(Value.iVal(12)); values1.add(Value.fVal(1.0)); @@ -43,7 +45,7 @@ public static List mockVertexDataSets() { values1.add(Value.dtVal(new DateTime((short) 2020, (byte) 1, (byte) 1, (byte) 12, (byte) 10, (byte) 30, 100))); values1.add(Value.ggVal(new Geography(Geography.PTVAL, - new Point(new Coordinate(1.0,1.5))))); + new Point(new Coordinate(1.0, 1.5))))); List rows = new ArrayList<>(); rows.add(new Row(values1)); diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java index a527daa82..fa7d84370 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/StorageClientTest.java @@ -64,7 +64,6 @@ public void testScanVertexWithNoCol() { ScanVertexResultIterator resultIterator = client.scanVertex( "testStorage", "person"); - int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -76,7 +75,6 @@ public void testScanVertexWithNoCol() { if (result.isEmpty()) { continue; } - count += result.getVertices().size(); Assert.assertEquals(1, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (result.isAllSuccess()); @@ -106,7 +104,6 @@ public void testScanVertexWithNoCol() { } } } - assert (count == 5); } @Test @@ -121,7 +118,6 @@ public void testScanVertexWithCols() { "testStorage", "person", Arrays.asList("name", "age")); - int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -133,7 +129,6 @@ public void testScanVertexWithCols() { if (result.isEmpty()) { continue; } - count += result.getVertices().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (result.getPropNames().get(1).equals("name")); @@ -172,7 +167,6 @@ public void testScanVertexWithCols() { assert (Arrays.asList(18L, 20L, 23L, 15L, 25L).contains(tableRow.getLong(2))); } } - assert (count == 5); } @Test @@ -187,7 +181,6 @@ public void testScanVertexWithAllCol() { "testStorage", "person", Arrays.asList()); - int count = 0; while (resultIterator.hasNext()) { ScanVertexResult result = null; try { @@ -199,14 +192,12 @@ public void testScanVertexWithAllCol() { if (result.isEmpty()) { continue; } - count += result.getVertices().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_vid")); assert (Arrays.asList("name", "age").contains(result.getPropNames().get(1))); assert (Arrays.asList("name", "age").contains(result.getPropNames().get(2))); assert (result.isAllSuccess()); } - assert (count == 5); } @Test @@ -220,7 +211,6 @@ public void testScanEdgeWithoutCol() { ScanEdgeResultIterator resultIterator = client.scanEdge( "testStorage", "friend"); - int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -232,7 +222,6 @@ public void testScanEdgeWithoutCol() { if (result.isEmpty()) { continue; } - count += result.getEdges().size(); Assert.assertEquals(3, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_src")); assert (result.getPropNames().get(1).equals("_dst")); @@ -270,7 +259,6 @@ public void testScanEdgeWithoutCol() { } } } - assert (count == 5); } @Test @@ -285,7 +273,6 @@ public void testScanEdgeWithCols() { "testStorage", "friend", Arrays.asList("likeness")); - int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -297,7 +284,6 @@ public void testScanEdgeWithCols() { if (result.isEmpty()) { continue; } - count += result.getEdges().size(); Assert.assertEquals(4, result.getPropNames().size()); assert (result.getPropNames().get(0).equals("_src")); assert (result.getPropNames().get(1).equals("_dst")); @@ -341,7 +327,6 @@ public void testScanEdgeWithCols() { assert (Arrays.asList(1.0, 2.1, 3.2, 4.5, 5.9).contains(tableRow.getDouble(3))); } } - assert (count == 5); } @Test @@ -356,7 +341,6 @@ public void testScanEdgeWithAllCols() { "testStorage", "friend", Arrays.asList()); - int count = 0; while (resultIterator.hasNext()) { ScanEdgeResult result = null; try { @@ -368,7 +352,6 @@ public void testScanEdgeWithAllCols() { if (result.isEmpty()) { continue; } - count += result.getEdges().size(); Assert.assertEquals(4, result.getPropNames().size()); assert (Arrays.asList("_src", "_dst", "_rank", "likeness") .contains(result.getPropNames().get(0))); @@ -380,7 +363,6 @@ public void testScanEdgeWithAllCols() { .contains(result.getPropNames().get(3))); assert (result.isAllSuccess()); } - assert (count == 5); } @Test @@ -501,6 +483,7 @@ private void assertIterator(ScanVertexResultIterator resultIterator) { } } } + System.out.println("count:" + count); assert (count == 5); } } diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java index c96faa6d2..ce5ee366a 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java @@ -31,7 +31,7 @@ public void testGetPart() { // test validate leader HostAddress rightAddr = new HostAddress("127.0.0.1", 1); assert (queue.getPart(rightAddr).getLeader().getPort() == 1); - assert (queue.getPart(rightAddr).getCursor() == null); + assert ("".equals(new String(queue.getPart(rightAddr).getCursor().next_cursor))); // test cursor HostAddress addr = new HostAddress("127.0.0.1", 3); diff --git a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java index 3204d461c..0d10704d3 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java @@ -85,19 +85,18 @@ public static void main(String[] args) { try { NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); nebulaPoolConfig.setMaxConnSize(100); - List addresses = Arrays.asList(new HostAddress("127.0.0.1", 9669), - new HostAddress("127.0.0.1", 9670)); + List addresses = Arrays.asList(new HostAddress("127.0.0.1", 9669)); pool.init(addresses, nebulaPoolConfig); session = pool.getSession("root", "nebula", false); { - String createSchema = "CREATE SPACE IF NOT EXISTS test; " - + "USE test;" - + "CREATE TAG IF NOT EXISTS person(name string, age int);" - + "CREATE EDGE IF NOT EXISTS like(likeness double)"; + String createSchema = "CREATE SPACE IF NOT EXISTS test(vid_type=fixed_string(20)); " + + "USE test;" + + "CREATE TAG IF NOT EXISTS person(name string, age int);" + + "CREATE EDGE IF NOT EXISTS like(likeness double)"; ResultSet resp = session.execute(createSchema); if (!resp.isSucceeded()) { log.error(String.format("Execute: `%s', failed: %s", - createSchema, resp.getErrorMessage())); + createSchema, resp.getErrorMessage())); System.exit(1); } } @@ -105,41 +104,41 @@ public static void main(String[] args) { TimeUnit.SECONDS.sleep(5); { String insertVertexes = "INSERT VERTEX person(name, age) VALUES " - + "'Bob':('Bob', 10), " - + "'Lily':('Lily', 9), " - + "'Tom':('Tom', 10), " - + "'Jerry':('Jerry', 13), " - + "'John':('John', 11);"; + + "'Bob':('Bob', 10), " + + "'Lily':('Lily', 9), " + + "'Tom':('Tom', 10), " + + "'Jerry':('Jerry', 13), " + + "'John':('John', 11);"; ResultSet resp = session.execute(insertVertexes); if (!resp.isSucceeded()) { log.error(String.format("Execute: `%s', failed: %s", - insertVertexes, resp.getErrorMessage())); + insertVertexes, resp.getErrorMessage())); System.exit(1); } } { String insertEdges = "INSERT EDGE like(likeness) VALUES " - + "'Bob'->'Lily':(80.0), " - + "'Bob'->'Tom':(70.0), " - + "'Lily'->'Jerry':(84.0), " - + "'Tom'->'Jerry':(68.3), " - + "'Bob'->'John':(97.2);"; + + "'Bob'->'Lily':(80.0), " + + "'Bob'->'Tom':(70.0), " + + "'Lily'->'Jerry':(84.0), " + + "'Tom'->'Jerry':(68.3), " + + "'Bob'->'John':(97.2);"; ResultSet resp = session.execute(insertEdges); if (!resp.isSucceeded()) { log.error(String.format("Execute: `%s', failed: %s", - insertEdges, resp.getErrorMessage())); + insertEdges, resp.getErrorMessage())); System.exit(1); } } { String query = "GO FROM \"Bob\" OVER like " - + "YIELD $^.person.name, $^.person.age, like.likeness"; + + "YIELD $^.person.name, $^.person.age, like.likeness"; ResultSet resp = session.execute(query); if (!resp.isSucceeded()) { log.error(String.format("Execute: `%s', failed: %s", - query, resp.getErrorMessage())); + query, resp.getErrorMessage())); System.exit(1); } printResult(resp); @@ -166,7 +165,7 @@ public static void main(String[] args) { "examples/src/main/resources/ssl/casigned.crt", "examples/src/main/resources/ssl/casigned.key")); NebulaPool sslPool = new NebulaPool(); - sslPool.init(Arrays.asList(new HostAddress("192.168.8.123", 9669)), + sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 9669)), nebulaSslPoolConfig); String queryForJson = "YIELD 1"; Session sslSession = sslPool.getSession("root", "nebula", false); @@ -189,7 +188,7 @@ public static void main(String[] args) { "examples/src/main/resources/ssl/selfsigned.key", "vesoft")); NebulaPool sslPool = new NebulaPool(); - sslPool.init(Arrays.asList(new HostAddress("192.168.8.123", 9669)), + sslPool.init(Arrays.asList(new HostAddress("127.0.0.1", 9669)), nebulaSslPoolConfig); String queryForJson = "YIELD 1"; Session sslSession = sslPool.getSession("root", "nebula", false); diff --git a/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java index bd0608878..26e98c9f5 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/StorageClientExample.java @@ -61,27 +61,21 @@ public static void scanVertex(StorageClient client) { if (result.isEmpty()) { continue; } - System.out.println(result.getPropNames()); + List vertexRows = result.getVertices(); for (VertexRow row : vertexRows) { if (result.getVertex(row.getVid()) != null) { - System.out.println("vid : " + result.getVertex(row.getVid())); + System.out.println(result.getVertex(row.getVid())); } } - System.out.println(result.getVidVertices()); - - System.out.println("result vertex table view:"); + System.out.println("\nresult vertex table view:"); + System.out.println(result.getPropNames()); List vertexTableRows = result.getVertexTableRows(); for (VertexTableRow vertex : vertexTableRows) { - try { - System.out.println("_vid: " + vertex.getVid().asString()); - System.out.println(vertex.getValues()); - } catch (UnsupportedEncodingException e) { - LOGGER.error("decode String error, ", e); - } + System.out.println(vertex.getValues()); } - System.out.println(result.getVertices()); + System.out.println("\n"); } } @@ -108,21 +102,16 @@ public static void scanEdge(StorageClient client) { if (result.isEmpty()) { continue; } - System.out.println(result.getPropNames()); + System.out.println(result.getEdges()); - System.out.println("result edge table view:"); + System.out.println("\nresult edge table view:"); + System.out.println(result.getPropNames()); List edgeTableRows = result.getEdgeTableRows(); for (EdgeTableRow edge : edgeTableRows) { - try { - System.out.println("_src:" + edge.getSrcId().asString()); - System.out.println("_dst:" + edge.getDstId().asString()); - } catch (UnsupportedEncodingException e) { - LOGGER.error("decode String error, ", e); - } - System.out.println("_rank:" + edge.getRank()); System.out.println(edge.getValues()); } + System.out.println("\n"); } } } From ac50d728e58b8d5d60d17a41e45d20e8ce87bacb Mon Sep 17 00:00:00 2001 From: "Harris.Chu" <1726587+HarrisChu@users.noreply.github.com> Date: Tue, 21 Dec 2021 11:53:01 +0800 Subject: [PATCH 14/25] fix add hosts (#407) --- .../client/graph/data/TestDataFromServer.java | 5 +++-- .../test/resources/docker-compose-casigned.yaml | 14 ++++++++++++++ .../test/resources/docker-compose-selfsigned.yaml | 14 ++++++++++++++ client/src/test/resources/docker-compose.yaml | 14 ++++++++++++++ 4 files changed, 45 insertions(+), 2 deletions(-) diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index 326b18e78..571a65273 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -521,8 +521,9 @@ public void testComplexTypeForJson() { Assert.assertEquals(rowData, "[{\"person.first_out_city\":1111,\"person" + ".book_num\":100,\"person.age\":10,\"person.expend\":100,\"person.is_girl\":" + "false,\"person.name\":\"Bob\",\"person.grade\":3,\"person.birthday\":\"2010" - + "-09-10T02:08:02.0Z\",\"student.name\":\"Bob\",\"person.child_name\":\"Hello" - + " Worl\",\"person.property\":1000,\"person.morning\":\"23:10:00.000000Z\",\"" + + "-09-10T02:08:02.000000000Z\",\"student.name\":\"Bob\"," + + "\"person.child_name\":\"Hello Worl\"," + + "\"person.property\":1000,\"person.morning\":\"23:10:00.000000000Z\",\"" + "person.start_school\":\"2017-09-10\",\"person.friends\":10}]"); } catch (IOErrorException e) { e.printStackTrace(); diff --git a/client/src/test/resources/docker-compose-casigned.yaml b/client/src/test/resources/docker-compose-casigned.yaml index cf55d12fd..3cbdb7f59 100644 --- a/client/src/test/resources/docker-compose-casigned.yaml +++ b/client/src/test/resources/docker-compose-casigned.yaml @@ -128,6 +128,20 @@ services: restart: on-failure cap_add: - SYS_PTRACE + console: + image: vesoft/nebula-console:nightly + entrypoint: "" + command: + - sh + - -c + - | + sleep 3 && + nebula-console -addr graphd-casigned -port 9669 -u root -p nebula -e 'ADD HOSTS "172.29.2.1":9779' && + sleep 36000 + depends_on: + - graphd-casigned + networks: + - nebula-net-casigned networks: nebula-net-casigned: diff --git a/client/src/test/resources/docker-compose-selfsigned.yaml b/client/src/test/resources/docker-compose-selfsigned.yaml index 8a5a71d84..ff551b8d8 100644 --- a/client/src/test/resources/docker-compose-selfsigned.yaml +++ b/client/src/test/resources/docker-compose-selfsigned.yaml @@ -127,6 +127,20 @@ services: restart: on-failure cap_add: - SYS_PTRACE + console: + image: vesoft/nebula-console:nightly + entrypoint: "" + command: + - sh + - -c + - | + sleep 3 && + nebula-console -addr graphd-selfsigned -port 9669 -u root -p nebula -e 'ADD HOSTS "172.30.2.1":9779' && + sleep 36000 + depends_on: + - graphd-selfsigned + networks: + - nebula-net-selfsigned networks: nebula-net-selfsigned: diff --git a/client/src/test/resources/docker-compose.yaml b/client/src/test/resources/docker-compose.yaml index 6399d054f..4f75fdfb5 100644 --- a/client/src/test/resources/docker-compose.yaml +++ b/client/src/test/resources/docker-compose.yaml @@ -347,6 +347,20 @@ services: restart: on-failure cap_add: - SYS_PTRACE + console: + image: vesoft/nebula-console:nightly + entrypoint: "" + command: + - sh + - -c + - | + sleep 3 && + nebula-console -addr graphd0 -port 9669 -u root -p nebula -e 'ADD HOSTS "172.28.2.1":9779,"172.28.2.2":9779,"172.28.2.3":9779' && + sleep 36000 + depends_on: + - graphd0 + networks: + - nebula-net networks: nebula-net: From 88ee4988d8f2c45ae33d35b87ffa8424642deb28 Mon Sep 17 00:00:00 2001 From: Anqi Date: Tue, 21 Dec 2021 14:26:10 +0800 Subject: [PATCH 15/25] release the transport when version verification failed (#402) --- .../com/vesoft/nebula/client/graph/net/SyncConnection.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java index 07e625aae..4216e684c 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java @@ -78,6 +78,7 @@ public void open(HostAddress address, int timeout, SSLParam sslParam) Charsets.UTF_8)); } } catch (TException | IOException e) { + close(); throw new IOErrorException(IOErrorException.E_UNKNOWN, e.getMessage()); } } @@ -224,7 +225,7 @@ public boolean ping() { } public void close() { - if (transport != null) { + if (transport != null && transport.isOpen()) { transport.close(); } } From ede2cb25bac587a1b186e0a143593908846183d9 Mon Sep 17 00:00:00 2001 From: Anqi Date: Tue, 21 Dec 2021 16:43:31 +0800 Subject: [PATCH 16/25] support demain address (#403) Co-authored-by: Yichen Wang <18348405+Aiee@users.noreply.github.com> --- .../client/meta/AbstractMetaClient.java | 12 +++++----- .../vesoft/nebula/client/meta/MetaClient.java | 15 ++++++++----- .../nebula/client/meta/MetaManager.java | 5 +++-- .../nebula/client/meta/TestMetaClient.java | 22 ++++++++++++++----- .../nebula/client/meta/TestMetaManager.java | 9 ++++++-- 5 files changed, 42 insertions(+), 21 deletions(-) diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java index c74e30ac3..f37daee44 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/AbstractMetaClient.java @@ -10,6 +10,8 @@ import com.google.common.base.Preconditions; import com.google.common.net.InetAddresses; import com.vesoft.nebula.client.graph.data.HostAddress; +import java.net.InetAddress; +import java.net.UnknownHostException; import java.util.List; public class AbstractMetaClient { @@ -22,16 +24,16 @@ public class AbstractMetaClient { protected TTransport transport; public AbstractMetaClient(List addresses, int timeout, - int connectionRetry, int executionRetry) { + int connectionRetry, int executionRetry) throws UnknownHostException { Preconditions.checkArgument(timeout > 0); - Preconditions.checkArgument(connectionRetry > 0); - Preconditions.checkArgument(executionRetry > 0); + Preconditions.checkArgument(connectionRetry >= 0); + Preconditions.checkArgument(executionRetry >= 0); for (HostAddress address : addresses) { - String host = address.getHost(); + String host = InetAddress.getByName(address.getHost()).getHostAddress(); int port = address.getPort(); // check if the address is a valid ip address or uri address and port is valid if ((!InetAddresses.isInetAddress(host) || !InetAddresses.isUriInetAddress(host)) - || (port <= 0 || port >= 65535)) { + || (port <= 0 || port >= 65535)) { throw new IllegalArgumentException(String.format("%s:%d is not a valid address", host, port)); } diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java index a5cfa60b8..118d99416 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaClient.java @@ -48,6 +48,7 @@ import com.vesoft.nebula.meta.VerifyClientVersionResp; import com.vesoft.nebula.util.SslUtil; import java.io.IOException; +import java.net.UnknownHostException; import java.util.Arrays; import java.util.HashSet; import java.util.List; @@ -75,30 +76,32 @@ public class MetaClient extends AbstractMetaClient { private MetaService.Client client; private final List addresses; - public MetaClient(String host, int port) { + public MetaClient(String host, int port) throws UnknownHostException { this(new HostAddress(host, port)); } - public MetaClient(HostAddress address) { + public MetaClient(HostAddress address) throws UnknownHostException { this(Arrays.asList(address), DEFAULT_CONNECTION_RETRY_SIZE, DEFAULT_EXECUTION_RETRY_SIZE); } - public MetaClient(List addresses) { + public MetaClient(List addresses) throws UnknownHostException { this(addresses, DEFAULT_CONNECTION_RETRY_SIZE, DEFAULT_EXECUTION_RETRY_SIZE); } - public MetaClient(List addresses, int connectionRetry, int executionRetry) { + public MetaClient(List addresses, int connectionRetry, int executionRetry) + throws UnknownHostException { this(addresses, DEFAULT_TIMEOUT_MS, connectionRetry, executionRetry); } public MetaClient(List addresses, int timeout, int connectionRetry, - int executionRetry) { + int executionRetry) throws UnknownHostException { super(addresses, timeout, connectionRetry, executionRetry); this.addresses = addresses; } public MetaClient(List addresses, int timeout, int connectionRetry, - int executionRetry, boolean enableSSL, SSLParam sslParam) { + int executionRetry, boolean enableSSL, SSLParam sslParam) + throws UnknownHostException { super(addresses, timeout, connectionRetry, executionRetry); this.addresses = addresses; this.enableSSL = enableSSL; diff --git a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java index 8416b0fd0..1c23ebb7b 100644 --- a/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java +++ b/client/src/main/java/com/vesoft/nebula/client/meta/MetaManager.java @@ -16,6 +16,7 @@ import com.vesoft.nebula.meta.IdName; import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; +import java.net.UnknownHostException; import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; @@ -55,7 +56,7 @@ private class SpaceInfo { * init the meta info cache */ public MetaManager(List address) - throws TException, ClientServerIncompatibleException { + throws TException, ClientServerIncompatibleException, UnknownHostException { metaClient = new MetaClient(address); metaClient.connect(); fillMetaInfo(); @@ -66,7 +67,7 @@ public MetaManager(List address) */ public MetaManager(List address, int timeout, int connectionRetry, int executionRetry, boolean enableSSL, SSLParam sslParam) - throws TException, ClientServerIncompatibleException { + throws TException, ClientServerIncompatibleException, UnknownHostException { metaClient = new MetaClient(address, timeout, connectionRetry, executionRetry, enableSSL, sslParam); metaClient.connect(); diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java index a805fcb96..69e3c5426 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaClient.java @@ -17,6 +17,7 @@ import com.vesoft.nebula.meta.IdName; import com.vesoft.nebula.meta.TagItem; import java.io.IOException; +import java.net.UnknownHostException; import java.util.Arrays; import java.util.List; import java.util.concurrent.TimeUnit; @@ -43,10 +44,10 @@ public void tearDown() throws Exception { } private void connect() { - metaClient = new MetaClient(address, port); try { + metaClient = new MetaClient(address, port); metaClient.connect(); - } catch (TException | ClientServerIncompatibleException e) { + } catch (TException | UnknownHostException | ClientServerIncompatibleException e) { e.printStackTrace(); assert (false); } @@ -54,10 +55,11 @@ private void connect() { public void testFailConnect() { int port = 1111; - MetaClient client = new MetaClient(address, port); + try { + MetaClient client = new MetaClient(address, port); client.connect(); - } catch (TException | ClientServerIncompatibleException e) { + } catch (TException | UnknownHostException | ClientServerIncompatibleException e) { assert (true); } } @@ -107,7 +109,11 @@ public void testGetPartsAlloc() { public void testListHosts() { if (metaClient == null) { - metaClient = new MetaClient(address, port); + try { + metaClient = new MetaClient(address, port); + } catch (UnknownHostException e) { + assert (false); + } } assert (metaClient.listHosts().size() == 3); } @@ -126,7 +132,11 @@ public void testListOnlineHosts() { assert (false); } if (metaClient == null) { - metaClient = new MetaClient(address, port); + try { + metaClient = new MetaClient(address, port); + } catch (UnknownHostException e) { + assert (false); + } } assert (metaClient.listHosts().size() == 2); diff --git a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java index 0d6ceeb74..9124a65dd 100644 --- a/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java +++ b/client/src/test/java/com/vesoft/nebula/client/meta/TestMetaManager.java @@ -16,6 +16,7 @@ import com.vesoft.nebula.meta.SpaceItem; import com.vesoft.nebula.meta.TagItem; import java.io.IOException; +import java.net.UnknownHostException; import java.util.Arrays; import java.util.Collections; import java.util.List; @@ -107,8 +108,12 @@ public void testGetSpaceParts() { public void testMultiVersionSchema() throws ClientServerIncompatibleException { MockNebulaGraph.createMultiVersionTagAndEdge(); metaManager.close(); - metaManager = new MetaManager( - Collections.singletonList(new HostAddress("127.0.0.1", 9559))); + try { + metaManager = new MetaManager( + Collections.singletonList(new HostAddress("127.0.0.1", 9559))); + } catch (UnknownHostException e) { + assert (false); + } TagItem tagItem = metaManager.getTag("testMeta", "player"); assert (tagItem.getVersion() == 1); assert (tagItem.schema.getColumns().size() == 1); From d487480c706a2e1e1c6a4e53601dc94232e3b274 Mon Sep 17 00:00:00 2001 From: Anqi Date: Tue, 21 Dec 2021 19:23:16 +0800 Subject: [PATCH 17/25] upadte version match info (#404) Co-authored-by: Yichen Wang <18348405+Aiee@users.noreply.github.com> --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 054c73808..56f0d50b7 100644 --- a/README.md +++ b/README.md @@ -62,10 +62,12 @@ There are the version correspondence between client and Nebula: | 1.2.0 | 1.1.0,1.2.0,1.2.1 | | 2.0.0-beta | 2.0.0-beta | | 2.0.0-rc1 | 2.0.0-rc1 | -| 2.0.0/2.0.1 | 2.0.0/2.0.1 | -| 2.5.0 | 2.5.0 | -| 2.6.0 | 2.6.0 | -| 2.0.0-SNAPSHOT| 2.0.0-nightly | +| 2.0.0 | 2.0.0,2.0.1 | +| 2.0.1 | 2.0.0,2.0.1 | +| 2.5.0 | 2.5.0,2.5.1 | +| 2.6.0 | 2.6.0,2.6.1 | +| 2.6.1 | 2.6.0,2.6.1 | +| 2.0.0-SNAPSHOT| nightly | ## Graph client example From 5cceada86a7123fd398ab0f11dd8818593151093 Mon Sep 17 00:00:00 2001 From: Anqi Date: Thu, 23 Dec 2021 18:04:51 +0800 Subject: [PATCH 18/25] update scan interface according to the latest server (#410) * update thrift * remove has_next field * update test Co-authored-by: Yichen Wang <18348405+Aiee@users.noreply.github.com> --- .../generated/com/vesoft/nebula/Duration.java | 431 ++ .../com/vesoft/nebula/ErrorCode.java | 2 +- .../com/vesoft/nebula/PropertyType.java | 46 +- .../nebula/graph/GraphAdminService.java | 644 +++ .../com/vesoft/nebula/graph/GraphService.java | 1535 ++++++- .../nebula/graph/ListAllSessionsReq.java | 174 + .../nebula/graph/ListAllSessionsResp.java | 360 ++ .../vesoft/nebula/graph/ListSessionsReq.java | 174 + .../vesoft/nebula/graph/ListSessionsResp.java | 438 ++ .../com/vesoft/nebula/graph/QueryDesc.java | 630 +++ .../com/vesoft/nebula/graph/QueryStatus.java | 46 + .../com/vesoft/nebula/graph/Session.java | 993 +++++ .../nebula/meta/AddHostsIntoZoneReq.java | 463 +++ .../com/vesoft/nebula/meta/AddHostsReq.java | 286 ++ .../vesoft/nebula/meta/AddListenerReq.java | 22 +- .../com/vesoft/nebula/meta/AdminJobReq.java | 20 +- .../vesoft/nebula/meta/AdminJobResult.java | 44 +- .../com/vesoft/nebula/meta/AlterEdgeReq.java | 22 +- .../com/vesoft/nebula/meta/AlterTagReq.java | 22 +- .../com/vesoft/nebula/meta/BackupInfo.java | 22 +- .../com/vesoft/nebula/meta/BackupMeta.java | 48 +- .../vesoft/nebula/meta/CreateBackupReq.java | 20 +- .../nebula/meta/CreateEdgeIndexReq.java | 22 +- .../vesoft/nebula/meta/CreateTagIndexReq.java | 22 +- .../com/vesoft/nebula/meta/DropHostsReq.java | 286 ++ .../com/vesoft/nebula/meta/FTIndex.java | 20 +- .../com/vesoft/nebula/meta/GetConfigResp.java | 22 +- .../vesoft/nebula/meta/GetPartsAllocResp.java | 72 +- .../com/vesoft/nebula/meta/GetStatisReq.java | 267 ++ .../com/vesoft/nebula/meta/GetStatisResp.java | 457 +++ .../com/vesoft/nebula/meta/GetZoneResp.java | 22 +- .../com/vesoft/nebula/meta/HBReq.java | 98 +- .../com/vesoft/nebula/meta/HostItem.java | 88 +- .../com/vesoft/nebula/meta/IndexItem.java | 22 +- .../com/vesoft/nebula/meta/IndexParams.java | 454 --- .../com/vesoft/nebula/meta/JobDesc.java | 20 +- .../com/vesoft/nebula/meta/KillQueryReq.java | 44 +- .../nebula/meta/ListAllSessionsReq.java | 174 + .../nebula/meta/ListAllSessionsResp.java | 438 ++ .../nebula/meta/ListClusterInfoResp.java | 44 +- .../vesoft/nebula/meta/ListConfigsResp.java | 22 +- .../nebula/meta/ListEdgeIndexesResp.java | 22 +- .../com/vesoft/nebula/meta/ListEdgesResp.java | 22 +- .../vesoft/nebula/meta/ListFTClientsResp.java | 22 +- .../vesoft/nebula/meta/ListFTIndexesResp.java | 28 +- .../com/vesoft/nebula/meta/ListHostsResp.java | 22 +- .../nebula/meta/ListIndexStatusResp.java | 22 +- .../vesoft/nebula/meta/ListListenerResp.java | 22 +- .../com/vesoft/nebula/meta/ListPartsReq.java | 20 +- .../com/vesoft/nebula/meta/ListPartsResp.java | 22 +- .../com/vesoft/nebula/meta/ListRolesResp.java | 22 +- .../vesoft/nebula/meta/ListSessionsResp.java | 22 +- .../vesoft/nebula/meta/ListSnapshotsResp.java | 22 +- .../vesoft/nebula/meta/ListSpacesResp.java | 22 +- .../nebula/meta/ListTagIndexesResp.java | 22 +- .../com/vesoft/nebula/meta/ListTagsResp.java | 22 +- .../com/vesoft/nebula/meta/ListUsersResp.java | 26 +- .../com/vesoft/nebula/meta/ListZonesResp.java | 22 +- .../com/vesoft/nebula/meta/MergeZoneReq.java | 375 ++ .../com/vesoft/nebula/meta/MetaService.java | 3540 ++++++++++++----- .../com/vesoft/nebula/meta/MultiGetReq.java | 20 +- .../com/vesoft/nebula/meta/MultiGetResp.java | 20 +- .../com/vesoft/nebula/meta/MultiPutReq.java | 22 +- .../com/vesoft/nebula/meta/PartItem.java | 44 +- .../com/vesoft/nebula/meta/PartitionList.java | 20 +- .../com/vesoft/nebula/meta/PropertyType.java | 88 + .../com/vesoft/nebula/meta/RegConfigReq.java | 22 +- .../com/vesoft/nebula/meta/RenameZoneReq.java | 360 ++ .../vesoft/nebula/meta/RestoreMetaReq.java | 42 +- .../com/vesoft/nebula/meta/ScanResp.java | 20 +- .../com/vesoft/nebula/meta/SchemaID.java | 239 ++ .../com/vesoft/nebula/meta/Session.java | 56 +- .../vesoft/nebula/meta/SessionContext.java | 839 ++++ .../com/vesoft/nebula/meta/SessionSchema.java | 607 +++ .../nebula/meta/SignInFTServiceReq.java | 22 +- .../vesoft/nebula/meta/SpaceBackupInfo.java | 22 +- .../com/vesoft/nebula/meta/SpaceDesc.java | 132 +- .../com/vesoft/nebula/meta/SplitZoneReq.java | 270 ++ .../com/vesoft/nebula/meta/StatisItem.java | 927 +++++ .../com/vesoft/nebula/meta/StatsItem.java | 144 +- .../vesoft/nebula/meta/UpdateSessionsReq.java | 22 +- .../nebula/meta/UpdateSessionsResp.java | 52 +- .../nebula/meta/VerifyClientVersionReq.java | 188 +- .../com/vesoft/nebula/meta/Zone.java | 22 +- .../nebula/storage/AddEdgesRequest.java | 91 +- .../nebula/storage/AddVerticesRequest.java | 91 +- .../nebula/storage/GetValueRequest.java | 439 ++ .../nebula/storage/GetValueResponse.java | 365 ++ .../com/vesoft/nebula/storage/ScanCursor.java | 100 +- .../client/storage/scan/PartScanInfo.java | 2 +- .../storage/scan/ScanResultIterator.java | 6 +- .../storage/scan/PartScanQueueTest.java | 2 +- .../nebula/encoder/MetaCacheImplTest.java | 71 +- 93 files changed, 16065 insertions(+), 2635 deletions(-) create mode 100644 client/src/main/generated/com/vesoft/nebula/Duration.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java create mode 100644 client/src/main/generated/com/vesoft/nebula/graph/Session.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddHostsReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/DropHostsReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/RenameZoneReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SplitZoneReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java create mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java diff --git a/client/src/main/generated/com/vesoft/nebula/Duration.java b/client/src/main/generated/com/vesoft/nebula/Duration.java new file mode 100644 index 000000000..150088d93 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/Duration.java @@ -0,0 +1,431 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class Duration implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("Duration"); + private static final TField SECONDS_FIELD_DESC = new TField("seconds", TType.I64, (short)1); + private static final TField MICROSECONDS_FIELD_DESC = new TField("microseconds", TType.I32, (short)2); + private static final TField MONTHS_FIELD_DESC = new TField("months", TType.I32, (short)3); + + public long seconds; + public int microseconds; + public int months; + public static final int SECONDS = 1; + public static final int MICROSECONDS = 2; + public static final int MONTHS = 3; + + // isset id assignments + private static final int __SECONDS_ISSET_ID = 0; + private static final int __MICROSECONDS_ISSET_ID = 1; + private static final int __MONTHS_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SECONDS, new FieldMetaData("seconds", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(MICROSECONDS, new FieldMetaData("microseconds", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(MONTHS, new FieldMetaData("months", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(Duration.class, metaDataMap); + } + + public Duration() { + } + + public Duration( + long seconds, + int microseconds, + int months) { + this(); + this.seconds = seconds; + setSecondsIsSet(true); + this.microseconds = microseconds; + setMicrosecondsIsSet(true); + this.months = months; + setMonthsIsSet(true); + } + + public static class Builder { + private long seconds; + private int microseconds; + private int months; + + BitSet __optional_isset = new BitSet(3); + + public Builder() { + } + + public Builder setSeconds(final long seconds) { + this.seconds = seconds; + __optional_isset.set(__SECONDS_ISSET_ID, true); + return this; + } + + public Builder setMicroseconds(final int microseconds) { + this.microseconds = microseconds; + __optional_isset.set(__MICROSECONDS_ISSET_ID, true); + return this; + } + + public Builder setMonths(final int months) { + this.months = months; + __optional_isset.set(__MONTHS_ISSET_ID, true); + return this; + } + + public Duration build() { + Duration result = new Duration(); + if (__optional_isset.get(__SECONDS_ISSET_ID)) { + result.setSeconds(this.seconds); + } + if (__optional_isset.get(__MICROSECONDS_ISSET_ID)) { + result.setMicroseconds(this.microseconds); + } + if (__optional_isset.get(__MONTHS_ISSET_ID)) { + result.setMonths(this.months); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public Duration(Duration other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.seconds = TBaseHelper.deepCopy(other.seconds); + this.microseconds = TBaseHelper.deepCopy(other.microseconds); + this.months = TBaseHelper.deepCopy(other.months); + } + + public Duration deepCopy() { + return new Duration(this); + } + + public long getSeconds() { + return this.seconds; + } + + public Duration setSeconds(long seconds) { + this.seconds = seconds; + setSecondsIsSet(true); + return this; + } + + public void unsetSeconds() { + __isset_bit_vector.clear(__SECONDS_ISSET_ID); + } + + // Returns true if field seconds is set (has been assigned a value) and false otherwise + public boolean isSetSeconds() { + return __isset_bit_vector.get(__SECONDS_ISSET_ID); + } + + public void setSecondsIsSet(boolean __value) { + __isset_bit_vector.set(__SECONDS_ISSET_ID, __value); + } + + public int getMicroseconds() { + return this.microseconds; + } + + public Duration setMicroseconds(int microseconds) { + this.microseconds = microseconds; + setMicrosecondsIsSet(true); + return this; + } + + public void unsetMicroseconds() { + __isset_bit_vector.clear(__MICROSECONDS_ISSET_ID); + } + + // Returns true if field microseconds is set (has been assigned a value) and false otherwise + public boolean isSetMicroseconds() { + return __isset_bit_vector.get(__MICROSECONDS_ISSET_ID); + } + + public void setMicrosecondsIsSet(boolean __value) { + __isset_bit_vector.set(__MICROSECONDS_ISSET_ID, __value); + } + + public int getMonths() { + return this.months; + } + + public Duration setMonths(int months) { + this.months = months; + setMonthsIsSet(true); + return this; + } + + public void unsetMonths() { + __isset_bit_vector.clear(__MONTHS_ISSET_ID); + } + + // Returns true if field months is set (has been assigned a value) and false otherwise + public boolean isSetMonths() { + return __isset_bit_vector.get(__MONTHS_ISSET_ID); + } + + public void setMonthsIsSet(boolean __value) { + __isset_bit_vector.set(__MONTHS_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SECONDS: + if (__value == null) { + unsetSeconds(); + } else { + setSeconds((Long)__value); + } + break; + + case MICROSECONDS: + if (__value == null) { + unsetMicroseconds(); + } else { + setMicroseconds((Integer)__value); + } + break; + + case MONTHS: + if (__value == null) { + unsetMonths(); + } else { + setMonths((Integer)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SECONDS: + return new Long(getSeconds()); + + case MICROSECONDS: + return new Integer(getMicroseconds()); + + case MONTHS: + return new Integer(getMonths()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof Duration)) + return false; + Duration that = (Duration)_that; + + if (!TBaseHelper.equalsNobinary(this.seconds, that.seconds)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.microseconds, that.microseconds)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.months, that.months)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {seconds, microseconds, months}); + } + + @Override + public int compareTo(Duration other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSeconds()).compareTo(other.isSetSeconds()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(seconds, other.seconds); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetMicroseconds()).compareTo(other.isSetMicroseconds()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(microseconds, other.microseconds); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetMonths()).compareTo(other.isSetMonths()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(months, other.months); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SECONDS: + if (__field.type == TType.I64) { + this.seconds = iprot.readI64(); + setSecondsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case MICROSECONDS: + if (__field.type == TType.I32) { + this.microseconds = iprot.readI32(); + setMicrosecondsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case MONTHS: + if (__field.type == TType.I32) { + this.months = iprot.readI32(); + setMonthsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SECONDS_FIELD_DESC); + oprot.writeI64(this.seconds); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(MICROSECONDS_FIELD_DESC); + oprot.writeI32(this.microseconds); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(MONTHS_FIELD_DESC); + oprot.writeI32(this.months); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("Duration"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("seconds"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSeconds(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("microseconds"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getMicroseconds(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("months"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getMonths(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java index cd84b2ceb..aeb236d81 100644 --- a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java +++ b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java @@ -26,7 +26,7 @@ public enum ErrorCode implements com.facebook.thrift.TEnum { E_TAG_PROP_NOT_FOUND(-10), E_ROLE_NOT_FOUND(-11), E_CONFIG_NOT_FOUND(-12), - E_GROUP_NOT_FOUND(-13), + E_MACHINE_NOT_FOUND(-13), E_ZONE_NOT_FOUND(-14), E_LISTENER_NOT_FOUND(-15), E_PART_NOT_FOUND(-16), diff --git a/client/src/main/generated/com/vesoft/nebula/PropertyType.java b/client/src/main/generated/com/vesoft/nebula/PropertyType.java index 9d9671e8d..73704d9cd 100644 --- a/client/src/main/generated/com/vesoft/nebula/PropertyType.java +++ b/client/src/main/generated/com/vesoft/nebula/PropertyType.java @@ -25,11 +25,20 @@ public enum PropertyType implements com.facebook.thrift.TEnum { INT16(9), INT32(10), TIMESTAMP(21), + DURATION(23), DATE(24), DATETIME(25), TIME(26), GEOGRAPHY(31); + private static final Map INDEXED_VALUES = new HashMap(); + + static { + for (PropertyType e: values()) { + INDEXED_VALUES.put(e.getValue(), e); + } + } + private final int value; private PropertyType(int value) { @@ -48,41 +57,6 @@ public int getValue() { * @return null if the value is not found. */ public static PropertyType findByValue(int value) { - switch (value) { - case 0: - return UNKNOWN; - case 1: - return BOOL; - case 2: - return INT64; - case 3: - return VID; - case 4: - return FLOAT; - case 5: - return DOUBLE; - case 6: - return STRING; - case 7: - return FIXED_STRING; - case 8: - return INT8; - case 9: - return INT16; - case 10: - return INT32; - case 21: - return TIMESTAMP; - case 24: - return DATE; - case 25: - return DATETIME; - case 26: - return TIME; - case 31: - return GEOGRAPHY; - default: - return null; - } + return INDEXED_VALUES.get(value); } } diff --git a/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java b/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java new file mode 100644 index 000000000..b39ac4039 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java @@ -0,0 +1,644 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GraphAdminService { + + public interface Iface { + + public ListAllSessionsResp listAllSessions(ListAllSessionsReq req) throws TException; + + } + + public interface AsyncIface { + + public void listAllSessions(ListAllSessionsReq req, AsyncMethodCallback resultHandler) throws TException; + + } + + public static class Client extends EventHandlerBase implements Iface, TClientIf { + public Client(TProtocol prot) + { + this(prot, prot); + } + + public Client(TProtocol iprot, TProtocol oprot) + { + iprot_ = iprot; + oprot_ = oprot; + } + + protected TProtocol iprot_; + protected TProtocol oprot_; + + protected int seqid_; + + @Override + public TProtocol getInputProtocol() + { + return this.iprot_; + } + + @Override + public TProtocol getOutputProtocol() + { + return this.oprot_; + } + + public ListAllSessionsResp listAllSessions(ListAllSessionsReq req) throws TException + { + ContextStack ctx = getContextStack("GraphAdminService.listAllSessions", null); + this.setContextStack(ctx); + send_listAllSessions(req); + return recv_listAllSessions(); + } + + public void send_listAllSessions(ListAllSessionsReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphAdminService.listAllSessions", null); + oprot_.writeMessageBegin(new TMessage("listAllSessions", TMessageType.CALL, seqid_)); + listAllSessions_args args = new listAllSessions_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphAdminService.listAllSessions", args); + return; + } + + public ListAllSessionsResp recv_listAllSessions() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphAdminService.listAllSessions"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + listAllSessions_result result = new listAllSessions_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphAdminService.listAllSessions", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "listAllSessions failed: unknown result"); + } + + } + public static class AsyncClient extends TAsyncClient implements AsyncIface { + public static class Factory implements TAsyncClientFactory { + private TAsyncClientManager clientManager; + private TProtocolFactory protocolFactory; + public Factory(TAsyncClientManager clientManager, TProtocolFactory protocolFactory) { + this.clientManager = clientManager; + this.protocolFactory = protocolFactory; + } + public AsyncClient getAsyncClient(TNonblockingTransport transport) { + return new AsyncClient(protocolFactory, clientManager, transport); + } + } + + public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientManager, TNonblockingTransport transport) { + super(protocolFactory, clientManager, transport); + } + + public void listAllSessions(ListAllSessionsReq req, AsyncMethodCallback resultHandler74) throws TException { + checkReady(); + listAllSessions_call method_call = new listAllSessions_call(req, resultHandler74, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class listAllSessions_call extends TAsyncMethodCall { + private ListAllSessionsReq req; + public listAllSessions_call(ListAllSessionsReq req, AsyncMethodCallback resultHandler75, TAsyncClient client71, TProtocolFactory protocolFactory72, TNonblockingTransport transport73) throws TException { + super(client71, protocolFactory72, transport73, resultHandler75, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("listAllSessions", TMessageType.CALL, 0)); + listAllSessions_args args = new listAllSessions_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ListAllSessionsResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_listAllSessions(); + } + } + + } + + public static class Processor implements TProcessor { + private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName()); + public Processor(Iface iface) + { + iface_ = iface; + event_handler_ = new TProcessorEventHandler(); // Empty handler + processMap_.put("listAllSessions", new listAllSessions()); + } + + protected static interface ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException; + } + + public void setEventHandler(TProcessorEventHandler handler) { + this.event_handler_ = handler; + } + + private Iface iface_; + protected TProcessorEventHandler event_handler_; + protected final HashMap processMap_ = new HashMap(); + + public boolean process(TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + TMessage msg = iprot.readMessageBegin(); + ProcessFunction fn = processMap_.get(msg.name); + if (fn == null) { + TProtocolUtil.skip(iprot, TType.STRUCT); + iprot.readMessageEnd(); + TApplicationException x = new TApplicationException(TApplicationException.UNKNOWN_METHOD, "Invalid method name: '"+msg.name+"'"); + oprot.writeMessageBegin(new TMessage(msg.name, TMessageType.EXCEPTION, msg.seqid)); + x.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + return true; + } + fn.process(msg.seqid, iprot, oprot, server_ctx); + return true; + } + + private class listAllSessions implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphAdminService.listAllSessions", server_ctx); + listAllSessions_args args = new listAllSessions_args(); + event_handler_.preRead(handler_ctx, "GraphAdminService.listAllSessions"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphAdminService.listAllSessions", args); + listAllSessions_result result = new listAllSessions_result(); + result.success = iface_.listAllSessions(args.req); + event_handler_.preWrite(handler_ctx, "GraphAdminService.listAllSessions", result); + oprot.writeMessageBegin(new TMessage("listAllSessions", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphAdminService.listAllSessions", result); + } + + } + + } + + public static class listAllSessions_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listAllSessions_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public ListAllSessionsReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ListAllSessionsReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(listAllSessions_args.class, metaDataMap); + } + + public listAllSessions_args() { + } + + public listAllSessions_args( + ListAllSessionsReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public listAllSessions_args(listAllSessions_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public listAllSessions_args deepCopy() { + return new listAllSessions_args(this); + } + + public ListAllSessionsReq getReq() { + return this.req; + } + + public listAllSessions_args setReq(ListAllSessionsReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((ListAllSessionsReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof listAllSessions_args)) + return false; + listAllSessions_args that = (listAllSessions_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(listAllSessions_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new ListAllSessionsReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("listAllSessions_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class listAllSessions_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("listAllSessions_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ListAllSessionsResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ListAllSessionsResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(listAllSessions_result.class, metaDataMap); + } + + public listAllSessions_result() { + } + + public listAllSessions_result( + ListAllSessionsResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public listAllSessions_result(listAllSessions_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public listAllSessions_result deepCopy() { + return new listAllSessions_result(this); + } + + public ListAllSessionsResp getSuccess() { + return this.success; + } + + public listAllSessions_result setSuccess(ListAllSessionsResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ListAllSessionsResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof listAllSessions_result)) + return false; + listAllSessions_result that = (listAllSessions_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ListAllSessionsResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("listAllSessions_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + +} diff --git a/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java b/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java index 4083c3390..326abd953 100644 --- a/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java +++ b/client/src/main/generated/com/vesoft/nebula/graph/GraphService.java @@ -37,8 +37,12 @@ public interface Iface { public ExecutionResponse execute(long sessionId, byte[] stmt) throws TException; + public ExecutionResponse executeWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException; + public byte[] executeJson(long sessionId, byte[] stmt) throws TException; + public byte[] executeJsonWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException; + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException; } @@ -51,8 +55,12 @@ public interface AsyncIface { public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler) throws TException; + public void executeWithParameter(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler) throws TException; + public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler) throws TException; + public void executeJsonWithParameter(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler) throws TException; + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler) throws TException; } @@ -199,6 +207,53 @@ public ExecutionResponse recv_execute() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "execute failed: unknown result"); } + public ExecutionResponse executeWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException + { + ContextStack ctx = getContextStack("GraphService.executeWithParameter", null); + this.setContextStack(ctx); + send_executeWithParameter(sessionId, stmt, parameterMap); + return recv_executeWithParameter(); + } + + public void send_executeWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphService.executeWithParameter", null); + oprot_.writeMessageBegin(new TMessage("executeWithParameter", TMessageType.CALL, seqid_)); + executeWithParameter_args args = new executeWithParameter_args(); + args.sessionId = sessionId; + args.stmt = stmt; + args.parameterMap = parameterMap; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphService.executeWithParameter", args); + return; + } + + public ExecutionResponse recv_executeWithParameter() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphService.executeWithParameter"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + executeWithParameter_result result = new executeWithParameter_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphService.executeWithParameter", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "executeWithParameter failed: unknown result"); + } + public byte[] executeJson(long sessionId, byte[] stmt) throws TException { ContextStack ctx = getContextStack("GraphService.executeJson", null); @@ -245,6 +300,53 @@ public byte[] recv_executeJson() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "executeJson failed: unknown result"); } + public byte[] executeJsonWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException + { + ContextStack ctx = getContextStack("GraphService.executeJsonWithParameter", null); + this.setContextStack(ctx); + send_executeJsonWithParameter(sessionId, stmt, parameterMap); + return recv_executeJsonWithParameter(); + } + + public void send_executeJsonWithParameter(long sessionId, byte[] stmt, Map parameterMap) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "GraphService.executeJsonWithParameter", null); + oprot_.writeMessageBegin(new TMessage("executeJsonWithParameter", TMessageType.CALL, seqid_)); + executeJsonWithParameter_args args = new executeJsonWithParameter_args(); + args.sessionId = sessionId; + args.stmt = stmt; + args.parameterMap = parameterMap; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "GraphService.executeJsonWithParameter", args); + return; + } + + public byte[] recv_executeJsonWithParameter() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "GraphService.executeJsonWithParameter"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + executeJsonWithParameter_result result = new executeJsonWithParameter_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "GraphService.executeJsonWithParameter", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "executeJsonWithParameter failed: unknown result"); + } + public VerifyClientVersionResp verifyClientVersion(VerifyClientVersionReq req) throws TException { ContextStack ctx = getContextStack("GraphService.verifyClientVersion", null); @@ -308,9 +410,9 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void authenticate(byte[] username, byte[] password, AsyncMethodCallback resultHandler34) throws TException { + public void authenticate(byte[] username, byte[] password, AsyncMethodCallback resultHandler36) throws TException { checkReady(); - authenticate_call method_call = new authenticate_call(username, password, resultHandler34, this, ___protocolFactory, ___transport); + authenticate_call method_call = new authenticate_call(username, password, resultHandler36, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -318,8 +420,8 @@ public void authenticate(byte[] username, byte[] password, AsyncMethodCallback r public static class authenticate_call extends TAsyncMethodCall { private byte[] username; private byte[] password; - public authenticate_call(byte[] username, byte[] password, AsyncMethodCallback resultHandler35, TAsyncClient client31, TProtocolFactory protocolFactory32, TNonblockingTransport transport33) throws TException { - super(client31, protocolFactory32, transport33, resultHandler35, false); + public authenticate_call(byte[] username, byte[] password, AsyncMethodCallback resultHandler37, TAsyncClient client33, TProtocolFactory protocolFactory34, TNonblockingTransport transport35) throws TException { + super(client33, protocolFactory34, transport35, resultHandler37, false); this.username = username; this.password = password; } @@ -343,17 +445,17 @@ public AuthResponse getResult() throws TException { } } - public void signout(long sessionId, AsyncMethodCallback resultHandler39) throws TException { + public void signout(long sessionId, AsyncMethodCallback resultHandler41) throws TException { checkReady(); - signout_call method_call = new signout_call(sessionId, resultHandler39, this, ___protocolFactory, ___transport); + signout_call method_call = new signout_call(sessionId, resultHandler41, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signout_call extends TAsyncMethodCall { private long sessionId; - public signout_call(long sessionId, AsyncMethodCallback resultHandler40, TAsyncClient client36, TProtocolFactory protocolFactory37, TNonblockingTransport transport38) throws TException { - super(client36, protocolFactory37, transport38, resultHandler40, true); + public signout_call(long sessionId, AsyncMethodCallback resultHandler42, TAsyncClient client38, TProtocolFactory protocolFactory39, TNonblockingTransport transport40) throws TException { + super(client38, protocolFactory39, transport40, resultHandler42, true); this.sessionId = sessionId; } @@ -374,9 +476,9 @@ public void getResult() throws TException { } } - public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler44) throws TException { + public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler46) throws TException { checkReady(); - execute_call method_call = new execute_call(sessionId, stmt, resultHandler44, this, ___protocolFactory, ___transport); + execute_call method_call = new execute_call(sessionId, stmt, resultHandler46, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -384,8 +486,8 @@ public void execute(long sessionId, byte[] stmt, AsyncMethodCallback resultHandl public static class execute_call extends TAsyncMethodCall { private long sessionId; private byte[] stmt; - public execute_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler45, TAsyncClient client41, TProtocolFactory protocolFactory42, TNonblockingTransport transport43) throws TException { - super(client41, protocolFactory42, transport43, resultHandler45, false); + public execute_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler47, TAsyncClient client43, TProtocolFactory protocolFactory44, TNonblockingTransport transport45) throws TException { + super(client43, protocolFactory44, transport45, resultHandler47, false); this.sessionId = sessionId; this.stmt = stmt; } @@ -409,9 +511,47 @@ public ExecutionResponse getResult() throws TException { } } - public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler49) throws TException { + public void executeWithParameter(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler51) throws TException { + checkReady(); + executeWithParameter_call method_call = new executeWithParameter_call(sessionId, stmt, parameterMap, resultHandler51, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class executeWithParameter_call extends TAsyncMethodCall { + private long sessionId; + private byte[] stmt; + private Map parameterMap; + public executeWithParameter_call(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler52, TAsyncClient client48, TProtocolFactory protocolFactory49, TNonblockingTransport transport50) throws TException { + super(client48, protocolFactory49, transport50, resultHandler52, false); + this.sessionId = sessionId; + this.stmt = stmt; + this.parameterMap = parameterMap; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("executeWithParameter", TMessageType.CALL, 0)); + executeWithParameter_args args = new executeWithParameter_args(); + args.setSessionId(sessionId); + args.setStmt(stmt); + args.setParameterMap(parameterMap); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecutionResponse getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_executeWithParameter(); + } + } + + public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler56) throws TException { checkReady(); - executeJson_call method_call = new executeJson_call(sessionId, stmt, resultHandler49, this, ___protocolFactory, ___transport); + executeJson_call method_call = new executeJson_call(sessionId, stmt, resultHandler56, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } @@ -419,8 +559,8 @@ public void executeJson(long sessionId, byte[] stmt, AsyncMethodCallback resultH public static class executeJson_call extends TAsyncMethodCall { private long sessionId; private byte[] stmt; - public executeJson_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler50, TAsyncClient client46, TProtocolFactory protocolFactory47, TNonblockingTransport transport48) throws TException { - super(client46, protocolFactory47, transport48, resultHandler50, false); + public executeJson_call(long sessionId, byte[] stmt, AsyncMethodCallback resultHandler57, TAsyncClient client53, TProtocolFactory protocolFactory54, TNonblockingTransport transport55) throws TException { + super(client53, protocolFactory54, transport55, resultHandler57, false); this.sessionId = sessionId; this.stmt = stmt; } @@ -444,17 +584,55 @@ public byte[] getResult() throws TException { } } - public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler54) throws TException { + public void executeJsonWithParameter(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler61) throws TException { + checkReady(); + executeJsonWithParameter_call method_call = new executeJsonWithParameter_call(sessionId, stmt, parameterMap, resultHandler61, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class executeJsonWithParameter_call extends TAsyncMethodCall { + private long sessionId; + private byte[] stmt; + private Map parameterMap; + public executeJsonWithParameter_call(long sessionId, byte[] stmt, Map parameterMap, AsyncMethodCallback resultHandler62, TAsyncClient client58, TProtocolFactory protocolFactory59, TNonblockingTransport transport60) throws TException { + super(client58, protocolFactory59, transport60, resultHandler62, false); + this.sessionId = sessionId; + this.stmt = stmt; + this.parameterMap = parameterMap; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("executeJsonWithParameter", TMessageType.CALL, 0)); + executeJsonWithParameter_args args = new executeJsonWithParameter_args(); + args.setSessionId(sessionId); + args.setStmt(stmt); + args.setParameterMap(parameterMap); + args.write(prot); + prot.writeMessageEnd(); + } + + public byte[] getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_executeJsonWithParameter(); + } + } + + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler66) throws TException { checkReady(); - verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler54, this, ___protocolFactory, ___transport); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler66, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class verifyClientVersion_call extends TAsyncMethodCall { private VerifyClientVersionReq req; - public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler55, TAsyncClient client51, TProtocolFactory protocolFactory52, TNonblockingTransport transport53) throws TException { - super(client51, protocolFactory52, transport53, resultHandler55, false); + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler67, TAsyncClient client63, TProtocolFactory protocolFactory64, TNonblockingTransport transport65) throws TException { + super(client63, protocolFactory64, transport65, resultHandler67, false); this.req = req; } @@ -487,7 +665,9 @@ public Processor(Iface iface) processMap_.put("authenticate", new authenticate()); processMap_.put("signout", new signout()); processMap_.put("execute", new execute()); + processMap_.put("executeWithParameter", new executeWithParameter()); processMap_.put("executeJson", new executeJson()); + processMap_.put("executeJsonWithParameter", new executeJsonWithParameter()); processMap_.put("verifyClientVersion", new verifyClientVersion()); } @@ -577,6 +757,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class executeWithParameter implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphService.executeWithParameter", server_ctx); + executeWithParameter_args args = new executeWithParameter_args(); + event_handler_.preRead(handler_ctx, "GraphService.executeWithParameter"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphService.executeWithParameter", args); + executeWithParameter_result result = new executeWithParameter_result(); + result.success = iface_.executeWithParameter(args.sessionId, args.stmt, args.parameterMap); + event_handler_.preWrite(handler_ctx, "GraphService.executeWithParameter", result); + oprot.writeMessageBegin(new TMessage("executeWithParameter", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphService.executeWithParameter", result); + } + + } + private class executeJson implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -598,6 +799,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class executeJsonWithParameter implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("GraphService.executeJsonWithParameter", server_ctx); + executeJsonWithParameter_args args = new executeJsonWithParameter_args(); + event_handler_.preRead(handler_ctx, "GraphService.executeJsonWithParameter"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "GraphService.executeJsonWithParameter", args); + executeJsonWithParameter_result result = new executeJsonWithParameter_result(); + result.success = iface_.executeJsonWithParameter(args.sessionId, args.stmt, args.parameterMap); + event_handler_.preWrite(handler_ctx, "GraphService.executeJsonWithParameter", result); + oprot.writeMessageBegin(new TMessage("executeJsonWithParameter", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "GraphService.executeJsonWithParameter", result); + } + + } + private class verifyClientVersion implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -1848,15 +2070,18 @@ public void validate() throws TException { } - public static class executeJson_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("executeJson_args"); + public static class executeWithParameter_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("executeWithParameter_args"); private static final TField SESSION_ID_FIELD_DESC = new TField("sessionId", TType.I64, (short)1); private static final TField STMT_FIELD_DESC = new TField("stmt", TType.STRING, (short)2); + private static final TField PARAMETER_MAP_FIELD_DESC = new TField("parameterMap", TType.MAP, (short)3); public long sessionId; public byte[] stmt; + public Map parameterMap; public static final int SESSIONID = 1; public static final int STMT = 2; + public static final int PARAMETERMAP = 3; // isset id assignments private static final int __SESSIONID_ISSET_ID = 0; @@ -1870,46 +2095,55 @@ public static class executeJson_args implements TBase, java.io.Serializable, Clo new FieldValueMetaData(TType.I64))); tmpMetaDataMap.put(STMT, new FieldMetaData("stmt", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(PARAMETERMAP, new FieldMetaData("parameterMap", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(executeJson_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(executeWithParameter_args.class, metaDataMap); } - public executeJson_args() { + public executeWithParameter_args() { } - public executeJson_args( + public executeWithParameter_args( long sessionId, - byte[] stmt) { + byte[] stmt, + Map parameterMap) { this(); this.sessionId = sessionId; setSessionIdIsSet(true); this.stmt = stmt; + this.parameterMap = parameterMap; } /** * Performs a deep copy on other. */ - public executeJson_args(executeJson_args other) { + public executeWithParameter_args(executeWithParameter_args other) { __isset_bit_vector.clear(); __isset_bit_vector.or(other.__isset_bit_vector); this.sessionId = TBaseHelper.deepCopy(other.sessionId); if (other.isSetStmt()) { this.stmt = TBaseHelper.deepCopy(other.stmt); } + if (other.isSetParameterMap()) { + this.parameterMap = TBaseHelper.deepCopy(other.parameterMap); + } } - public executeJson_args deepCopy() { - return new executeJson_args(this); + public executeWithParameter_args deepCopy() { + return new executeWithParameter_args(this); } public long getSessionId() { return this.sessionId; } - public executeJson_args setSessionId(long sessionId) { + public executeWithParameter_args setSessionId(long sessionId) { this.sessionId = sessionId; setSessionIdIsSet(true); return this; @@ -1932,7 +2166,7 @@ public byte[] getStmt() { return this.stmt; } - public executeJson_args setStmt(byte[] stmt) { + public executeWithParameter_args setStmt(byte[] stmt) { this.stmt = stmt; return this; } @@ -1952,6 +2186,31 @@ public void setStmtIsSet(boolean __value) { } } + public Map getParameterMap() { + return this.parameterMap; + } + + public executeWithParameter_args setParameterMap(Map parameterMap) { + this.parameterMap = parameterMap; + return this; + } + + public void unsetParameterMap() { + this.parameterMap = null; + } + + // Returns true if field parameterMap is set (has been assigned a value) and false otherwise + public boolean isSetParameterMap() { + return this.parameterMap != null; + } + + public void setParameterMapIsSet(boolean __value) { + if (!__value) { + this.parameterMap = null; + } + } + + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SESSIONID: @@ -1970,6 +2229,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case PARAMETERMAP: + if (__value == null) { + unsetParameterMap(); + } else { + setParameterMap((Map)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -1983,6 +2250,9 @@ public Object getFieldValue(int fieldID) { case STMT: return getStmt(); + case PARAMETERMAP: + return getParameterMap(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -1994,51 +2264,22 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof executeJson_args)) + if (!(_that instanceof executeWithParameter_args)) return false; - executeJson_args that = (executeJson_args)_that; + executeWithParameter_args that = (executeWithParameter_args)_that; if (!TBaseHelper.equalsNobinary(this.sessionId, that.sessionId)) { return false; } if (!TBaseHelper.equalsSlow(this.isSetStmt(), that.isSetStmt(), this.stmt, that.stmt)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetParameterMap(), that.isSetParameterMap(), this.parameterMap, that.parameterMap)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {sessionId, stmt}); - } - - @Override - public int compareTo(executeJson_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(other.isSetSessionId()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(sessionId, other.sessionId); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStmt()).compareTo(other.isSetStmt()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(stmt, other.stmt); - if (lastComparison != 0) { - return lastComparison; - } - return 0; + return Arrays.deepHashCode(new Object[] {sessionId, stmt, parameterMap}); } public void read(TProtocol iprot) throws TException { @@ -2067,6 +2308,28 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case PARAMETERMAP: + if (__field.type == TType.MAP) { + { + TMap _map68 = iprot.readMapBegin(); + this.parameterMap = new HashMap(Math.max(0, 2*_map68.size)); + for (int _i69 = 0; + (_map68.size < 0) ? iprot.peekMap() : (_i69 < _map68.size); + ++_i69) + { + byte[] _key70; + com.vesoft.nebula.Value _val71; + _key70 = iprot.readBinary(); + _val71 = new com.vesoft.nebula.Value(); + _val71.read(iprot); + this.parameterMap.put(_key70, _val71); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -2092,6 +2355,18 @@ public void write(TProtocol oprot) throws TException { oprot.writeBinary(this.stmt); oprot.writeFieldEnd(); } + if (this.parameterMap != null) { + oprot.writeFieldBegin(PARAMETER_MAP_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.parameterMap.size())); + for (Map.Entry _iter72 : this.parameterMap.entrySet()) { + oprot.writeBinary(_iter72.getKey()); + _iter72.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -2106,7 +2381,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("executeJson_args"); + StringBuilder sb = new StringBuilder("executeWithParameter_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -2134,6 +2409,17 @@ public String toString(int indent, boolean prettyPrint) { if (this.getStmt().length > 128) sb.append(" ..."); } first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("parameterMap"); + sb.append(space); + sb.append(":").append(space); + if (this.getParameterMap() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParameterMap(), indent + 1, prettyPrint)); + } + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); @@ -2145,11 +2431,11 @@ public void validate() throws TException { } - public static class executeJson_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("executeJson_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRING, (short)0); + public static class executeWithParameter_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("executeWithParameter_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public byte[] success; + public ExecutionResponse success; public static final int SUCCESS = 0; // isset id assignments @@ -2159,19 +2445,19 @@ public static class executeJson_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); + new StructMetaData(TType.STRUCT, ExecutionResponse.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(executeJson_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(executeWithParameter_result.class, metaDataMap); } - public executeJson_result() { + public executeWithParameter_result() { } - public executeJson_result( - byte[] success) { + public executeWithParameter_result( + ExecutionResponse success) { this(); this.success = success; } @@ -2179,21 +2465,21 @@ public executeJson_result( /** * Performs a deep copy on other. */ - public executeJson_result(executeJson_result other) { + public executeWithParameter_result(executeWithParameter_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public executeJson_result deepCopy() { - return new executeJson_result(this); + public executeWithParameter_result deepCopy() { + return new executeWithParameter_result(this); } - public byte[] getSuccess() { + public ExecutionResponse getSuccess() { return this.success; } - public executeJson_result setSuccess(byte[] success) { + public executeWithParameter_result setSuccess(ExecutionResponse success) { this.success = success; return this; } @@ -2219,7 +2505,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((byte[])__value); + setSuccess((ExecutionResponse)__value); } break; @@ -2244,11 +2530,11 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof executeJson_result)) + if (!(_that instanceof executeWithParameter_result)) return false; - executeJson_result that = (executeJson_result)_that; + executeWithParameter_result that = (executeWithParameter_result)_that; - if (!TBaseHelper.equalsSlow(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } return true; } @@ -2258,9 +2544,1082 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } - @Override - public int compareTo(executeJson_result other) { - if (other == null) { + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ExecutionResponse(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("executeWithParameter_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class executeJson_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("executeJson_args"); + private static final TField SESSION_ID_FIELD_DESC = new TField("sessionId", TType.I64, (short)1); + private static final TField STMT_FIELD_DESC = new TField("stmt", TType.STRING, (short)2); + + public long sessionId; + public byte[] stmt; + public static final int SESSIONID = 1; + public static final int STMT = 2; + + // isset id assignments + private static final int __SESSIONID_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SESSIONID, new FieldMetaData("sessionId", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(STMT, new FieldMetaData("stmt", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(executeJson_args.class, metaDataMap); + } + + public executeJson_args() { + } + + public executeJson_args( + long sessionId, + byte[] stmt) { + this(); + this.sessionId = sessionId; + setSessionIdIsSet(true); + this.stmt = stmt; + } + + /** + * Performs a deep copy on other. + */ + public executeJson_args(executeJson_args other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.sessionId = TBaseHelper.deepCopy(other.sessionId); + if (other.isSetStmt()) { + this.stmt = TBaseHelper.deepCopy(other.stmt); + } + } + + public executeJson_args deepCopy() { + return new executeJson_args(this); + } + + public long getSessionId() { + return this.sessionId; + } + + public executeJson_args setSessionId(long sessionId) { + this.sessionId = sessionId; + setSessionIdIsSet(true); + return this; + } + + public void unsetSessionId() { + __isset_bit_vector.clear(__SESSIONID_ISSET_ID); + } + + // Returns true if field sessionId is set (has been assigned a value) and false otherwise + public boolean isSetSessionId() { + return __isset_bit_vector.get(__SESSIONID_ISSET_ID); + } + + public void setSessionIdIsSet(boolean __value) { + __isset_bit_vector.set(__SESSIONID_ISSET_ID, __value); + } + + public byte[] getStmt() { + return this.stmt; + } + + public executeJson_args setStmt(byte[] stmt) { + this.stmt = stmt; + return this; + } + + public void unsetStmt() { + this.stmt = null; + } + + // Returns true if field stmt is set (has been assigned a value) and false otherwise + public boolean isSetStmt() { + return this.stmt != null; + } + + public void setStmtIsSet(boolean __value) { + if (!__value) { + this.stmt = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SESSIONID: + if (__value == null) { + unsetSessionId(); + } else { + setSessionId((Long)__value); + } + break; + + case STMT: + if (__value == null) { + unsetStmt(); + } else { + setStmt((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SESSIONID: + return new Long(getSessionId()); + + case STMT: + return getStmt(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof executeJson_args)) + return false; + executeJson_args that = (executeJson_args)_that; + + if (!TBaseHelper.equalsNobinary(this.sessionId, that.sessionId)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetStmt(), that.isSetStmt(), this.stmt, that.stmt)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {sessionId, stmt}); + } + + @Override + public int compareTo(executeJson_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(other.isSetSessionId()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(sessionId, other.sessionId); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStmt()).compareTo(other.isSetStmt()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(stmt, other.stmt); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SESSIONID: + if (__field.type == TType.I64) { + this.sessionId = iprot.readI64(); + setSessionIdIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STMT: + if (__field.type == TType.STRING) { + this.stmt = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); + oprot.writeI64(this.sessionId); + oprot.writeFieldEnd(); + if (this.stmt != null) { + oprot.writeFieldBegin(STMT_FIELD_DESC); + oprot.writeBinary(this.stmt); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("executeJson_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("sessionId"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSessionId(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("stmt"); + sb.append(space); + sb.append(":").append(space); + if (this.getStmt() == null) { + sb.append("null"); + } else { + int __stmt_size = Math.min(this.getStmt().length, 128); + for (int i = 0; i < __stmt_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getStmt()[i]).length() > 1 ? Integer.toHexString(this.getStmt()[i]).substring(Integer.toHexString(this.getStmt()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getStmt()[i]).toUpperCase()); + } + if (this.getStmt().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class executeJson_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("executeJson_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRING, (short)0); + + public byte[] success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(executeJson_result.class, metaDataMap); + } + + public executeJson_result() { + } + + public executeJson_result( + byte[] success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public executeJson_result(executeJson_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public executeJson_result deepCopy() { + return new executeJson_result(this); + } + + public byte[] getSuccess() { + return this.success; + } + + public executeJson_result setSuccess(byte[] success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof executeJson_result)) + return false; + executeJson_result that = (executeJson_result)_that; + + if (!TBaseHelper.equalsSlow(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(executeJson_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRING) { + this.success = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + oprot.writeBinary(this.success); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("executeJson_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + int __success_size = Math.min(this.getSuccess().length, 128); + for (int i = 0; i < __success_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getSuccess()[i]).length() > 1 ? Integer.toHexString(this.getSuccess()[i]).substring(Integer.toHexString(this.getSuccess()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getSuccess()[i]).toUpperCase()); + } + if (this.getSuccess().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class executeJsonWithParameter_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("executeJsonWithParameter_args"); + private static final TField SESSION_ID_FIELD_DESC = new TField("sessionId", TType.I64, (short)1); + private static final TField STMT_FIELD_DESC = new TField("stmt", TType.STRING, (short)2); + private static final TField PARAMETER_MAP_FIELD_DESC = new TField("parameterMap", TType.MAP, (short)3); + + public long sessionId; + public byte[] stmt; + public Map parameterMap; + public static final int SESSIONID = 1; + public static final int STMT = 2; + public static final int PARAMETERMAP = 3; + + // isset id assignments + private static final int __SESSIONID_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SESSIONID, new FieldMetaData("sessionId", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(STMT, new FieldMetaData("stmt", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(PARAMETERMAP, new FieldMetaData("parameterMap", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(executeJsonWithParameter_args.class, metaDataMap); + } + + public executeJsonWithParameter_args() { + } + + public executeJsonWithParameter_args( + long sessionId, + byte[] stmt, + Map parameterMap) { + this(); + this.sessionId = sessionId; + setSessionIdIsSet(true); + this.stmt = stmt; + this.parameterMap = parameterMap; + } + + /** + * Performs a deep copy on other. + */ + public executeJsonWithParameter_args(executeJsonWithParameter_args other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.sessionId = TBaseHelper.deepCopy(other.sessionId); + if (other.isSetStmt()) { + this.stmt = TBaseHelper.deepCopy(other.stmt); + } + if (other.isSetParameterMap()) { + this.parameterMap = TBaseHelper.deepCopy(other.parameterMap); + } + } + + public executeJsonWithParameter_args deepCopy() { + return new executeJsonWithParameter_args(this); + } + + public long getSessionId() { + return this.sessionId; + } + + public executeJsonWithParameter_args setSessionId(long sessionId) { + this.sessionId = sessionId; + setSessionIdIsSet(true); + return this; + } + + public void unsetSessionId() { + __isset_bit_vector.clear(__SESSIONID_ISSET_ID); + } + + // Returns true if field sessionId is set (has been assigned a value) and false otherwise + public boolean isSetSessionId() { + return __isset_bit_vector.get(__SESSIONID_ISSET_ID); + } + + public void setSessionIdIsSet(boolean __value) { + __isset_bit_vector.set(__SESSIONID_ISSET_ID, __value); + } + + public byte[] getStmt() { + return this.stmt; + } + + public executeJsonWithParameter_args setStmt(byte[] stmt) { + this.stmt = stmt; + return this; + } + + public void unsetStmt() { + this.stmt = null; + } + + // Returns true if field stmt is set (has been assigned a value) and false otherwise + public boolean isSetStmt() { + return this.stmt != null; + } + + public void setStmtIsSet(boolean __value) { + if (!__value) { + this.stmt = null; + } + } + + public Map getParameterMap() { + return this.parameterMap; + } + + public executeJsonWithParameter_args setParameterMap(Map parameterMap) { + this.parameterMap = parameterMap; + return this; + } + + public void unsetParameterMap() { + this.parameterMap = null; + } + + // Returns true if field parameterMap is set (has been assigned a value) and false otherwise + public boolean isSetParameterMap() { + return this.parameterMap != null; + } + + public void setParameterMapIsSet(boolean __value) { + if (!__value) { + this.parameterMap = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SESSIONID: + if (__value == null) { + unsetSessionId(); + } else { + setSessionId((Long)__value); + } + break; + + case STMT: + if (__value == null) { + unsetStmt(); + } else { + setStmt((byte[])__value); + } + break; + + case PARAMETERMAP: + if (__value == null) { + unsetParameterMap(); + } else { + setParameterMap((Map)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SESSIONID: + return new Long(getSessionId()); + + case STMT: + return getStmt(); + + case PARAMETERMAP: + return getParameterMap(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof executeJsonWithParameter_args)) + return false; + executeJsonWithParameter_args that = (executeJsonWithParameter_args)_that; + + if (!TBaseHelper.equalsNobinary(this.sessionId, that.sessionId)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetStmt(), that.isSetStmt(), this.stmt, that.stmt)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetParameterMap(), that.isSetParameterMap(), this.parameterMap, that.parameterMap)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {sessionId, stmt, parameterMap}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SESSIONID: + if (__field.type == TType.I64) { + this.sessionId = iprot.readI64(); + setSessionIdIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STMT: + if (__field.type == TType.STRING) { + this.stmt = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARAMETERMAP: + if (__field.type == TType.MAP) { + { + TMap _map73 = iprot.readMapBegin(); + this.parameterMap = new HashMap(Math.max(0, 2*_map73.size)); + for (int _i74 = 0; + (_map73.size < 0) ? iprot.peekMap() : (_i74 < _map73.size); + ++_i74) + { + byte[] _key75; + com.vesoft.nebula.Value _val76; + _key75 = iprot.readBinary(); + _val76 = new com.vesoft.nebula.Value(); + _val76.read(iprot); + this.parameterMap.put(_key75, _val76); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); + oprot.writeI64(this.sessionId); + oprot.writeFieldEnd(); + if (this.stmt != null) { + oprot.writeFieldBegin(STMT_FIELD_DESC); + oprot.writeBinary(this.stmt); + oprot.writeFieldEnd(); + } + if (this.parameterMap != null) { + oprot.writeFieldBegin(PARAMETER_MAP_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.parameterMap.size())); + for (Map.Entry _iter77 : this.parameterMap.entrySet()) { + oprot.writeBinary(_iter77.getKey()); + _iter77.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("executeJsonWithParameter_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("sessionId"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSessionId(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("stmt"); + sb.append(space); + sb.append(":").append(space); + if (this.getStmt() == null) { + sb.append("null"); + } else { + int __stmt_size = Math.min(this.getStmt().length, 128); + for (int i = 0; i < __stmt_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getStmt()[i]).length() > 1 ? Integer.toHexString(this.getStmt()[i]).substring(Integer.toHexString(this.getStmt()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getStmt()[i]).toUpperCase()); + } + if (this.getStmt().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("parameterMap"); + sb.append(space); + sb.append(":").append(space); + if (this.getParameterMap() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParameterMap(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class executeJsonWithParameter_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("executeJsonWithParameter_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRING, (short)0); + + public byte[] success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(executeJsonWithParameter_result.class, metaDataMap); + } + + public executeJsonWithParameter_result() { + } + + public executeJsonWithParameter_result( + byte[] success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public executeJsonWithParameter_result(executeJsonWithParameter_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public executeJsonWithParameter_result deepCopy() { + return new executeJsonWithParameter_result(this); + } + + public byte[] getSuccess() { + return this.success; + } + + public executeJsonWithParameter_result setSuccess(byte[] success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof executeJsonWithParameter_result)) + return false; + executeJsonWithParameter_result that = (executeJsonWithParameter_result)_that; + + if (!TBaseHelper.equalsSlow(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(executeJsonWithParameter_result other) { + if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); } @@ -2334,7 +3693,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("executeJson_result"); + StringBuilder sb = new StringBuilder("executeJsonWithParameter_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java new file mode 100644 index 000000000..d442be0d0 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java @@ -0,0 +1,174 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListAllSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsReq"); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListAllSessionsReq.class, metaDataMap); + } + + public ListAllSessionsReq() { + } + + public static class Builder { + + public Builder() { + } + + public ListAllSessionsReq build() { + ListAllSessionsReq result = new ListAllSessionsReq(); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListAllSessionsReq(ListAllSessionsReq other) { + } + + public ListAllSessionsReq deepCopy() { + return new ListAllSessionsReq(this); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListAllSessionsReq)) + return false; + ListAllSessionsReq that = (ListAllSessionsReq)_that; + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {}); + } + + @Override + public int compareTo(ListAllSessionsReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListAllSessionsReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java new file mode 100644 index 000000000..70e5d311d --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java @@ -0,0 +1,360 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListAllSessionsResp implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsResp"); + private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); + private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)2); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode code; + public List sessions; + public static final int CODE = 1; + public static final int SESSIONS = 2; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Session.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListAllSessionsResp.class, metaDataMap); + } + + public ListAllSessionsResp() { + } + + public ListAllSessionsResp( + com.vesoft.nebula.ErrorCode code, + List sessions) { + this(); + this.code = code; + this.sessions = sessions; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode code; + private List sessions; + + public Builder() { + } + + public Builder setCode(final com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public Builder setSessions(final List sessions) { + this.sessions = sessions; + return this; + } + + public ListAllSessionsResp build() { + ListAllSessionsResp result = new ListAllSessionsResp(); + result.setCode(this.code); + result.setSessions(this.sessions); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListAllSessionsResp(ListAllSessionsResp other) { + if (other.isSetCode()) { + this.code = TBaseHelper.deepCopy(other.code); + } + if (other.isSetSessions()) { + this.sessions = TBaseHelper.deepCopy(other.sessions); + } + } + + public ListAllSessionsResp deepCopy() { + return new ListAllSessionsResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getCode() { + return this.code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public ListAllSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public void unsetCode() { + this.code = null; + } + + // Returns true if field code is set (has been assigned a value) and false otherwise + public boolean isSetCode() { + return this.code != null; + } + + public void setCodeIsSet(boolean __value) { + if (!__value) { + this.code = null; + } + } + + public List getSessions() { + return this.sessions; + } + + public ListAllSessionsResp setSessions(List sessions) { + this.sessions = sessions; + return this; + } + + public void unsetSessions() { + this.sessions = null; + } + + // Returns true if field sessions is set (has been assigned a value) and false otherwise + public boolean isSetSessions() { + return this.sessions != null; + } + + public void setSessionsIsSet(boolean __value) { + if (!__value) { + this.sessions = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CODE: + if (__value == null) { + unsetCode(); + } else { + setCode((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case SESSIONS: + if (__value == null) { + unsetSessions(); + } else { + setSessions((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CODE: + return getCode(); + + case SESSIONS: + return getSessions(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListAllSessionsResp)) + return false; + ListAllSessionsResp that = (ListAllSessionsResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {code, sessions}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CODE: + if (__field.type == TType.I32) { + this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SESSIONS: + if (__field.type == TType.LIST) { + { + TList _list36 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list36.size)); + for (int _i37 = 0; + (_list36.size < 0) ? iprot.peekList() : (_i37 < _list36.size); + ++_i37) + { + Session _elem38; + _elem38 = new Session(); + _elem38.read(iprot); + this.sessions.add(_elem38); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.code != null) { + oprot.writeFieldBegin(CODE_FIELD_DESC); + oprot.writeI32(this.code == null ? 0 : this.code.getValue()); + oprot.writeFieldEnd(); + } + if (this.sessions != null) { + oprot.writeFieldBegin(SESSIONS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); + for (Session _iter39 : this.sessions) { + _iter39.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListAllSessionsResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("code"); + sb.append(space); + sb.append(":").append(space); + if (this.getCode() == null) { + sb.append("null"); + } else { + String code_name = this.getCode() == null ? "null" : this.getCode().name(); + if (code_name != null) { + sb.append(code_name); + sb.append(" ("); + } + sb.append(this.getCode()); + if (code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("sessions"); + sb.append(space); + sb.append(":").append(space); + if (this.getSessions() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java new file mode 100644 index 000000000..14c048679 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java @@ -0,0 +1,174 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("ListSessionsReq"); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListSessionsReq.class, metaDataMap); + } + + public ListSessionsReq() { + } + + public static class Builder { + + public Builder() { + } + + public ListSessionsReq build() { + ListSessionsReq result = new ListSessionsReq(); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListSessionsReq(ListSessionsReq other) { + } + + public ListSessionsReq deepCopy() { + return new ListSessionsReq(this); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListSessionsReq)) + return false; + ListSessionsReq that = (ListSessionsReq)_that; + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {}); + } + + @Override + public int compareTo(ListSessionsReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListSessionsReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java new file mode 100644 index 000000000..f85103789 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java @@ -0,0 +1,438 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListSessionsResp implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ListSessionsResp"); + private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); + private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); + private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)3); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode code; + public com.vesoft.nebula.HostAddr leader; + public List sessions; + public static final int CODE = 1; + public static final int LEADER = 2; + public static final int SESSIONS = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Session.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListSessionsResp.class, metaDataMap); + } + + public ListSessionsResp() { + } + + public ListSessionsResp( + com.vesoft.nebula.ErrorCode code, + com.vesoft.nebula.HostAddr leader, + List sessions) { + this(); + this.code = code; + this.leader = leader; + this.sessions = sessions; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode code; + private com.vesoft.nebula.HostAddr leader; + private List sessions; + + public Builder() { + } + + public Builder setCode(final com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public Builder setSessions(final List sessions) { + this.sessions = sessions; + return this; + } + + public ListSessionsResp build() { + ListSessionsResp result = new ListSessionsResp(); + result.setCode(this.code); + result.setLeader(this.leader); + result.setSessions(this.sessions); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListSessionsResp(ListSessionsResp other) { + if (other.isSetCode()) { + this.code = TBaseHelper.deepCopy(other.code); + } + if (other.isSetLeader()) { + this.leader = TBaseHelper.deepCopy(other.leader); + } + if (other.isSetSessions()) { + this.sessions = TBaseHelper.deepCopy(other.sessions); + } + } + + public ListSessionsResp deepCopy() { + return new ListSessionsResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getCode() { + return this.code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public ListSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public void unsetCode() { + this.code = null; + } + + // Returns true if field code is set (has been assigned a value) and false otherwise + public boolean isSetCode() { + return this.code != null; + } + + public void setCodeIsSet(boolean __value) { + if (!__value) { + this.code = null; + } + } + + public com.vesoft.nebula.HostAddr getLeader() { + return this.leader; + } + + public ListSessionsResp setLeader(com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public void unsetLeader() { + this.leader = null; + } + + // Returns true if field leader is set (has been assigned a value) and false otherwise + public boolean isSetLeader() { + return this.leader != null; + } + + public void setLeaderIsSet(boolean __value) { + if (!__value) { + this.leader = null; + } + } + + public List getSessions() { + return this.sessions; + } + + public ListSessionsResp setSessions(List sessions) { + this.sessions = sessions; + return this; + } + + public void unsetSessions() { + this.sessions = null; + } + + // Returns true if field sessions is set (has been assigned a value) and false otherwise + public boolean isSetSessions() { + return this.sessions != null; + } + + public void setSessionsIsSet(boolean __value) { + if (!__value) { + this.sessions = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CODE: + if (__value == null) { + unsetCode(); + } else { + setCode((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case LEADER: + if (__value == null) { + unsetLeader(); + } else { + setLeader((com.vesoft.nebula.HostAddr)__value); + } + break; + + case SESSIONS: + if (__value == null) { + unsetSessions(); + } else { + setSessions((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CODE: + return getCode(); + + case LEADER: + return getLeader(); + + case SESSIONS: + return getSessions(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListSessionsResp)) + return false; + ListSessionsResp that = (ListSessionsResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {code, leader, sessions}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CODE: + if (__field.type == TType.I32) { + this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LEADER: + if (__field.type == TType.STRUCT) { + this.leader = new com.vesoft.nebula.HostAddr(); + this.leader.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SESSIONS: + if (__field.type == TType.LIST) { + { + TList _list36 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list36.size)); + for (int _i37 = 0; + (_list36.size < 0) ? iprot.peekList() : (_i37 < _list36.size); + ++_i37) + { + Session _elem38; + _elem38 = new Session(); + _elem38.read(iprot); + this.sessions.add(_elem38); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.code != null) { + oprot.writeFieldBegin(CODE_FIELD_DESC); + oprot.writeI32(this.code == null ? 0 : this.code.getValue()); + oprot.writeFieldEnd(); + } + if (this.leader != null) { + oprot.writeFieldBegin(LEADER_FIELD_DESC); + this.leader.write(oprot); + oprot.writeFieldEnd(); + } + if (this.sessions != null) { + oprot.writeFieldBegin(SESSIONS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); + for (Session _iter39 : this.sessions) { + _iter39.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListSessionsResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("code"); + sb.append(space); + sb.append(":").append(space); + if (this.getCode() == null) { + sb.append("null"); + } else { + String code_name = this.getCode() == null ? "null" : this.getCode().name(); + if (code_name != null) { + sb.append(code_name); + sb.append(" ("); + } + sb.append(this.getCode()); + if (code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("leader"); + sb.append(space); + sb.append(":").append(space); + if (this.getLeader() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("sessions"); + sb.append(space); + sb.append(":").append(space); + if (this.getSessions() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java b/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java new file mode 100644 index 000000000..25f9ea56a --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java @@ -0,0 +1,630 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class QueryDesc implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("QueryDesc"); + private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)1); + private static final TField STATUS_FIELD_DESC = new TField("status", TType.I32, (short)2); + private static final TField DURATION_FIELD_DESC = new TField("duration", TType.I64, (short)3); + private static final TField QUERY_FIELD_DESC = new TField("query", TType.STRING, (short)4); + private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)5); + + public long start_time; + /** + * + * @see QueryStatus + */ + public QueryStatus status; + public long duration; + public byte[] query; + public com.vesoft.nebula.HostAddr graph_addr; + public static final int START_TIME = 1; + public static final int STATUS = 2; + public static final int DURATION = 3; + public static final int QUERY = 4; + public static final int GRAPH_ADDR = 5; + + // isset id assignments + private static final int __START_TIME_ISSET_ID = 0; + private static final int __DURATION_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(START_TIME, new FieldMetaData("start_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(STATUS, new FieldMetaData("status", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(DURATION, new FieldMetaData("duration", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(QUERY, new FieldMetaData("query", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(QueryDesc.class, metaDataMap); + } + + public QueryDesc() { + } + + public QueryDesc( + long start_time, + QueryStatus status, + long duration, + byte[] query, + com.vesoft.nebula.HostAddr graph_addr) { + this(); + this.start_time = start_time; + setStart_timeIsSet(true); + this.status = status; + this.duration = duration; + setDurationIsSet(true); + this.query = query; + this.graph_addr = graph_addr; + } + + public static class Builder { + private long start_time; + private QueryStatus status; + private long duration; + private byte[] query; + private com.vesoft.nebula.HostAddr graph_addr; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setStart_time(final long start_time) { + this.start_time = start_time; + __optional_isset.set(__START_TIME_ISSET_ID, true); + return this; + } + + public Builder setStatus(final QueryStatus status) { + this.status = status; + return this; + } + + public Builder setDuration(final long duration) { + this.duration = duration; + __optional_isset.set(__DURATION_ISSET_ID, true); + return this; + } + + public Builder setQuery(final byte[] query) { + this.query = query; + return this; + } + + public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public QueryDesc build() { + QueryDesc result = new QueryDesc(); + if (__optional_isset.get(__START_TIME_ISSET_ID)) { + result.setStart_time(this.start_time); + } + result.setStatus(this.status); + if (__optional_isset.get(__DURATION_ISSET_ID)) { + result.setDuration(this.duration); + } + result.setQuery(this.query); + result.setGraph_addr(this.graph_addr); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public QueryDesc(QueryDesc other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.start_time = TBaseHelper.deepCopy(other.start_time); + if (other.isSetStatus()) { + this.status = TBaseHelper.deepCopy(other.status); + } + this.duration = TBaseHelper.deepCopy(other.duration); + if (other.isSetQuery()) { + this.query = TBaseHelper.deepCopy(other.query); + } + if (other.isSetGraph_addr()) { + this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); + } + } + + public QueryDesc deepCopy() { + return new QueryDesc(this); + } + + public long getStart_time() { + return this.start_time; + } + + public QueryDesc setStart_time(long start_time) { + this.start_time = start_time; + setStart_timeIsSet(true); + return this; + } + + public void unsetStart_time() { + __isset_bit_vector.clear(__START_TIME_ISSET_ID); + } + + // Returns true if field start_time is set (has been assigned a value) and false otherwise + public boolean isSetStart_time() { + return __isset_bit_vector.get(__START_TIME_ISSET_ID); + } + + public void setStart_timeIsSet(boolean __value) { + __isset_bit_vector.set(__START_TIME_ISSET_ID, __value); + } + + /** + * + * @see QueryStatus + */ + public QueryStatus getStatus() { + return this.status; + } + + /** + * + * @see QueryStatus + */ + public QueryDesc setStatus(QueryStatus status) { + this.status = status; + return this; + } + + public void unsetStatus() { + this.status = null; + } + + // Returns true if field status is set (has been assigned a value) and false otherwise + public boolean isSetStatus() { + return this.status != null; + } + + public void setStatusIsSet(boolean __value) { + if (!__value) { + this.status = null; + } + } + + public long getDuration() { + return this.duration; + } + + public QueryDesc setDuration(long duration) { + this.duration = duration; + setDurationIsSet(true); + return this; + } + + public void unsetDuration() { + __isset_bit_vector.clear(__DURATION_ISSET_ID); + } + + // Returns true if field duration is set (has been assigned a value) and false otherwise + public boolean isSetDuration() { + return __isset_bit_vector.get(__DURATION_ISSET_ID); + } + + public void setDurationIsSet(boolean __value) { + __isset_bit_vector.set(__DURATION_ISSET_ID, __value); + } + + public byte[] getQuery() { + return this.query; + } + + public QueryDesc setQuery(byte[] query) { + this.query = query; + return this; + } + + public void unsetQuery() { + this.query = null; + } + + // Returns true if field query is set (has been assigned a value) and false otherwise + public boolean isSetQuery() { + return this.query != null; + } + + public void setQueryIsSet(boolean __value) { + if (!__value) { + this.query = null; + } + } + + public com.vesoft.nebula.HostAddr getGraph_addr() { + return this.graph_addr; + } + + public QueryDesc setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public void unsetGraph_addr() { + this.graph_addr = null; + } + + // Returns true if field graph_addr is set (has been assigned a value) and false otherwise + public boolean isSetGraph_addr() { + return this.graph_addr != null; + } + + public void setGraph_addrIsSet(boolean __value) { + if (!__value) { + this.graph_addr = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case START_TIME: + if (__value == null) { + unsetStart_time(); + } else { + setStart_time((Long)__value); + } + break; + + case STATUS: + if (__value == null) { + unsetStatus(); + } else { + setStatus((QueryStatus)__value); + } + break; + + case DURATION: + if (__value == null) { + unsetDuration(); + } else { + setDuration((Long)__value); + } + break; + + case QUERY: + if (__value == null) { + unsetQuery(); + } else { + setQuery((byte[])__value); + } + break; + + case GRAPH_ADDR: + if (__value == null) { + unsetGraph_addr(); + } else { + setGraph_addr((com.vesoft.nebula.HostAddr)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case START_TIME: + return new Long(getStart_time()); + + case STATUS: + return getStatus(); + + case DURATION: + return new Long(getDuration()); + + case QUERY: + return getQuery(); + + case GRAPH_ADDR: + return getGraph_addr(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof QueryDesc)) + return false; + QueryDesc that = (QueryDesc)_that; + + if (!TBaseHelper.equalsNobinary(this.start_time, that.start_time)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetStatus(), that.isSetStatus(), this.status, that.status)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.duration, that.duration)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetQuery(), that.isSetQuery(), this.query, that.query)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {start_time, status, duration, query, graph_addr}); + } + + @Override + public int compareTo(QueryDesc other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetStart_time()).compareTo(other.isSetStart_time()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(start_time, other.start_time); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(status, other.status); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetDuration()).compareTo(other.isSetDuration()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(duration, other.duration); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetQuery()).compareTo(other.isSetQuery()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(query, other.query); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetGraph_addr()).compareTo(other.isSetGraph_addr()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(graph_addr, other.graph_addr); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case START_TIME: + if (__field.type == TType.I64) { + this.start_time = iprot.readI64(); + setStart_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STATUS: + if (__field.type == TType.I32) { + this.status = QueryStatus.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case DURATION: + if (__field.type == TType.I64) { + this.duration = iprot.readI64(); + setDurationIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case QUERY: + if (__field.type == TType.STRING) { + this.query = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case GRAPH_ADDR: + if (__field.type == TType.STRUCT) { + this.graph_addr = new com.vesoft.nebula.HostAddr(); + this.graph_addr.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(START_TIME_FIELD_DESC); + oprot.writeI64(this.start_time); + oprot.writeFieldEnd(); + if (this.status != null) { + oprot.writeFieldBegin(STATUS_FIELD_DESC); + oprot.writeI32(this.status == null ? 0 : this.status.getValue()); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(DURATION_FIELD_DESC); + oprot.writeI64(this.duration); + oprot.writeFieldEnd(); + if (this.query != null) { + oprot.writeFieldBegin(QUERY_FIELD_DESC); + oprot.writeBinary(this.query); + oprot.writeFieldEnd(); + } + if (this.graph_addr != null) { + oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); + this.graph_addr.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("QueryDesc"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("start_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getStart_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("status"); + sb.append(space); + sb.append(":").append(space); + if (this.getStatus() == null) { + sb.append("null"); + } else { + String status_name = this.getStatus() == null ? "null" : this.getStatus().name(); + if (status_name != null) { + sb.append(status_name); + sb.append(" ("); + } + sb.append(this.getStatus()); + if (status_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("duration"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getDuration(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("query"); + sb.append(space); + sb.append(":").append(space); + if (this.getQuery() == null) { + sb.append("null"); + } else { + int __query_size = Math.min(this.getQuery().length, 128); + for (int i = 0; i < __query_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getQuery()[i]).length() > 1 ? Integer.toHexString(this.getQuery()[i]).substring(Integer.toHexString(this.getQuery()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getQuery()[i]).toUpperCase()); + } + if (this.getQuery().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("graph_addr"); + sb.append(space); + sb.append(":").append(space); + if (this.getGraph_addr() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java b/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java new file mode 100644 index 000000000..62ee710a7 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java @@ -0,0 +1,46 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + + +import com.facebook.thrift.IntRangeSet; +import java.util.Map; +import java.util.HashMap; + +@SuppressWarnings({ "unused" }) +public enum QueryStatus implements com.facebook.thrift.TEnum { + RUNNING(1), + KILLING(2); + + private final int value; + + private QueryStatus(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static QueryStatus findByValue(int value) { + switch (value) { + case 1: + return RUNNING; + case 2: + return KILLING; + default: + return null; + } + } +} diff --git a/client/src/main/generated/com/vesoft/nebula/graph/Session.java b/client/src/main/generated/com/vesoft/nebula/graph/Session.java new file mode 100644 index 000000000..d8afef2ed --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/graph/Session.java @@ -0,0 +1,993 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.graph; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class Session implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("Session"); + private static final TField SESSION_ID_FIELD_DESC = new TField("session_id", TType.I64, (short)1); + private static final TField CREATE_TIME_FIELD_DESC = new TField("create_time", TType.I64, (short)2); + private static final TField UPDATE_TIME_FIELD_DESC = new TField("update_time", TType.I64, (short)3); + private static final TField USER_NAME_FIELD_DESC = new TField("user_name", TType.STRING, (short)4); + private static final TField SPACE_NAME_FIELD_DESC = new TField("space_name", TType.STRING, (short)5); + private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)6); + private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)7); + private static final TField CLIENT_IP_FIELD_DESC = new TField("client_ip", TType.STRING, (short)8); + private static final TField CONFIGS_FIELD_DESC = new TField("configs", TType.MAP, (short)9); + private static final TField QUERIES_FIELD_DESC = new TField("queries", TType.MAP, (short)10); + + public long session_id; + public long create_time; + public long update_time; + public byte[] user_name; + public byte[] space_name; + public com.vesoft.nebula.HostAddr graph_addr; + public int timezone; + public byte[] client_ip; + public Map configs; + public Map queries; + public static final int SESSION_ID = 1; + public static final int CREATE_TIME = 2; + public static final int UPDATE_TIME = 3; + public static final int USER_NAME = 4; + public static final int SPACE_NAME = 5; + public static final int GRAPH_ADDR = 6; + public static final int TIMEZONE = 7; + public static final int CLIENT_IP = 8; + public static final int CONFIGS = 9; + public static final int QUERIES = 10; + + // isset id assignments + private static final int __SESSION_ID_ISSET_ID = 0; + private static final int __CREATE_TIME_ISSET_ID = 1; + private static final int __UPDATE_TIME_ISSET_ID = 2; + private static final int __TIMEZONE_ISSET_ID = 3; + private BitSet __isset_bit_vector = new BitSet(4); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SESSION_ID, new FieldMetaData("session_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(CREATE_TIME, new FieldMetaData("create_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(UPDATE_TIME, new FieldMetaData("update_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(USER_NAME, new FieldMetaData("user_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(SPACE_NAME, new FieldMetaData("space_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(CLIENT_IP, new FieldMetaData("client_ip", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(CONFIGS, new FieldMetaData("configs", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); + tmpMetaDataMap.put(QUERIES, new FieldMetaData("queries", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I64), + new StructMetaData(TType.STRUCT, QueryDesc.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(Session.class, metaDataMap); + } + + public Session() { + } + + public Session( + long session_id, + long create_time, + long update_time, + byte[] user_name, + byte[] space_name, + com.vesoft.nebula.HostAddr graph_addr, + int timezone, + byte[] client_ip, + Map configs, + Map queries) { + this(); + this.session_id = session_id; + setSession_idIsSet(true); + this.create_time = create_time; + setCreate_timeIsSet(true); + this.update_time = update_time; + setUpdate_timeIsSet(true); + this.user_name = user_name; + this.space_name = space_name; + this.graph_addr = graph_addr; + this.timezone = timezone; + setTimezoneIsSet(true); + this.client_ip = client_ip; + this.configs = configs; + this.queries = queries; + } + + public static class Builder { + private long session_id; + private long create_time; + private long update_time; + private byte[] user_name; + private byte[] space_name; + private com.vesoft.nebula.HostAddr graph_addr; + private int timezone; + private byte[] client_ip; + private Map configs; + private Map queries; + + BitSet __optional_isset = new BitSet(4); + + public Builder() { + } + + public Builder setSession_id(final long session_id) { + this.session_id = session_id; + __optional_isset.set(__SESSION_ID_ISSET_ID, true); + return this; + } + + public Builder setCreate_time(final long create_time) { + this.create_time = create_time; + __optional_isset.set(__CREATE_TIME_ISSET_ID, true); + return this; + } + + public Builder setUpdate_time(final long update_time) { + this.update_time = update_time; + __optional_isset.set(__UPDATE_TIME_ISSET_ID, true); + return this; + } + + public Builder setUser_name(final byte[] user_name) { + this.user_name = user_name; + return this; + } + + public Builder setSpace_name(final byte[] space_name) { + this.space_name = space_name; + return this; + } + + public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public Builder setTimezone(final int timezone) { + this.timezone = timezone; + __optional_isset.set(__TIMEZONE_ISSET_ID, true); + return this; + } + + public Builder setClient_ip(final byte[] client_ip) { + this.client_ip = client_ip; + return this; + } + + public Builder setConfigs(final Map configs) { + this.configs = configs; + return this; + } + + public Builder setQueries(final Map queries) { + this.queries = queries; + return this; + } + + public Session build() { + Session result = new Session(); + if (__optional_isset.get(__SESSION_ID_ISSET_ID)) { + result.setSession_id(this.session_id); + } + if (__optional_isset.get(__CREATE_TIME_ISSET_ID)) { + result.setCreate_time(this.create_time); + } + if (__optional_isset.get(__UPDATE_TIME_ISSET_ID)) { + result.setUpdate_time(this.update_time); + } + result.setUser_name(this.user_name); + result.setSpace_name(this.space_name); + result.setGraph_addr(this.graph_addr); + if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { + result.setTimezone(this.timezone); + } + result.setClient_ip(this.client_ip); + result.setConfigs(this.configs); + result.setQueries(this.queries); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public Session(Session other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.session_id = TBaseHelper.deepCopy(other.session_id); + this.create_time = TBaseHelper.deepCopy(other.create_time); + this.update_time = TBaseHelper.deepCopy(other.update_time); + if (other.isSetUser_name()) { + this.user_name = TBaseHelper.deepCopy(other.user_name); + } + if (other.isSetSpace_name()) { + this.space_name = TBaseHelper.deepCopy(other.space_name); + } + if (other.isSetGraph_addr()) { + this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); + } + this.timezone = TBaseHelper.deepCopy(other.timezone); + if (other.isSetClient_ip()) { + this.client_ip = TBaseHelper.deepCopy(other.client_ip); + } + if (other.isSetConfigs()) { + this.configs = TBaseHelper.deepCopy(other.configs); + } + if (other.isSetQueries()) { + this.queries = TBaseHelper.deepCopy(other.queries); + } + } + + public Session deepCopy() { + return new Session(this); + } + + public long getSession_id() { + return this.session_id; + } + + public Session setSession_id(long session_id) { + this.session_id = session_id; + setSession_idIsSet(true); + return this; + } + + public void unsetSession_id() { + __isset_bit_vector.clear(__SESSION_ID_ISSET_ID); + } + + // Returns true if field session_id is set (has been assigned a value) and false otherwise + public boolean isSetSession_id() { + return __isset_bit_vector.get(__SESSION_ID_ISSET_ID); + } + + public void setSession_idIsSet(boolean __value) { + __isset_bit_vector.set(__SESSION_ID_ISSET_ID, __value); + } + + public long getCreate_time() { + return this.create_time; + } + + public Session setCreate_time(long create_time) { + this.create_time = create_time; + setCreate_timeIsSet(true); + return this; + } + + public void unsetCreate_time() { + __isset_bit_vector.clear(__CREATE_TIME_ISSET_ID); + } + + // Returns true if field create_time is set (has been assigned a value) and false otherwise + public boolean isSetCreate_time() { + return __isset_bit_vector.get(__CREATE_TIME_ISSET_ID); + } + + public void setCreate_timeIsSet(boolean __value) { + __isset_bit_vector.set(__CREATE_TIME_ISSET_ID, __value); + } + + public long getUpdate_time() { + return this.update_time; + } + + public Session setUpdate_time(long update_time) { + this.update_time = update_time; + setUpdate_timeIsSet(true); + return this; + } + + public void unsetUpdate_time() { + __isset_bit_vector.clear(__UPDATE_TIME_ISSET_ID); + } + + // Returns true if field update_time is set (has been assigned a value) and false otherwise + public boolean isSetUpdate_time() { + return __isset_bit_vector.get(__UPDATE_TIME_ISSET_ID); + } + + public void setUpdate_timeIsSet(boolean __value) { + __isset_bit_vector.set(__UPDATE_TIME_ISSET_ID, __value); + } + + public byte[] getUser_name() { + return this.user_name; + } + + public Session setUser_name(byte[] user_name) { + this.user_name = user_name; + return this; + } + + public void unsetUser_name() { + this.user_name = null; + } + + // Returns true if field user_name is set (has been assigned a value) and false otherwise + public boolean isSetUser_name() { + return this.user_name != null; + } + + public void setUser_nameIsSet(boolean __value) { + if (!__value) { + this.user_name = null; + } + } + + public byte[] getSpace_name() { + return this.space_name; + } + + public Session setSpace_name(byte[] space_name) { + this.space_name = space_name; + return this; + } + + public void unsetSpace_name() { + this.space_name = null; + } + + // Returns true if field space_name is set (has been assigned a value) and false otherwise + public boolean isSetSpace_name() { + return this.space_name != null; + } + + public void setSpace_nameIsSet(boolean __value) { + if (!__value) { + this.space_name = null; + } + } + + public com.vesoft.nebula.HostAddr getGraph_addr() { + return this.graph_addr; + } + + public Session setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public void unsetGraph_addr() { + this.graph_addr = null; + } + + // Returns true if field graph_addr is set (has been assigned a value) and false otherwise + public boolean isSetGraph_addr() { + return this.graph_addr != null; + } + + public void setGraph_addrIsSet(boolean __value) { + if (!__value) { + this.graph_addr = null; + } + } + + public int getTimezone() { + return this.timezone; + } + + public Session setTimezone(int timezone) { + this.timezone = timezone; + setTimezoneIsSet(true); + return this; + } + + public void unsetTimezone() { + __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); + } + + // Returns true if field timezone is set (has been assigned a value) and false otherwise + public boolean isSetTimezone() { + return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); + } + + public void setTimezoneIsSet(boolean __value) { + __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); + } + + public byte[] getClient_ip() { + return this.client_ip; + } + + public Session setClient_ip(byte[] client_ip) { + this.client_ip = client_ip; + return this; + } + + public void unsetClient_ip() { + this.client_ip = null; + } + + // Returns true if field client_ip is set (has been assigned a value) and false otherwise + public boolean isSetClient_ip() { + return this.client_ip != null; + } + + public void setClient_ipIsSet(boolean __value) { + if (!__value) { + this.client_ip = null; + } + } + + public Map getConfigs() { + return this.configs; + } + + public Session setConfigs(Map configs) { + this.configs = configs; + return this; + } + + public void unsetConfigs() { + this.configs = null; + } + + // Returns true if field configs is set (has been assigned a value) and false otherwise + public boolean isSetConfigs() { + return this.configs != null; + } + + public void setConfigsIsSet(boolean __value) { + if (!__value) { + this.configs = null; + } + } + + public Map getQueries() { + return this.queries; + } + + public Session setQueries(Map queries) { + this.queries = queries; + return this; + } + + public void unsetQueries() { + this.queries = null; + } + + // Returns true if field queries is set (has been assigned a value) and false otherwise + public boolean isSetQueries() { + return this.queries != null; + } + + public void setQueriesIsSet(boolean __value) { + if (!__value) { + this.queries = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SESSION_ID: + if (__value == null) { + unsetSession_id(); + } else { + setSession_id((Long)__value); + } + break; + + case CREATE_TIME: + if (__value == null) { + unsetCreate_time(); + } else { + setCreate_time((Long)__value); + } + break; + + case UPDATE_TIME: + if (__value == null) { + unsetUpdate_time(); + } else { + setUpdate_time((Long)__value); + } + break; + + case USER_NAME: + if (__value == null) { + unsetUser_name(); + } else { + setUser_name((byte[])__value); + } + break; + + case SPACE_NAME: + if (__value == null) { + unsetSpace_name(); + } else { + setSpace_name((byte[])__value); + } + break; + + case GRAPH_ADDR: + if (__value == null) { + unsetGraph_addr(); + } else { + setGraph_addr((com.vesoft.nebula.HostAddr)__value); + } + break; + + case TIMEZONE: + if (__value == null) { + unsetTimezone(); + } else { + setTimezone((Integer)__value); + } + break; + + case CLIENT_IP: + if (__value == null) { + unsetClient_ip(); + } else { + setClient_ip((byte[])__value); + } + break; + + case CONFIGS: + if (__value == null) { + unsetConfigs(); + } else { + setConfigs((Map)__value); + } + break; + + case QUERIES: + if (__value == null) { + unsetQueries(); + } else { + setQueries((Map)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SESSION_ID: + return new Long(getSession_id()); + + case CREATE_TIME: + return new Long(getCreate_time()); + + case UPDATE_TIME: + return new Long(getUpdate_time()); + + case USER_NAME: + return getUser_name(); + + case SPACE_NAME: + return getSpace_name(); + + case GRAPH_ADDR: + return getGraph_addr(); + + case TIMEZONE: + return new Integer(getTimezone()); + + case CLIENT_IP: + return getClient_ip(); + + case CONFIGS: + return getConfigs(); + + case QUERIES: + return getQueries(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof Session)) + return false; + Session that = (Session)_that; + + if (!TBaseHelper.equalsNobinary(this.session_id, that.session_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.create_time, that.create_time)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.update_time, that.update_time)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetUser_name(), that.isSetUser_name(), this.user_name, that.user_name)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetSpace_name(), that.isSetSpace_name(), this.space_name, that.space_name)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetClient_ip(), that.isSetClient_ip(), this.client_ip, that.client_ip)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetConfigs(), that.isSetConfigs(), this.configs, that.configs)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetQueries(), that.isSetQueries(), this.queries, that.queries)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {session_id, create_time, update_time, user_name, space_name, graph_addr, timezone, client_ip, configs, queries}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SESSION_ID: + if (__field.type == TType.I64) { + this.session_id = iprot.readI64(); + setSession_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case CREATE_TIME: + if (__field.type == TType.I64) { + this.create_time = iprot.readI64(); + setCreate_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case UPDATE_TIME: + if (__field.type == TType.I64) { + this.update_time = iprot.readI64(); + setUpdate_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case USER_NAME: + if (__field.type == TType.STRING) { + this.user_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SPACE_NAME: + if (__field.type == TType.STRING) { + this.space_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case GRAPH_ADDR: + if (__field.type == TType.STRUCT) { + this.graph_addr = new com.vesoft.nebula.HostAddr(); + this.graph_addr.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TIMEZONE: + if (__field.type == TType.I32) { + this.timezone = iprot.readI32(); + setTimezoneIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case CLIENT_IP: + if (__field.type == TType.STRING) { + this.client_ip = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case CONFIGS: + if (__field.type == TType.MAP) { + { + TMap _map26 = iprot.readMapBegin(); + this.configs = new HashMap(Math.max(0, 2*_map26.size)); + for (int _i27 = 0; + (_map26.size < 0) ? iprot.peekMap() : (_i27 < _map26.size); + ++_i27) + { + byte[] _key28; + com.vesoft.nebula.Value _val29; + _key28 = iprot.readBinary(); + _val29 = new com.vesoft.nebula.Value(); + _val29.read(iprot); + this.configs.put(_key28, _val29); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case QUERIES: + if (__field.type == TType.MAP) { + { + TMap _map30 = iprot.readMapBegin(); + this.queries = new HashMap(Math.max(0, 2*_map30.size)); + for (int _i31 = 0; + (_map30.size < 0) ? iprot.peekMap() : (_i31 < _map30.size); + ++_i31) + { + long _key32; + QueryDesc _val33; + _key32 = iprot.readI64(); + _val33 = new QueryDesc(); + _val33.read(iprot); + this.queries.put(_key32, _val33); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); + oprot.writeI64(this.session_id); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); + oprot.writeI64(this.create_time); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(UPDATE_TIME_FIELD_DESC); + oprot.writeI64(this.update_time); + oprot.writeFieldEnd(); + if (this.user_name != null) { + oprot.writeFieldBegin(USER_NAME_FIELD_DESC); + oprot.writeBinary(this.user_name); + oprot.writeFieldEnd(); + } + if (this.space_name != null) { + oprot.writeFieldBegin(SPACE_NAME_FIELD_DESC); + oprot.writeBinary(this.space_name); + oprot.writeFieldEnd(); + } + if (this.graph_addr != null) { + oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); + this.graph_addr.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); + oprot.writeI32(this.timezone); + oprot.writeFieldEnd(); + if (this.client_ip != null) { + oprot.writeFieldBegin(CLIENT_IP_FIELD_DESC); + oprot.writeBinary(this.client_ip); + oprot.writeFieldEnd(); + } + if (this.configs != null) { + oprot.writeFieldBegin(CONFIGS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.configs.size())); + for (Map.Entry _iter34 : this.configs.entrySet()) { + oprot.writeBinary(_iter34.getKey()); + _iter34.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.queries != null) { + oprot.writeFieldBegin(QUERIES_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, this.queries.size())); + for (Map.Entry _iter35 : this.queries.entrySet()) { + oprot.writeI64(_iter35.getKey()); + _iter35.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("Session"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("session_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSession_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("create_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getCreate_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("update_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getUpdate_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("user_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getUser_name() == null) { + sb.append("null"); + } else { + int __user_name_size = Math.min(this.getUser_name().length, 128); + for (int i = 0; i < __user_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getUser_name()[i]).length() > 1 ? Integer.toHexString(this.getUser_name()[i]).substring(Integer.toHexString(this.getUser_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getUser_name()[i]).toUpperCase()); + } + if (this.getUser_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("space_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getSpace_name() == null) { + sb.append("null"); + } else { + int __space_name_size = Math.min(this.getSpace_name().length, 128); + for (int i = 0; i < __space_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getSpace_name()[i]).length() > 1 ? Integer.toHexString(this.getSpace_name()[i]).substring(Integer.toHexString(this.getSpace_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getSpace_name()[i]).toUpperCase()); + } + if (this.getSpace_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("graph_addr"); + sb.append(space); + sb.append(":").append(space); + if (this.getGraph_addr() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("timezone"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("client_ip"); + sb.append(space); + sb.append(":").append(space); + if (this.getClient_ip() == null) { + sb.append("null"); + } else { + int __client_ip_size = Math.min(this.getClient_ip().length, 128); + for (int i = 0; i < __client_ip_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getClient_ip()[i]).length() > 1 ? Integer.toHexString(this.getClient_ip()[i]).substring(Integer.toHexString(this.getClient_ip()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getClient_ip()[i]).toUpperCase()); + } + if (this.getClient_ip().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("configs"); + sb.append(space); + sb.append(":").append(space); + if (this.getConfigs() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getConfigs(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("queries"); + sb.append(space); + sb.append(":").append(space); + if (this.getQueries() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getQueries(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java new file mode 100644 index 000000000..ac8fdfb53 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java @@ -0,0 +1,463 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class AddHostsIntoZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("AddHostsIntoZoneReq"); + private static final TField HOSTS_FIELD_DESC = new TField("hosts", TType.LIST, (short)1); + private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)2); + private static final TField IS_NEW_FIELD_DESC = new TField("is_new", TType.BOOL, (short)3); + + public List hosts; + public byte[] zone_name; + public boolean is_new; + public static final int HOSTS = 1; + public static final int ZONE_NAME = 2; + public static final int IS_NEW = 3; + + // isset id assignments + private static final int __IS_NEW_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(HOSTS, new FieldMetaData("hosts", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); + tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(IS_NEW, new FieldMetaData("is_new", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(AddHostsIntoZoneReq.class, metaDataMap); + } + + public AddHostsIntoZoneReq() { + } + + public AddHostsIntoZoneReq( + List hosts, + byte[] zone_name, + boolean is_new) { + this(); + this.hosts = hosts; + this.zone_name = zone_name; + this.is_new = is_new; + setIs_newIsSet(true); + } + + public static class Builder { + private List hosts; + private byte[] zone_name; + private boolean is_new; + + BitSet __optional_isset = new BitSet(1); + + public Builder() { + } + + public Builder setHosts(final List hosts) { + this.hosts = hosts; + return this; + } + + public Builder setZone_name(final byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public Builder setIs_new(final boolean is_new) { + this.is_new = is_new; + __optional_isset.set(__IS_NEW_ISSET_ID, true); + return this; + } + + public AddHostsIntoZoneReq build() { + AddHostsIntoZoneReq result = new AddHostsIntoZoneReq(); + result.setHosts(this.hosts); + result.setZone_name(this.zone_name); + if (__optional_isset.get(__IS_NEW_ISSET_ID)) { + result.setIs_new(this.is_new); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public AddHostsIntoZoneReq(AddHostsIntoZoneReq other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + if (other.isSetHosts()) { + this.hosts = TBaseHelper.deepCopy(other.hosts); + } + if (other.isSetZone_name()) { + this.zone_name = TBaseHelper.deepCopy(other.zone_name); + } + this.is_new = TBaseHelper.deepCopy(other.is_new); + } + + public AddHostsIntoZoneReq deepCopy() { + return new AddHostsIntoZoneReq(this); + } + + public List getHosts() { + return this.hosts; + } + + public AddHostsIntoZoneReq setHosts(List hosts) { + this.hosts = hosts; + return this; + } + + public void unsetHosts() { + this.hosts = null; + } + + // Returns true if field hosts is set (has been assigned a value) and false otherwise + public boolean isSetHosts() { + return this.hosts != null; + } + + public void setHostsIsSet(boolean __value) { + if (!__value) { + this.hosts = null; + } + } + + public byte[] getZone_name() { + return this.zone_name; + } + + public AddHostsIntoZoneReq setZone_name(byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public void unsetZone_name() { + this.zone_name = null; + } + + // Returns true if field zone_name is set (has been assigned a value) and false otherwise + public boolean isSetZone_name() { + return this.zone_name != null; + } + + public void setZone_nameIsSet(boolean __value) { + if (!__value) { + this.zone_name = null; + } + } + + public boolean isIs_new() { + return this.is_new; + } + + public AddHostsIntoZoneReq setIs_new(boolean is_new) { + this.is_new = is_new; + setIs_newIsSet(true); + return this; + } + + public void unsetIs_new() { + __isset_bit_vector.clear(__IS_NEW_ISSET_ID); + } + + // Returns true if field is_new is set (has been assigned a value) and false otherwise + public boolean isSetIs_new() { + return __isset_bit_vector.get(__IS_NEW_ISSET_ID); + } + + public void setIs_newIsSet(boolean __value) { + __isset_bit_vector.set(__IS_NEW_ISSET_ID, __value); + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case HOSTS: + if (__value == null) { + unsetHosts(); + } else { + setHosts((List)__value); + } + break; + + case ZONE_NAME: + if (__value == null) { + unsetZone_name(); + } else { + setZone_name((byte[])__value); + } + break; + + case IS_NEW: + if (__value == null) { + unsetIs_new(); + } else { + setIs_new((Boolean)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case HOSTS: + return getHosts(); + + case ZONE_NAME: + return getZone_name(); + + case IS_NEW: + return new Boolean(isIs_new()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof AddHostsIntoZoneReq)) + return false; + AddHostsIntoZoneReq that = (AddHostsIntoZoneReq)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetHosts(), that.isSetHosts(), this.hosts, that.hosts)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.is_new, that.is_new)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {hosts, zone_name, is_new}); + } + + @Override + public int compareTo(AddHostsIntoZoneReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetHosts()).compareTo(other.isSetHosts()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(hosts, other.hosts); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetIs_new()).compareTo(other.isSetIs_new()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(is_new, other.is_new); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case HOSTS: + if (__field.type == TType.LIST) { + { + TList _list224 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list224.size)); + for (int _i225 = 0; + (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); + ++_i225) + { + com.vesoft.nebula.HostAddr _elem226; + _elem226 = new com.vesoft.nebula.HostAddr(); + _elem226.read(iprot); + this.hosts.add(_elem226); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ZONE_NAME: + if (__field.type == TType.STRING) { + this.zone_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case IS_NEW: + if (__field.type == TType.BOOL) { + this.is_new = iprot.readBool(); + setIs_newIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.hosts != null) { + oprot.writeFieldBegin(HOSTS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); + for (com.vesoft.nebula.HostAddr _iter227 : this.hosts) { + _iter227.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + if (this.zone_name != null) { + oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); + oprot.writeBinary(this.zone_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(IS_NEW_FIELD_DESC); + oprot.writeBool(this.is_new); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("AddHostsIntoZoneReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("hosts"); + sb.append(space); + sb.append(":").append(space); + if (this.getHosts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getHosts(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("zone_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getZone_name() == null) { + sb.append("null"); + } else { + int __zone_name_size = Math.min(this.getZone_name().length, 128); + for (int i = 0; i < __zone_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); + } + if (this.getZone_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("is_new"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIs_new(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddHostsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsReq.java new file mode 100644 index 000000000..44cda48d4 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsReq.java @@ -0,0 +1,286 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class AddHostsReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("AddHostsReq"); + private static final TField HOSTS_FIELD_DESC = new TField("hosts", TType.LIST, (short)1); + + public List hosts; + public static final int HOSTS = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(HOSTS, new FieldMetaData("hosts", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(AddHostsReq.class, metaDataMap); + } + + public AddHostsReq() { + } + + public AddHostsReq( + List hosts) { + this(); + this.hosts = hosts; + } + + public static class Builder { + private List hosts; + + public Builder() { + } + + public Builder setHosts(final List hosts) { + this.hosts = hosts; + return this; + } + + public AddHostsReq build() { + AddHostsReq result = new AddHostsReq(); + result.setHosts(this.hosts); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public AddHostsReq(AddHostsReq other) { + if (other.isSetHosts()) { + this.hosts = TBaseHelper.deepCopy(other.hosts); + } + } + + public AddHostsReq deepCopy() { + return new AddHostsReq(this); + } + + public List getHosts() { + return this.hosts; + } + + public AddHostsReq setHosts(List hosts) { + this.hosts = hosts; + return this; + } + + public void unsetHosts() { + this.hosts = null; + } + + // Returns true if field hosts is set (has been assigned a value) and false otherwise + public boolean isSetHosts() { + return this.hosts != null; + } + + public void setHostsIsSet(boolean __value) { + if (!__value) { + this.hosts = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case HOSTS: + if (__value == null) { + unsetHosts(); + } else { + setHosts((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case HOSTS: + return getHosts(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof AddHostsReq)) + return false; + AddHostsReq that = (AddHostsReq)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetHosts(), that.isSetHosts(), this.hosts, that.hosts)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {hosts}); + } + + @Override + public int compareTo(AddHostsReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetHosts()).compareTo(other.isSetHosts()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(hosts, other.hosts); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case HOSTS: + if (__field.type == TType.LIST) { + { + TList _list94 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list94.size)); + for (int _i95 = 0; + (_list94.size < 0) ? iprot.peekList() : (_i95 < _list94.size); + ++_i95) + { + com.vesoft.nebula.HostAddr _elem96; + _elem96 = new com.vesoft.nebula.HostAddr(); + _elem96.read(iprot); + this.hosts.add(_elem96); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.hosts != null) { + oprot.writeFieldBegin(HOSTS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); + for (com.vesoft.nebula.HostAddr _iter97 : this.hosts) { + _iter97.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("AddHostsReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("hosts"); + sb.append(space); + sb.append(":").append(space); + if (this.getHosts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getHosts(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java index 9a8a5c6ce..4ed5f7422 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java @@ -356,16 +356,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list224 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list224.size)); - for (int _i225 = 0; - (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); - ++_i225) + TList _list240 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list240.size)); + for (int _i241 = 0; + (_list240.size < 0) ? iprot.peekList() : (_i241 < _list240.size); + ++_i241) { - com.vesoft.nebula.HostAddr _elem226; - _elem226 = new com.vesoft.nebula.HostAddr(); - _elem226.read(iprot); - this.hosts.add(_elem226); + com.vesoft.nebula.HostAddr _elem242; + _elem242 = new com.vesoft.nebula.HostAddr(); + _elem242.read(iprot); + this.hosts.add(_elem242); } iprot.readListEnd(); } @@ -402,8 +402,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter227 : this.hosts) { - _iter227.write(oprot); + for (com.vesoft.nebula.HostAddr _iter243 : this.hosts) { + _iter243.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AdminJobReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AdminJobReq.java index 70d8b339a..beed5f2ab 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AdminJobReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AdminJobReq.java @@ -348,15 +348,15 @@ public void read(TProtocol iprot) throws TException { case PARAS: if (__field.type == TType.LIST) { { - TList _list26 = iprot.readListBegin(); - this.paras = new ArrayList(Math.max(0, _list26.size)); - for (int _i27 = 0; - (_list26.size < 0) ? iprot.peekList() : (_i27 < _list26.size); - ++_i27) + TList _list30 = iprot.readListBegin(); + this.paras = new ArrayList(Math.max(0, _list30.size)); + for (int _i31 = 0; + (_list30.size < 0) ? iprot.peekList() : (_i31 < _list30.size); + ++_i31) { - byte[] _elem28; - _elem28 = iprot.readBinary(); - this.paras.add(_elem28); + byte[] _elem32; + _elem32 = iprot.readBinary(); + this.paras.add(_elem32); } iprot.readListEnd(); } @@ -395,8 +395,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARAS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.paras.size())); - for (byte[] _iter29 : this.paras) { - oprot.writeBinary(_iter29); + for (byte[] _iter33 : this.paras) { + oprot.writeBinary(_iter33); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AdminJobResult.java b/client/src/main/generated/com/vesoft/nebula/meta/AdminJobResult.java index c81bef71f..26875bcfe 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AdminJobResult.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AdminJobResult.java @@ -402,16 +402,16 @@ public void read(TProtocol iprot) throws TException { case JOB_DESC: if (__field.type == TType.LIST) { { - TList _list34 = iprot.readListBegin(); - this.job_desc = new ArrayList(Math.max(0, _list34.size)); - for (int _i35 = 0; - (_list34.size < 0) ? iprot.peekList() : (_i35 < _list34.size); - ++_i35) + TList _list38 = iprot.readListBegin(); + this.job_desc = new ArrayList(Math.max(0, _list38.size)); + for (int _i39 = 0; + (_list38.size < 0) ? iprot.peekList() : (_i39 < _list38.size); + ++_i39) { - JobDesc _elem36; - _elem36 = new JobDesc(); - _elem36.read(iprot); - this.job_desc.add(_elem36); + JobDesc _elem40; + _elem40 = new JobDesc(); + _elem40.read(iprot); + this.job_desc.add(_elem40); } iprot.readListEnd(); } @@ -422,16 +422,16 @@ public void read(TProtocol iprot) throws TException { case TASK_DESC: if (__field.type == TType.LIST) { { - TList _list37 = iprot.readListBegin(); - this.task_desc = new ArrayList(Math.max(0, _list37.size)); - for (int _i38 = 0; - (_list37.size < 0) ? iprot.peekList() : (_i38 < _list37.size); - ++_i38) + TList _list41 = iprot.readListBegin(); + this.task_desc = new ArrayList(Math.max(0, _list41.size)); + for (int _i42 = 0; + (_list41.size < 0) ? iprot.peekList() : (_i42 < _list41.size); + ++_i42) { - TaskDesc _elem39; - _elem39 = new TaskDesc(); - _elem39.read(iprot); - this.task_desc.add(_elem39); + TaskDesc _elem43; + _elem43 = new TaskDesc(); + _elem43.read(iprot); + this.task_desc.add(_elem43); } iprot.readListEnd(); } @@ -474,8 +474,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(JOB_DESC_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.job_desc.size())); - for (JobDesc _iter40 : this.job_desc) { - _iter40.write(oprot); + for (JobDesc _iter44 : this.job_desc) { + _iter44.write(oprot); } oprot.writeListEnd(); } @@ -487,8 +487,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TASK_DESC_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.task_desc.size())); - for (TaskDesc _iter41 : this.task_desc) { - _iter41.write(oprot); + for (TaskDesc _iter45 : this.task_desc) { + _iter45.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AlterEdgeReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AlterEdgeReq.java index 0a55d02d5..7adfd4dd9 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AlterEdgeReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AlterEdgeReq.java @@ -406,16 +406,16 @@ public void read(TProtocol iprot) throws TException { case EDGE_ITEMS: if (__field.type == TType.LIST) { { - TList _list82 = iprot.readListBegin(); - this.edge_items = new ArrayList(Math.max(0, _list82.size)); - for (int _i83 = 0; - (_list82.size < 0) ? iprot.peekList() : (_i83 < _list82.size); - ++_i83) + TList _list86 = iprot.readListBegin(); + this.edge_items = new ArrayList(Math.max(0, _list86.size)); + for (int _i87 = 0; + (_list86.size < 0) ? iprot.peekList() : (_i87 < _list86.size); + ++_i87) { - AlterSchemaItem _elem84; - _elem84 = new AlterSchemaItem(); - _elem84.read(iprot); - this.edge_items.add(_elem84); + AlterSchemaItem _elem88; + _elem88 = new AlterSchemaItem(); + _elem88.read(iprot); + this.edge_items.add(_elem88); } iprot.readListEnd(); } @@ -460,8 +460,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGE_ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.edge_items.size())); - for (AlterSchemaItem _iter85 : this.edge_items) { - _iter85.write(oprot); + for (AlterSchemaItem _iter89 : this.edge_items) { + _iter89.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AlterTagReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AlterTagReq.java index 92909df0d..08a0b21bb 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AlterTagReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AlterTagReq.java @@ -406,16 +406,16 @@ public void read(TProtocol iprot) throws TException { case TAG_ITEMS: if (__field.type == TType.LIST) { { - TList _list74 = iprot.readListBegin(); - this.tag_items = new ArrayList(Math.max(0, _list74.size)); - for (int _i75 = 0; - (_list74.size < 0) ? iprot.peekList() : (_i75 < _list74.size); - ++_i75) + TList _list78 = iprot.readListBegin(); + this.tag_items = new ArrayList(Math.max(0, _list78.size)); + for (int _i79 = 0; + (_list78.size < 0) ? iprot.peekList() : (_i79 < _list78.size); + ++_i79) { - AlterSchemaItem _elem76; - _elem76 = new AlterSchemaItem(); - _elem76.read(iprot); - this.tag_items.add(_elem76); + AlterSchemaItem _elem80; + _elem80 = new AlterSchemaItem(); + _elem80.read(iprot); + this.tag_items.add(_elem80); } iprot.readListEnd(); } @@ -460,8 +460,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TAG_ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.tag_items.size())); - for (AlterSchemaItem _iter77 : this.tag_items) { - _iter77.write(oprot); + for (AlterSchemaItem _iter81 : this.tag_items) { + _iter81.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java index e1588ae80..f8387b031 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java @@ -268,16 +268,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list232 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list232.size)); - for (int _i233 = 0; - (_list232.size < 0) ? iprot.peekList() : (_i233 < _list232.size); - ++_i233) + TList _list248 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list248.size)); + for (int _i249 = 0; + (_list248.size < 0) ? iprot.peekList() : (_i249 < _list248.size); + ++_i249) { - com.vesoft.nebula.CheckpointInfo _elem234; - _elem234 = new com.vesoft.nebula.CheckpointInfo(); - _elem234.read(iprot); - this.info.add(_elem234); + com.vesoft.nebula.CheckpointInfo _elem250; + _elem250 = new com.vesoft.nebula.CheckpointInfo(); + _elem250.read(iprot); + this.info.add(_elem250); } iprot.readListEnd(); } @@ -311,8 +311,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter235 : this.info) { - _iter235.write(oprot); + for (com.vesoft.nebula.CheckpointInfo _iter251 : this.info) { + _iter251.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java index 2065c4c59..0ab43acc0 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java @@ -521,18 +521,18 @@ public void read(TProtocol iprot) throws TException { case BACKUP_INFO: if (__field.type == TType.MAP) { { - TMap _map240 = iprot.readMapBegin(); - this.backup_info = new HashMap(Math.max(0, 2*_map240.size)); - for (int _i241 = 0; - (_map240.size < 0) ? iprot.peekMap() : (_i241 < _map240.size); - ++_i241) + TMap _map256 = iprot.readMapBegin(); + this.backup_info = new HashMap(Math.max(0, 2*_map256.size)); + for (int _i257 = 0; + (_map256.size < 0) ? iprot.peekMap() : (_i257 < _map256.size); + ++_i257) { - int _key242; - SpaceBackupInfo _val243; - _key242 = iprot.readI32(); - _val243 = new SpaceBackupInfo(); - _val243.read(iprot); - this.backup_info.put(_key242, _val243); + int _key258; + SpaceBackupInfo _val259; + _key258 = iprot.readI32(); + _val259 = new SpaceBackupInfo(); + _val259.read(iprot); + this.backup_info.put(_key258, _val259); } iprot.readMapEnd(); } @@ -543,15 +543,15 @@ public void read(TProtocol iprot) throws TException { case META_FILES: if (__field.type == TType.LIST) { { - TList _list244 = iprot.readListBegin(); - this.meta_files = new ArrayList(Math.max(0, _list244.size)); - for (int _i245 = 0; - (_list244.size < 0) ? iprot.peekList() : (_i245 < _list244.size); - ++_i245) + TList _list260 = iprot.readListBegin(); + this.meta_files = new ArrayList(Math.max(0, _list260.size)); + for (int _i261 = 0; + (_list260.size < 0) ? iprot.peekList() : (_i261 < _list260.size); + ++_i261) { - byte[] _elem246; - _elem246 = iprot.readBinary(); - this.meta_files.add(_elem246); + byte[] _elem262; + _elem262 = iprot.readBinary(); + this.meta_files.add(_elem262); } iprot.readListEnd(); } @@ -611,9 +611,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(BACKUP_INFO_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.backup_info.size())); - for (Map.Entry _iter247 : this.backup_info.entrySet()) { - oprot.writeI32(_iter247.getKey()); - _iter247.getValue().write(oprot); + for (Map.Entry _iter263 : this.backup_info.entrySet()) { + oprot.writeI32(_iter263.getKey()); + _iter263.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -623,8 +623,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(META_FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.meta_files.size())); - for (byte[] _iter248 : this.meta_files) { - oprot.writeBinary(_iter248); + for (byte[] _iter264 : this.meta_files) { + oprot.writeBinary(_iter264); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java index 86b982e5e..7df101c4d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java @@ -198,15 +198,15 @@ public void read(TProtocol iprot) throws TException { case SPACES: if (__field.type == TType.LIST) { { - TList _list249 = iprot.readListBegin(); - this.spaces = new ArrayList(Math.max(0, _list249.size)); - for (int _i250 = 0; - (_list249.size < 0) ? iprot.peekList() : (_i250 < _list249.size); - ++_i250) + TList _list265 = iprot.readListBegin(); + this.spaces = new ArrayList(Math.max(0, _list265.size)); + for (int _i266 = 0; + (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); + ++_i266) { - byte[] _elem251; - _elem251 = iprot.readBinary(); - this.spaces.add(_elem251); + byte[] _elem267; + _elem267 = iprot.readBinary(); + this.spaces.add(_elem267); } iprot.readListEnd(); } @@ -236,8 +236,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.spaces.size())); - for (byte[] _iter252 : this.spaces) { - oprot.writeBinary(_iter252); + for (byte[] _iter268 : this.spaces) { + oprot.writeBinary(_iter268); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java index ea50efe47..3c72e04db 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java @@ -555,16 +555,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list171 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list171.size)); - for (int _i172 = 0; - (_list171.size < 0) ? iprot.peekList() : (_i172 < _list171.size); - ++_i172) + TList _list183 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list183.size)); + for (int _i184 = 0; + (_list183.size < 0) ? iprot.peekList() : (_i184 < _list183.size); + ++_i184) { - IndexFieldDef _elem173; - _elem173 = new IndexFieldDef(); - _elem173.read(iprot); - this.fields.add(_elem173); + IndexFieldDef _elem185; + _elem185 = new IndexFieldDef(); + _elem185.read(iprot); + this.fields.add(_elem185); } iprot.readListEnd(); } @@ -621,8 +621,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter174 : this.fields) { - _iter174.write(oprot); + for (IndexFieldDef _iter186 : this.fields) { + _iter186.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java index bd1036b54..d60dd1465 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java @@ -555,16 +555,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list163 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list163.size)); - for (int _i164 = 0; - (_list163.size < 0) ? iprot.peekList() : (_i164 < _list163.size); - ++_i164) + TList _list175 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list175.size)); + for (int _i176 = 0; + (_list175.size < 0) ? iprot.peekList() : (_i176 < _list175.size); + ++_i176) { - IndexFieldDef _elem165; - _elem165 = new IndexFieldDef(); - _elem165.read(iprot); - this.fields.add(_elem165); + IndexFieldDef _elem177; + _elem177 = new IndexFieldDef(); + _elem177.read(iprot); + this.fields.add(_elem177); } iprot.readListEnd(); } @@ -621,8 +621,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter166 : this.fields) { - _iter166.write(oprot); + for (IndexFieldDef _iter178 : this.fields) { + _iter178.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/DropHostsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/DropHostsReq.java new file mode 100644 index 000000000..36b2ed69a --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/DropHostsReq.java @@ -0,0 +1,286 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class DropHostsReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("DropHostsReq"); + private static final TField HOSTS_FIELD_DESC = new TField("hosts", TType.LIST, (short)1); + + public List hosts; + public static final int HOSTS = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(HOSTS, new FieldMetaData("hosts", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(DropHostsReq.class, metaDataMap); + } + + public DropHostsReq() { + } + + public DropHostsReq( + List hosts) { + this(); + this.hosts = hosts; + } + + public static class Builder { + private List hosts; + + public Builder() { + } + + public Builder setHosts(final List hosts) { + this.hosts = hosts; + return this; + } + + public DropHostsReq build() { + DropHostsReq result = new DropHostsReq(); + result.setHosts(this.hosts); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public DropHostsReq(DropHostsReq other) { + if (other.isSetHosts()) { + this.hosts = TBaseHelper.deepCopy(other.hosts); + } + } + + public DropHostsReq deepCopy() { + return new DropHostsReq(this); + } + + public List getHosts() { + return this.hosts; + } + + public DropHostsReq setHosts(List hosts) { + this.hosts = hosts; + return this; + } + + public void unsetHosts() { + this.hosts = null; + } + + // Returns true if field hosts is set (has been assigned a value) and false otherwise + public boolean isSetHosts() { + return this.hosts != null; + } + + public void setHostsIsSet(boolean __value) { + if (!__value) { + this.hosts = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case HOSTS: + if (__value == null) { + unsetHosts(); + } else { + setHosts((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case HOSTS: + return getHosts(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof DropHostsReq)) + return false; + DropHostsReq that = (DropHostsReq)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetHosts(), that.isSetHosts(), this.hosts, that.hosts)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {hosts}); + } + + @Override + public int compareTo(DropHostsReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetHosts()).compareTo(other.isSetHosts()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(hosts, other.hosts); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case HOSTS: + if (__field.type == TType.LIST) { + { + TList _list98 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list98.size)); + for (int _i99 = 0; + (_list98.size < 0) ? iprot.peekList() : (_i99 < _list98.size); + ++_i99) + { + com.vesoft.nebula.HostAddr _elem100; + _elem100 = new com.vesoft.nebula.HostAddr(); + _elem100.read(iprot); + this.hosts.add(_elem100); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.hosts != null) { + oprot.writeFieldBegin(HOSTS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); + for (com.vesoft.nebula.HostAddr _iter101 : this.hosts) { + _iter101.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("DropHostsReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("hosts"); + sb.append(space); + sb.append(":").append(space); + if (this.getHosts() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getHosts(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java index 48bb851ca..ebdf0ec4c 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java @@ -345,15 +345,15 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list269 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list269.size)); - for (int _i270 = 0; - (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); - ++_i270) + TList _list285 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list285.size)); + for (int _i286 = 0; + (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); + ++_i286) { - byte[] _elem271; - _elem271 = iprot.readBinary(); - this.fields.add(_elem271); + byte[] _elem287; + _elem287 = iprot.readBinary(); + this.fields.add(_elem287); } iprot.readListEnd(); } @@ -390,8 +390,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.fields.size())); - for (byte[] _iter272 : this.fields) { - oprot.writeBinary(_iter272); + for (byte[] _iter288 : this.fields) { + oprot.writeBinary(_iter288); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java index 356787301..b685c7e55 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list192 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list192.size)); - for (int _i193 = 0; - (_list192.size < 0) ? iprot.peekList() : (_i193 < _list192.size); - ++_i193) + TList _list204 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list204.size)); + for (int _i205 = 0; + (_list204.size < 0) ? iprot.peekList() : (_i205 < _list204.size); + ++_i205) { - ConfigItem _elem194; - _elem194 = new ConfigItem(); - _elem194.read(iprot); - this.items.add(_elem194); + ConfigItem _elem206; + _elem206 = new ConfigItem(); + _elem206.read(iprot); + this.items.add(_elem206); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter195 : this.items) { - _iter195.write(oprot); + for (ConfigItem _iter207 : this.items) { + _iter207.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetPartsAllocResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetPartsAllocResp.java index 836c00dae..cc9d65187 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetPartsAllocResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetPartsAllocResp.java @@ -425,30 +425,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map110 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map110.size)); - for (int _i111 = 0; - (_map110.size < 0) ? iprot.peekMap() : (_i111 < _map110.size); - ++_i111) + TMap _map122 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map122.size)); + for (int _i123 = 0; + (_map122.size < 0) ? iprot.peekMap() : (_i123 < _map122.size); + ++_i123) { - int _key112; - List _val113; - _key112 = iprot.readI32(); + int _key124; + List _val125; + _key124 = iprot.readI32(); { - TList _list114 = iprot.readListBegin(); - _val113 = new ArrayList(Math.max(0, _list114.size)); - for (int _i115 = 0; - (_list114.size < 0) ? iprot.peekList() : (_i115 < _list114.size); - ++_i115) + TList _list126 = iprot.readListBegin(); + _val125 = new ArrayList(Math.max(0, _list126.size)); + for (int _i127 = 0; + (_list126.size < 0) ? iprot.peekList() : (_i127 < _list126.size); + ++_i127) { - com.vesoft.nebula.HostAddr _elem116; - _elem116 = new com.vesoft.nebula.HostAddr(); - _elem116.read(iprot); - _val113.add(_elem116); + com.vesoft.nebula.HostAddr _elem128; + _elem128 = new com.vesoft.nebula.HostAddr(); + _elem128.read(iprot); + _val125.add(_elem128); } iprot.readListEnd(); } - this.parts.put(_key112, _val113); + this.parts.put(_key124, _val125); } iprot.readMapEnd(); } @@ -459,17 +459,17 @@ public void read(TProtocol iprot) throws TException { case TERMS: if (__field.type == TType.MAP) { { - TMap _map117 = iprot.readMapBegin(); - this.terms = new HashMap(Math.max(0, 2*_map117.size)); - for (int _i118 = 0; - (_map117.size < 0) ? iprot.peekMap() : (_i118 < _map117.size); - ++_i118) + TMap _map129 = iprot.readMapBegin(); + this.terms = new HashMap(Math.max(0, 2*_map129.size)); + for (int _i130 = 0; + (_map129.size < 0) ? iprot.peekMap() : (_i130 < _map129.size); + ++_i130) { - int _key119; - long _val120; - _key119 = iprot.readI32(); - _val120 = iprot.readI64(); - this.terms.put(_key119, _val120); + int _key131; + long _val132; + _key131 = iprot.readI32(); + _val132 = iprot.readI64(); + this.terms.put(_key131, _val132); } iprot.readMapEnd(); } @@ -508,12 +508,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter121 : this.parts.entrySet()) { - oprot.writeI32(_iter121.getKey()); + for (Map.Entry> _iter133 : this.parts.entrySet()) { + oprot.writeI32(_iter133.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter121.getValue().size())); - for (com.vesoft.nebula.HostAddr _iter122 : _iter121.getValue()) { - _iter122.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter133.getValue().size())); + for (com.vesoft.nebula.HostAddr _iter134 : _iter133.getValue()) { + _iter134.write(oprot); } oprot.writeListEnd(); } @@ -527,9 +527,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TERMS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.I64, this.terms.size())); - for (Map.Entry _iter123 : this.terms.entrySet()) { - oprot.writeI32(_iter123.getKey()); - oprot.writeI64(_iter123.getValue()); + for (Map.Entry _iter135 : this.terms.entrySet()) { + oprot.writeI32(_iter135.getKey()); + oprot.writeI64(_iter135.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java new file mode 100644 index 000000000..9070aac9b --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java @@ -0,0 +1,267 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetStatisReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetStatisReq"); + private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + + public int space_id; + public static final int SPACE_ID = 1; + + // isset id assignments + private static final int __SPACE_ID_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetStatisReq.class, metaDataMap); + } + + public GetStatisReq() { + } + + public GetStatisReq( + int space_id) { + this(); + this.space_id = space_id; + setSpace_idIsSet(true); + } + + public static class Builder { + private int space_id; + + BitSet __optional_isset = new BitSet(1); + + public Builder() { + } + + public Builder setSpace_id(final int space_id) { + this.space_id = space_id; + __optional_isset.set(__SPACE_ID_ISSET_ID, true); + return this; + } + + public GetStatisReq build() { + GetStatisReq result = new GetStatisReq(); + if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { + result.setSpace_id(this.space_id); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetStatisReq(GetStatisReq other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.space_id = TBaseHelper.deepCopy(other.space_id); + } + + public GetStatisReq deepCopy() { + return new GetStatisReq(this); + } + + public int getSpace_id() { + return this.space_id; + } + + public GetStatisReq setSpace_id(int space_id) { + this.space_id = space_id; + setSpace_idIsSet(true); + return this; + } + + public void unsetSpace_id() { + __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + } + + // Returns true if field space_id is set (has been assigned a value) and false otherwise + public boolean isSetSpace_id() { + return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + } + + public void setSpace_idIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SPACE_ID: + if (__value == null) { + unsetSpace_id(); + } else { + setSpace_id((Integer)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SPACE_ID: + return new Integer(getSpace_id()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetStatisReq)) + return false; + GetStatisReq that = (GetStatisReq)_that; + + if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {space_id}); + } + + @Override + public int compareTo(GetStatisReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SPACE_ID: + if (__field.type == TType.I32) { + this.space_id = iprot.readI32(); + setSpace_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); + oprot.writeI32(this.space_id); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetStatisReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("space_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java new file mode 100644 index 000000000..4a018a286 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java @@ -0,0 +1,457 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetStatisResp implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetStatisResp"); + private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); + private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); + private static final TField STATIS_FIELD_DESC = new TField("statis", TType.STRUCT, (short)3); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode code; + public com.vesoft.nebula.HostAddr leader; + public StatisItem statis; + public static final int CODE = 1; + public static final int LEADER = 2; + public static final int STATIS = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(STATIS, new FieldMetaData("statis", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, StatisItem.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetStatisResp.class, metaDataMap); + } + + public GetStatisResp() { + } + + public GetStatisResp( + com.vesoft.nebula.ErrorCode code, + com.vesoft.nebula.HostAddr leader, + StatisItem statis) { + this(); + this.code = code; + this.leader = leader; + this.statis = statis; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode code; + private com.vesoft.nebula.HostAddr leader; + private StatisItem statis; + + public Builder() { + } + + public Builder setCode(final com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public Builder setStatis(final StatisItem statis) { + this.statis = statis; + return this; + } + + public GetStatisResp build() { + GetStatisResp result = new GetStatisResp(); + result.setCode(this.code); + result.setLeader(this.leader); + result.setStatis(this.statis); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetStatisResp(GetStatisResp other) { + if (other.isSetCode()) { + this.code = TBaseHelper.deepCopy(other.code); + } + if (other.isSetLeader()) { + this.leader = TBaseHelper.deepCopy(other.leader); + } + if (other.isSetStatis()) { + this.statis = TBaseHelper.deepCopy(other.statis); + } + } + + public GetStatisResp deepCopy() { + return new GetStatisResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getCode() { + return this.code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public GetStatisResp setCode(com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public void unsetCode() { + this.code = null; + } + + // Returns true if field code is set (has been assigned a value) and false otherwise + public boolean isSetCode() { + return this.code != null; + } + + public void setCodeIsSet(boolean __value) { + if (!__value) { + this.code = null; + } + } + + public com.vesoft.nebula.HostAddr getLeader() { + return this.leader; + } + + public GetStatisResp setLeader(com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public void unsetLeader() { + this.leader = null; + } + + // Returns true if field leader is set (has been assigned a value) and false otherwise + public boolean isSetLeader() { + return this.leader != null; + } + + public void setLeaderIsSet(boolean __value) { + if (!__value) { + this.leader = null; + } + } + + public StatisItem getStatis() { + return this.statis; + } + + public GetStatisResp setStatis(StatisItem statis) { + this.statis = statis; + return this; + } + + public void unsetStatis() { + this.statis = null; + } + + // Returns true if field statis is set (has been assigned a value) and false otherwise + public boolean isSetStatis() { + return this.statis != null; + } + + public void setStatisIsSet(boolean __value) { + if (!__value) { + this.statis = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CODE: + if (__value == null) { + unsetCode(); + } else { + setCode((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case LEADER: + if (__value == null) { + unsetLeader(); + } else { + setLeader((com.vesoft.nebula.HostAddr)__value); + } + break; + + case STATIS: + if (__value == null) { + unsetStatis(); + } else { + setStatis((StatisItem)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CODE: + return getCode(); + + case LEADER: + return getLeader(); + + case STATIS: + return getStatis(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetStatisResp)) + return false; + GetStatisResp that = (GetStatisResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetStatis(), that.isSetStatis(), this.statis, that.statis)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {code, leader, statis}); + } + + @Override + public int compareTo(GetStatisResp other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCode()).compareTo(other.isSetCode()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(code, other.code); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetLeader()).compareTo(other.isSetLeader()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(leader, other.leader); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStatis()).compareTo(other.isSetStatis()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(statis, other.statis); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CODE: + if (__field.type == TType.I32) { + this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LEADER: + if (__field.type == TType.STRUCT) { + this.leader = new com.vesoft.nebula.HostAddr(); + this.leader.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STATIS: + if (__field.type == TType.STRUCT) { + this.statis = new StatisItem(); + this.statis.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.code != null) { + oprot.writeFieldBegin(CODE_FIELD_DESC); + oprot.writeI32(this.code == null ? 0 : this.code.getValue()); + oprot.writeFieldEnd(); + } + if (this.leader != null) { + oprot.writeFieldBegin(LEADER_FIELD_DESC); + this.leader.write(oprot); + oprot.writeFieldEnd(); + } + if (this.statis != null) { + oprot.writeFieldBegin(STATIS_FIELD_DESC); + this.statis.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetStatisResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("code"); + sb.append(space); + sb.append(":").append(space); + if (this.getCode() == null) { + sb.append("null"); + } else { + String code_name = this.getCode() == null ? "null" : this.getCode().name(); + if (code_name != null) { + sb.append(code_name); + sb.append(" ("); + } + sb.append(this.getCode()); + if (code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("leader"); + sb.append(space); + sb.append(":").append(space); + if (this.getLeader() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("statis"); + sb.append(space); + sb.append(":").append(space); + if (this.getStatis() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getStatis(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java index aacd4b403..3a74cfcd4 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list212 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list212.size)); - for (int _i213 = 0; - (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); - ++_i213) + TList _list228 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list228.size)); + for (int _i229 = 0; + (_list228.size < 0) ? iprot.peekList() : (_i229 < _list228.size); + ++_i229) { - com.vesoft.nebula.HostAddr _elem214; - _elem214 = new com.vesoft.nebula.HostAddr(); - _elem214.read(iprot); - this.hosts.add(_elem214); + com.vesoft.nebula.HostAddr _elem230; + _elem230 = new com.vesoft.nebula.HostAddr(); + _elem230.read(iprot); + this.hosts.add(_elem230); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter215 : this.hosts) { - _iter215.write(oprot); + for (com.vesoft.nebula.HostAddr _iter231 : this.hosts) { + _iter231.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java index 8021c5f19..ea800cae9 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java @@ -569,30 +569,30 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTIDS: if (__field.type == TType.MAP) { { - TMap _map144 = iprot.readMapBegin(); - this.leader_partIds = new HashMap>(Math.max(0, 2*_map144.size)); - for (int _i145 = 0; - (_map144.size < 0) ? iprot.peekMap() : (_i145 < _map144.size); - ++_i145) + TMap _map156 = iprot.readMapBegin(); + this.leader_partIds = new HashMap>(Math.max(0, 2*_map156.size)); + for (int _i157 = 0; + (_map156.size < 0) ? iprot.peekMap() : (_i157 < _map156.size); + ++_i157) { - int _key146; - List _val147; - _key146 = iprot.readI32(); + int _key158; + List _val159; + _key158 = iprot.readI32(); { - TList _list148 = iprot.readListBegin(); - _val147 = new ArrayList(Math.max(0, _list148.size)); - for (int _i149 = 0; - (_list148.size < 0) ? iprot.peekList() : (_i149 < _list148.size); - ++_i149) + TList _list160 = iprot.readListBegin(); + _val159 = new ArrayList(Math.max(0, _list160.size)); + for (int _i161 = 0; + (_list160.size < 0) ? iprot.peekList() : (_i161 < _list160.size); + ++_i161) { - LeaderInfo _elem150; - _elem150 = new LeaderInfo(); - _elem150.read(iprot); - _val147.add(_elem150); + LeaderInfo _elem162; + _elem162 = new LeaderInfo(); + _elem162.read(iprot); + _val159.add(_elem162); } iprot.readListEnd(); } - this.leader_partIds.put(_key146, _val147); + this.leader_partIds.put(_key158, _val159); } iprot.readMapEnd(); } @@ -610,32 +610,32 @@ public void read(TProtocol iprot) throws TException { case DISK_PARTS: if (__field.type == TType.MAP) { { - TMap _map151 = iprot.readMapBegin(); - this.disk_parts = new HashMap>(Math.max(0, 2*_map151.size)); - for (int _i152 = 0; - (_map151.size < 0) ? iprot.peekMap() : (_i152 < _map151.size); - ++_i152) + TMap _map163 = iprot.readMapBegin(); + this.disk_parts = new HashMap>(Math.max(0, 2*_map163.size)); + for (int _i164 = 0; + (_map163.size < 0) ? iprot.peekMap() : (_i164 < _map163.size); + ++_i164) { - int _key153; - Map _val154; - _key153 = iprot.readI32(); + int _key165; + Map _val166; + _key165 = iprot.readI32(); { - TMap _map155 = iprot.readMapBegin(); - _val154 = new HashMap(Math.max(0, 2*_map155.size)); - for (int _i156 = 0; - (_map155.size < 0) ? iprot.peekMap() : (_i156 < _map155.size); - ++_i156) + TMap _map167 = iprot.readMapBegin(); + _val166 = new HashMap(Math.max(0, 2*_map167.size)); + for (int _i168 = 0; + (_map167.size < 0) ? iprot.peekMap() : (_i168 < _map167.size); + ++_i168) { - byte[] _key157; - PartitionList _val158; - _key157 = iprot.readBinary(); - _val158 = new PartitionList(); - _val158.read(iprot); - _val154.put(_key157, _val158); + byte[] _key169; + PartitionList _val170; + _key169 = iprot.readBinary(); + _val170 = new PartitionList(); + _val170.read(iprot); + _val166.put(_key169, _val170); } iprot.readMapEnd(); } - this.disk_parts.put(_key153, _val154); + this.disk_parts.put(_key165, _val166); } iprot.readMapEnd(); } @@ -678,12 +678,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PART_IDS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.leader_partIds.size())); - for (Map.Entry> _iter159 : this.leader_partIds.entrySet()) { - oprot.writeI32(_iter159.getKey()); + for (Map.Entry> _iter171 : this.leader_partIds.entrySet()) { + oprot.writeI32(_iter171.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter159.getValue().size())); - for (LeaderInfo _iter160 : _iter159.getValue()) { - _iter160.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter171.getValue().size())); + for (LeaderInfo _iter172 : _iter171.getValue()) { + _iter172.write(oprot); } oprot.writeListEnd(); } @@ -703,13 +703,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(DISK_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.MAP, this.disk_parts.size())); - for (Map.Entry> _iter161 : this.disk_parts.entrySet()) { - oprot.writeI32(_iter161.getKey()); + for (Map.Entry> _iter173 : this.disk_parts.entrySet()) { + oprot.writeI32(_iter173.getKey()); { - oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, _iter161.getValue().size())); - for (Map.Entry _iter162 : _iter161.getValue().entrySet()) { - oprot.writeBinary(_iter162.getKey()); - _iter162.getValue().write(oprot); + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, _iter173.getValue().size())); + for (Map.Entry _iter174 : _iter173.getValue().entrySet()) { + oprot.writeBinary(_iter174.getKey()); + _iter174.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/HostItem.java b/client/src/main/generated/com/vesoft/nebula/meta/HostItem.java index 792f3f517..1182272b9 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/HostItem.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HostItem.java @@ -680,29 +680,29 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTS: if (__field.type == TType.MAP) { { - TMap _map8 = iprot.readMapBegin(); - this.leader_parts = new HashMap>(Math.max(0, 2*_map8.size)); - for (int _i9 = 0; - (_map8.size < 0) ? iprot.peekMap() : (_i9 < _map8.size); - ++_i9) + TMap _map12 = iprot.readMapBegin(); + this.leader_parts = new HashMap>(Math.max(0, 2*_map12.size)); + for (int _i13 = 0; + (_map12.size < 0) ? iprot.peekMap() : (_i13 < _map12.size); + ++_i13) { - byte[] _key10; - List _val11; - _key10 = iprot.readBinary(); + byte[] _key14; + List _val15; + _key14 = iprot.readBinary(); { - TList _list12 = iprot.readListBegin(); - _val11 = new ArrayList(Math.max(0, _list12.size)); - for (int _i13 = 0; - (_list12.size < 0) ? iprot.peekList() : (_i13 < _list12.size); - ++_i13) + TList _list16 = iprot.readListBegin(); + _val15 = new ArrayList(Math.max(0, _list16.size)); + for (int _i17 = 0; + (_list16.size < 0) ? iprot.peekList() : (_i17 < _list16.size); + ++_i17) { - int _elem14; - _elem14 = iprot.readI32(); - _val11.add(_elem14); + int _elem18; + _elem18 = iprot.readI32(); + _val15.add(_elem18); } iprot.readListEnd(); } - this.leader_parts.put(_key10, _val11); + this.leader_parts.put(_key14, _val15); } iprot.readMapEnd(); } @@ -713,29 +713,29 @@ public void read(TProtocol iprot) throws TException { case ALL_PARTS: if (__field.type == TType.MAP) { { - TMap _map15 = iprot.readMapBegin(); - this.all_parts = new HashMap>(Math.max(0, 2*_map15.size)); - for (int _i16 = 0; - (_map15.size < 0) ? iprot.peekMap() : (_i16 < _map15.size); - ++_i16) + TMap _map19 = iprot.readMapBegin(); + this.all_parts = new HashMap>(Math.max(0, 2*_map19.size)); + for (int _i20 = 0; + (_map19.size < 0) ? iprot.peekMap() : (_i20 < _map19.size); + ++_i20) { - byte[] _key17; - List _val18; - _key17 = iprot.readBinary(); + byte[] _key21; + List _val22; + _key21 = iprot.readBinary(); { - TList _list19 = iprot.readListBegin(); - _val18 = new ArrayList(Math.max(0, _list19.size)); - for (int _i20 = 0; - (_list19.size < 0) ? iprot.peekList() : (_i20 < _list19.size); - ++_i20) + TList _list23 = iprot.readListBegin(); + _val22 = new ArrayList(Math.max(0, _list23.size)); + for (int _i24 = 0; + (_list23.size < 0) ? iprot.peekList() : (_i24 < _list23.size); + ++_i24) { - int _elem21; - _elem21 = iprot.readI32(); - _val18.add(_elem21); + int _elem25; + _elem25 = iprot.readI32(); + _val22.add(_elem25); } iprot.readListEnd(); } - this.all_parts.put(_key17, _val18); + this.all_parts.put(_key21, _val22); } iprot.readMapEnd(); } @@ -802,12 +802,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.LIST, this.leader_parts.size())); - for (Map.Entry> _iter22 : this.leader_parts.entrySet()) { - oprot.writeBinary(_iter22.getKey()); + for (Map.Entry> _iter26 : this.leader_parts.entrySet()) { + oprot.writeBinary(_iter26.getKey()); { - oprot.writeListBegin(new TList(TType.I32, _iter22.getValue().size())); - for (int _iter23 : _iter22.getValue()) { - oprot.writeI32(_iter23); + oprot.writeListBegin(new TList(TType.I32, _iter26.getValue().size())); + for (int _iter27 : _iter26.getValue()) { + oprot.writeI32(_iter27); } oprot.writeListEnd(); } @@ -820,12 +820,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ALL_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.LIST, this.all_parts.size())); - for (Map.Entry> _iter24 : this.all_parts.entrySet()) { - oprot.writeBinary(_iter24.getKey()); + for (Map.Entry> _iter28 : this.all_parts.entrySet()) { + oprot.writeBinary(_iter28.getKey()); { - oprot.writeListBegin(new TList(TType.I32, _iter24.getValue().size())); - for (int _iter25 : _iter24.getValue()) { - oprot.writeI32(_iter25); + oprot.writeListBegin(new TList(TType.I32, _iter28.getValue().size())); + for (int _iter29 : _iter28.getValue()) { + oprot.writeI32(_iter29); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java b/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java index 7646d65f1..20fabbffe 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java @@ -560,16 +560,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list4 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list4.size)); - for (int _i5 = 0; - (_list4.size < 0) ? iprot.peekList() : (_i5 < _list4.size); - ++_i5) + TList _list8 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list8.size)); + for (int _i9 = 0; + (_list8.size < 0) ? iprot.peekList() : (_i9 < _list8.size); + ++_i9) { - ColumnDef _elem6; - _elem6 = new ColumnDef(); - _elem6.read(iprot); - this.fields.add(_elem6); + ColumnDef _elem10; + _elem10 = new ColumnDef(); + _elem10.read(iprot); + this.fields.add(_elem10); } iprot.readListEnd(); } @@ -623,8 +623,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (ColumnDef _iter7 : this.fields) { - _iter7.write(oprot); + for (ColumnDef _iter11 : this.fields) { + _iter11.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java b/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java deleted file mode 100644 index 6b68dd756..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java +++ /dev/null @@ -1,454 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class IndexParams implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("IndexParams"); - private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)1); - private static final TField S2_MAX_LEVEL_FIELD_DESC = new TField("s2_max_level", TType.I32, (short)2); - private static final TField S2_MAX_CELLS_FIELD_DESC = new TField("s2_max_cells", TType.I32, (short)3); - - public byte[] comment; - public int s2_max_level; - public int s2_max_cells; - public static final int COMMENT = 1; - public static final int S2_MAX_LEVEL = 2; - public static final int S2_MAX_CELLS = 3; - - // isset id assignments - private static final int __S2_MAX_LEVEL_ISSET_ID = 0; - private static final int __S2_MAX_CELLS_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(S2_MAX_LEVEL, new FieldMetaData("s2_max_level", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(S2_MAX_CELLS, new FieldMetaData("s2_max_cells", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.I32))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(IndexParams.class, metaDataMap); - } - - public IndexParams() { - } - - public IndexParams( - byte[] comment, - int s2_max_level, - int s2_max_cells) { - this(); - this.comment = comment; - this.s2_max_level = s2_max_level; - setS2_max_levelIsSet(true); - this.s2_max_cells = s2_max_cells; - setS2_max_cellsIsSet(true); - } - - public static class Builder { - private byte[] comment; - private int s2_max_level; - private int s2_max_cells; - - BitSet __optional_isset = new BitSet(2); - - public Builder() { - } - - public Builder setComment(final byte[] comment) { - this.comment = comment; - return this; - } - - public Builder setS2_max_level(final int s2_max_level) { - this.s2_max_level = s2_max_level; - __optional_isset.set(__S2_MAX_LEVEL_ISSET_ID, true); - return this; - } - - public Builder setS2_max_cells(final int s2_max_cells) { - this.s2_max_cells = s2_max_cells; - __optional_isset.set(__S2_MAX_CELLS_ISSET_ID, true); - return this; - } - - public IndexParams build() { - IndexParams result = new IndexParams(); - result.setComment(this.comment); - if (__optional_isset.get(__S2_MAX_LEVEL_ISSET_ID)) { - result.setS2_max_level(this.s2_max_level); - } - if (__optional_isset.get(__S2_MAX_CELLS_ISSET_ID)) { - result.setS2_max_cells(this.s2_max_cells); - } - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public IndexParams(IndexParams other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - if (other.isSetComment()) { - this.comment = TBaseHelper.deepCopy(other.comment); - } - this.s2_max_level = TBaseHelper.deepCopy(other.s2_max_level); - this.s2_max_cells = TBaseHelper.deepCopy(other.s2_max_cells); - } - - public IndexParams deepCopy() { - return new IndexParams(this); - } - - public byte[] getComment() { - return this.comment; - } - - public IndexParams setComment(byte[] comment) { - this.comment = comment; - return this; - } - - public void unsetComment() { - this.comment = null; - } - - // Returns true if field comment is set (has been assigned a value) and false otherwise - public boolean isSetComment() { - return this.comment != null; - } - - public void setCommentIsSet(boolean __value) { - if (!__value) { - this.comment = null; - } - } - - public int getS2_max_level() { - return this.s2_max_level; - } - - public IndexParams setS2_max_level(int s2_max_level) { - this.s2_max_level = s2_max_level; - setS2_max_levelIsSet(true); - return this; - } - - public void unsetS2_max_level() { - __isset_bit_vector.clear(__S2_MAX_LEVEL_ISSET_ID); - } - - // Returns true if field s2_max_level is set (has been assigned a value) and false otherwise - public boolean isSetS2_max_level() { - return __isset_bit_vector.get(__S2_MAX_LEVEL_ISSET_ID); - } - - public void setS2_max_levelIsSet(boolean __value) { - __isset_bit_vector.set(__S2_MAX_LEVEL_ISSET_ID, __value); - } - - public int getS2_max_cells() { - return this.s2_max_cells; - } - - public IndexParams setS2_max_cells(int s2_max_cells) { - this.s2_max_cells = s2_max_cells; - setS2_max_cellsIsSet(true); - return this; - } - - public void unsetS2_max_cells() { - __isset_bit_vector.clear(__S2_MAX_CELLS_ISSET_ID); - } - - // Returns true if field s2_max_cells is set (has been assigned a value) and false otherwise - public boolean isSetS2_max_cells() { - return __isset_bit_vector.get(__S2_MAX_CELLS_ISSET_ID); - } - - public void setS2_max_cellsIsSet(boolean __value) { - __isset_bit_vector.set(__S2_MAX_CELLS_ISSET_ID, __value); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case COMMENT: - if (__value == null) { - unsetComment(); - } else { - setComment((byte[])__value); - } - break; - - case S2_MAX_LEVEL: - if (__value == null) { - unsetS2_max_level(); - } else { - setS2_max_level((Integer)__value); - } - break; - - case S2_MAX_CELLS: - if (__value == null) { - unsetS2_max_cells(); - } else { - setS2_max_cells((Integer)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case COMMENT: - return getComment(); - - case S2_MAX_LEVEL: - return new Integer(getS2_max_level()); - - case S2_MAX_CELLS: - return new Integer(getS2_max_cells()); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof IndexParams)) - return false; - IndexParams that = (IndexParams)_that; - - if (!TBaseHelper.equalsSlow(this.isSetComment(), that.isSetComment(), this.comment, that.comment)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetS2_max_level(), that.isSetS2_max_level(), this.s2_max_level, that.s2_max_level)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetS2_max_cells(), that.isSetS2_max_cells(), this.s2_max_cells, that.s2_max_cells)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {comment, s2_max_level, s2_max_cells}); - } - - @Override - public int compareTo(IndexParams other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetComment()).compareTo(other.isSetComment()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(comment, other.comment); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetS2_max_level()).compareTo(other.isSetS2_max_level()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(s2_max_level, other.s2_max_level); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetS2_max_cells()).compareTo(other.isSetS2_max_cells()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(s2_max_cells, other.s2_max_cells); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case COMMENT: - if (__field.type == TType.STRING) { - this.comment = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case S2_MAX_LEVEL: - if (__field.type == TType.I32) { - this.s2_max_level = iprot.readI32(); - setS2_max_levelIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case S2_MAX_CELLS: - if (__field.type == TType.I32) { - this.s2_max_cells = iprot.readI32(); - setS2_max_cellsIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.comment != null) { - if (isSetComment()) { - oprot.writeFieldBegin(COMMENT_FIELD_DESC); - oprot.writeBinary(this.comment); - oprot.writeFieldEnd(); - } - } - if (isSetS2_max_level()) { - oprot.writeFieldBegin(S2_MAX_LEVEL_FIELD_DESC); - oprot.writeI32(this.s2_max_level); - oprot.writeFieldEnd(); - } - if (isSetS2_max_cells()) { - oprot.writeFieldBegin(S2_MAX_CELLS_FIELD_DESC); - oprot.writeI32(this.s2_max_cells); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("IndexParams"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - if (isSetComment()) - { - sb.append(indentStr); - sb.append("comment"); - sb.append(space); - sb.append(":").append(space); - if (this.getComment() == null) { - sb.append("null"); - } else { - int __comment_size = Math.min(this.getComment().length, 128); - for (int i = 0; i < __comment_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getComment()[i]).length() > 1 ? Integer.toHexString(this.getComment()[i]).substring(Integer.toHexString(this.getComment()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getComment()[i]).toUpperCase()); - } - if (this.getComment().length > 128) sb.append(" ..."); - } - first = false; - } - if (isSetS2_max_level()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("s2_max_level"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getS2_max_level(), indent + 1, prettyPrint)); - first = false; - } - if (isSetS2_max_cells()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("s2_max_cells"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getS2_max_cells(), indent + 1, prettyPrint)); - first = false; - } - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/JobDesc.java b/client/src/main/generated/com/vesoft/nebula/meta/JobDesc.java index f19a17891..084392155 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/JobDesc.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/JobDesc.java @@ -558,15 +558,15 @@ public void read(TProtocol iprot) throws TException { case PARAS: if (__field.type == TType.LIST) { { - TList _list30 = iprot.readListBegin(); - this.paras = new ArrayList(Math.max(0, _list30.size)); - for (int _i31 = 0; - (_list30.size < 0) ? iprot.peekList() : (_i31 < _list30.size); - ++_i31) + TList _list34 = iprot.readListBegin(); + this.paras = new ArrayList(Math.max(0, _list34.size)); + for (int _i35 = 0; + (_list34.size < 0) ? iprot.peekList() : (_i35 < _list34.size); + ++_i35) { - String _elem32; - _elem32 = iprot.readString(); - this.paras.add(_elem32); + String _elem36; + _elem36 = iprot.readString(); + this.paras.add(_elem36); } iprot.readListEnd(); } @@ -626,8 +626,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARAS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.paras.size())); - for (String _iter33 : this.paras) { - oprot.writeString(_iter33); + for (String _iter37 : this.paras) { + oprot.writeString(_iter37); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java index 5b9b80d2e..ebdd259a9 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java @@ -200,29 +200,29 @@ public void read(TProtocol iprot) throws TException { case KILL_QUERIES: if (__field.type == TType.MAP) { { - TMap _map306 = iprot.readMapBegin(); - this.kill_queries = new HashMap>(Math.max(0, 2*_map306.size)); - for (int _i307 = 0; - (_map306.size < 0) ? iprot.peekMap() : (_i307 < _map306.size); - ++_i307) + TMap _map322 = iprot.readMapBegin(); + this.kill_queries = new HashMap>(Math.max(0, 2*_map322.size)); + for (int _i323 = 0; + (_map322.size < 0) ? iprot.peekMap() : (_i323 < _map322.size); + ++_i323) { - long _key308; - Set _val309; - _key308 = iprot.readI64(); + long _key324; + Set _val325; + _key324 = iprot.readI64(); { - TSet _set310 = iprot.readSetBegin(); - _val309 = new HashSet(Math.max(0, 2*_set310.size)); - for (int _i311 = 0; - (_set310.size < 0) ? iprot.peekSet() : (_i311 < _set310.size); - ++_i311) + TSet _set326 = iprot.readSetBegin(); + _val325 = new HashSet(Math.max(0, 2*_set326.size)); + for (int _i327 = 0; + (_set326.size < 0) ? iprot.peekSet() : (_i327 < _set326.size); + ++_i327) { - long _elem312; - _elem312 = iprot.readI64(); - _val309.add(_elem312); + long _elem328; + _elem328 = iprot.readI64(); + _val325.add(_elem328); } iprot.readSetEnd(); } - this.kill_queries.put(_key308, _val309); + this.kill_queries.put(_key324, _val325); } iprot.readMapEnd(); } @@ -251,12 +251,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILL_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.SET, this.kill_queries.size())); - for (Map.Entry> _iter313 : this.kill_queries.entrySet()) { - oprot.writeI64(_iter313.getKey()); + for (Map.Entry> _iter329 : this.kill_queries.entrySet()) { + oprot.writeI64(_iter329.getKey()); { - oprot.writeSetBegin(new TSet(TType.I64, _iter313.getValue().size())); - for (long _iter314 : _iter313.getValue()) { - oprot.writeI64(_iter314); + oprot.writeSetBegin(new TSet(TType.I64, _iter329.getValue().size())); + for (long _iter330 : _iter329.getValue()) { + oprot.writeI64(_iter330); } oprot.writeSetEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java new file mode 100644 index 000000000..dae1437e8 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java @@ -0,0 +1,174 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListAllSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsReq"); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListAllSessionsReq.class, metaDataMap); + } + + public ListAllSessionsReq() { + } + + public static class Builder { + + public Builder() { + } + + public ListAllSessionsReq build() { + ListAllSessionsReq result = new ListAllSessionsReq(); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListAllSessionsReq(ListAllSessionsReq other) { + } + + public ListAllSessionsReq deepCopy() { + return new ListAllSessionsReq(this); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListAllSessionsReq)) + return false; + ListAllSessionsReq that = (ListAllSessionsReq)_that; + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {}); + } + + @Override + public int compareTo(ListAllSessionsReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListAllSessionsReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java new file mode 100644 index 000000000..53c5a5115 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java @@ -0,0 +1,438 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class ListAllSessionsResp implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsResp"); + private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); + private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); + private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)3); + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode code; + public com.vesoft.nebula.HostAddr leader; + public List sessions; + public static final int CODE = 1; + public static final int LEADER = 2; + public static final int SESSIONS = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Session.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(ListAllSessionsResp.class, metaDataMap); + } + + public ListAllSessionsResp() { + } + + public ListAllSessionsResp( + com.vesoft.nebula.ErrorCode code, + com.vesoft.nebula.HostAddr leader, + List sessions) { + this(); + this.code = code; + this.leader = leader; + this.sessions = sessions; + } + + public static class Builder { + private com.vesoft.nebula.ErrorCode code; + private com.vesoft.nebula.HostAddr leader; + private List sessions; + + public Builder() { + } + + public Builder setCode(final com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public Builder setSessions(final List sessions) { + this.sessions = sessions; + return this; + } + + public ListAllSessionsResp build() { + ListAllSessionsResp result = new ListAllSessionsResp(); + result.setCode(this.code); + result.setLeader(this.leader); + result.setSessions(this.sessions); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public ListAllSessionsResp(ListAllSessionsResp other) { + if (other.isSetCode()) { + this.code = TBaseHelper.deepCopy(other.code); + } + if (other.isSetLeader()) { + this.leader = TBaseHelper.deepCopy(other.leader); + } + if (other.isSetSessions()) { + this.sessions = TBaseHelper.deepCopy(other.sessions); + } + } + + public ListAllSessionsResp deepCopy() { + return new ListAllSessionsResp(this); + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public com.vesoft.nebula.ErrorCode getCode() { + return this.code; + } + + /** + * + * @see com.vesoft.nebula.ErrorCode + */ + public ListAllSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { + this.code = code; + return this; + } + + public void unsetCode() { + this.code = null; + } + + // Returns true if field code is set (has been assigned a value) and false otherwise + public boolean isSetCode() { + return this.code != null; + } + + public void setCodeIsSet(boolean __value) { + if (!__value) { + this.code = null; + } + } + + public com.vesoft.nebula.HostAddr getLeader() { + return this.leader; + } + + public ListAllSessionsResp setLeader(com.vesoft.nebula.HostAddr leader) { + this.leader = leader; + return this; + } + + public void unsetLeader() { + this.leader = null; + } + + // Returns true if field leader is set (has been assigned a value) and false otherwise + public boolean isSetLeader() { + return this.leader != null; + } + + public void setLeaderIsSet(boolean __value) { + if (!__value) { + this.leader = null; + } + } + + public List getSessions() { + return this.sessions; + } + + public ListAllSessionsResp setSessions(List sessions) { + this.sessions = sessions; + return this; + } + + public void unsetSessions() { + this.sessions = null; + } + + // Returns true if field sessions is set (has been assigned a value) and false otherwise + public boolean isSetSessions() { + return this.sessions != null; + } + + public void setSessionsIsSet(boolean __value) { + if (!__value) { + this.sessions = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CODE: + if (__value == null) { + unsetCode(); + } else { + setCode((com.vesoft.nebula.ErrorCode)__value); + } + break; + + case LEADER: + if (__value == null) { + unsetLeader(); + } else { + setLeader((com.vesoft.nebula.HostAddr)__value); + } + break; + + case SESSIONS: + if (__value == null) { + unsetSessions(); + } else { + setSessions((List)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CODE: + return getCode(); + + case LEADER: + return getLeader(); + + case SESSIONS: + return getSessions(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof ListAllSessionsResp)) + return false; + ListAllSessionsResp that = (ListAllSessionsResp)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {code, leader, sessions}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CODE: + if (__field.type == TType.I32) { + this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case LEADER: + if (__field.type == TType.STRUCT) { + this.leader = new com.vesoft.nebula.HostAddr(); + this.leader.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SESSIONS: + if (__field.type == TType.LIST) { + { + TList _list308 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list308.size)); + for (int _i309 = 0; + (_list308.size < 0) ? iprot.peekList() : (_i309 < _list308.size); + ++_i309) + { + Session _elem310; + _elem310 = new Session(); + _elem310.read(iprot); + this.sessions.add(_elem310); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.code != null) { + oprot.writeFieldBegin(CODE_FIELD_DESC); + oprot.writeI32(this.code == null ? 0 : this.code.getValue()); + oprot.writeFieldEnd(); + } + if (this.leader != null) { + oprot.writeFieldBegin(LEADER_FIELD_DESC); + this.leader.write(oprot); + oprot.writeFieldEnd(); + } + if (this.sessions != null) { + oprot.writeFieldBegin(SESSIONS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); + for (Session _iter311 : this.sessions) { + _iter311.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("ListAllSessionsResp"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("code"); + sb.append(space); + sb.append(":").append(space); + if (this.getCode() == null) { + sb.append("null"); + } else { + String code_name = this.getCode() == null ? "null" : this.getCode().name(); + if (code_name != null) { + sb.append(code_name); + sb.append(" ("); + } + sb.append(this.getCode()); + if (code_name != null) { + sb.append(")"); + } + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("leader"); + sb.append(space); + sb.append(":").append(space); + if (this.getLeader() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("sessions"); + sb.append(space); + sb.append(":").append(space); + if (this.getSessions() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java index 0692221f0..a8c99667b 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java @@ -412,16 +412,16 @@ public void read(TProtocol iprot) throws TException { case META_SERVERS: if (__field.type == TType.LIST) { { - TList _list315 = iprot.readListBegin(); - this.meta_servers = new ArrayList(Math.max(0, _list315.size)); - for (int _i316 = 0; - (_list315.size < 0) ? iprot.peekList() : (_i316 < _list315.size); - ++_i316) + TList _list331 = iprot.readListBegin(); + this.meta_servers = new ArrayList(Math.max(0, _list331.size)); + for (int _i332 = 0; + (_list331.size < 0) ? iprot.peekList() : (_i332 < _list331.size); + ++_i332) { - com.vesoft.nebula.HostAddr _elem317; - _elem317 = new com.vesoft.nebula.HostAddr(); - _elem317.read(iprot); - this.meta_servers.add(_elem317); + com.vesoft.nebula.HostAddr _elem333; + _elem333 = new com.vesoft.nebula.HostAddr(); + _elem333.read(iprot); + this.meta_servers.add(_elem333); } iprot.readListEnd(); } @@ -432,16 +432,16 @@ public void read(TProtocol iprot) throws TException { case STORAGE_SERVERS: if (__field.type == TType.LIST) { { - TList _list318 = iprot.readListBegin(); - this.storage_servers = new ArrayList(Math.max(0, _list318.size)); - for (int _i319 = 0; - (_list318.size < 0) ? iprot.peekList() : (_i319 < _list318.size); - ++_i319) + TList _list334 = iprot.readListBegin(); + this.storage_servers = new ArrayList(Math.max(0, _list334.size)); + for (int _i335 = 0; + (_list334.size < 0) ? iprot.peekList() : (_i335 < _list334.size); + ++_i335) { - com.vesoft.nebula.NodeInfo _elem320; - _elem320 = new com.vesoft.nebula.NodeInfo(); - _elem320.read(iprot); - this.storage_servers.add(_elem320); + com.vesoft.nebula.NodeInfo _elem336; + _elem336 = new com.vesoft.nebula.NodeInfo(); + _elem336.read(iprot); + this.storage_servers.add(_elem336); } iprot.readListEnd(); } @@ -480,8 +480,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(META_SERVERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.meta_servers.size())); - for (com.vesoft.nebula.HostAddr _iter321 : this.meta_servers) { - _iter321.write(oprot); + for (com.vesoft.nebula.HostAddr _iter337 : this.meta_servers) { + _iter337.write(oprot); } oprot.writeListEnd(); } @@ -491,8 +491,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STORAGE_SERVERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.storage_servers.size())); - for (com.vesoft.nebula.NodeInfo _iter322 : this.storage_servers) { - _iter322.write(oprot); + for (com.vesoft.nebula.NodeInfo _iter338 : this.storage_servers) { + _iter338.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java index 38451aca5..48d8ce763 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list196 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list196.size)); - for (int _i197 = 0; - (_list196.size < 0) ? iprot.peekList() : (_i197 < _list196.size); - ++_i197) + TList _list208 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list208.size)); + for (int _i209 = 0; + (_list208.size < 0) ? iprot.peekList() : (_i209 < _list208.size); + ++_i209) { - ConfigItem _elem198; - _elem198 = new ConfigItem(); - _elem198.read(iprot); - this.items.add(_elem198); + ConfigItem _elem210; + _elem210 = new ConfigItem(); + _elem210.read(iprot); + this.items.add(_elem210); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter199 : this.items) { - _iter199.write(oprot); + for (ConfigItem _iter211 : this.items) { + _iter211.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java index 7f434d14a..ce7ed97b4 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list175 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list175.size)); - for (int _i176 = 0; - (_list175.size < 0) ? iprot.peekList() : (_i176 < _list175.size); - ++_i176) + TList _list187 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list187.size)); + for (int _i188 = 0; + (_list187.size < 0) ? iprot.peekList() : (_i188 < _list187.size); + ++_i188) { - IndexItem _elem177; - _elem177 = new IndexItem(); - _elem177.read(iprot); - this.items.add(_elem177); + IndexItem _elem189; + _elem189 = new IndexItem(); + _elem189.read(iprot); + this.items.add(_elem189); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter178 : this.items) { - _iter178.write(oprot); + for (IndexItem _iter190 : this.items) { + _iter190.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgesResp.java index 9bc2d16cc..9fb7fee6e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case EDGES: if (__field.type == TType.LIST) { { - TList _list86 = iprot.readListBegin(); - this.edges = new ArrayList(Math.max(0, _list86.size)); - for (int _i87 = 0; - (_list86.size < 0) ? iprot.peekList() : (_i87 < _list86.size); - ++_i87) + TList _list90 = iprot.readListBegin(); + this.edges = new ArrayList(Math.max(0, _list90.size)); + for (int _i91 = 0; + (_list90.size < 0) ? iprot.peekList() : (_i91 < _list90.size); + ++_i91) { - EdgeItem _elem88; - _elem88 = new EdgeItem(); - _elem88.read(iprot); - this.edges.add(_elem88); + EdgeItem _elem92; + _elem92 = new EdgeItem(); + _elem92.read(iprot); + this.edges.add(_elem92); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.edges.size())); - for (EdgeItem _iter89 : this.edges) { - _iter89.write(oprot); + for (EdgeItem _iter93 : this.edges) { + _iter93.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java index 3f87699e1..292c9609f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list265 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list265.size)); - for (int _i266 = 0; - (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); - ++_i266) + TList _list281 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list281.size)); + for (int _i282 = 0; + (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); + ++_i282) { - FTClient _elem267; - _elem267 = new FTClient(); - _elem267.read(iprot); - this.clients.add(_elem267); + FTClient _elem283; + _elem283 = new FTClient(); + _elem283.read(iprot); + this.clients.add(_elem283); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter268 : this.clients) { - _iter268.write(oprot); + for (FTClient _iter284 : this.clients) { + _iter284.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java index 4d4bfa55e..5cc6ec2e7 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java @@ -350,18 +350,18 @@ public void read(TProtocol iprot) throws TException { case INDEXES: if (__field.type == TType.MAP) { { - TMap _map273 = iprot.readMapBegin(); - this.indexes = new HashMap(Math.max(0, 2*_map273.size)); - for (int _i274 = 0; - (_map273.size < 0) ? iprot.peekMap() : (_i274 < _map273.size); - ++_i274) + TMap _map289 = iprot.readMapBegin(); + this.indexes = new HashMap(Math.max(0, 2*_map289.size)); + for (int _i290 = 0; + (_map289.size < 0) ? iprot.peekMap() : (_i290 < _map289.size); + ++_i290) { - byte[] _key275; - FTIndex _val276; - _key275 = iprot.readBinary(); - _val276 = new FTIndex(); - _val276.read(iprot); - this.indexes.put(_key275, _val276); + byte[] _key291; + FTIndex _val292; + _key291 = iprot.readBinary(); + _val292 = new FTIndex(); + _val292.read(iprot); + this.indexes.put(_key291, _val292); } iprot.readMapEnd(); } @@ -400,9 +400,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INDEXES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.indexes.size())); - for (Map.Entry _iter277 : this.indexes.entrySet()) { - oprot.writeBinary(_iter277.getKey()); - _iter277.getValue().write(oprot); + for (Map.Entry _iter293 : this.indexes.entrySet()) { + oprot.writeBinary(_iter293.getKey()); + _iter293.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListHostsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListHostsResp.java index 6b6d4951e..2724696a7 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListHostsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListHostsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list90 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list90.size)); - for (int _i91 = 0; - (_list90.size < 0) ? iprot.peekList() : (_i91 < _list90.size); - ++_i91) + TList _list102 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list102.size)); + for (int _i103 = 0; + (_list102.size < 0) ? iprot.peekList() : (_i103 < _list102.size); + ++_i103) { - HostItem _elem92; - _elem92 = new HostItem(); - _elem92.read(iprot); - this.hosts.add(_elem92); + HostItem _elem104; + _elem104 = new HostItem(); + _elem104.read(iprot); + this.hosts.add(_elem104); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (HostItem _iter93 : this.hosts) { - _iter93.write(oprot); + for (HostItem _iter105 : this.hosts) { + _iter105.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java index cc30b3476..200baa313 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case STATUSES: if (__field.type == TType.LIST) { { - TList _list204 = iprot.readListBegin(); - this.statuses = new ArrayList(Math.max(0, _list204.size)); - for (int _i205 = 0; - (_list204.size < 0) ? iprot.peekList() : (_i205 < _list204.size); - ++_i205) + TList _list216 = iprot.readListBegin(); + this.statuses = new ArrayList(Math.max(0, _list216.size)); + for (int _i217 = 0; + (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); + ++_i217) { - IndexStatus _elem206; - _elem206 = new IndexStatus(); - _elem206.read(iprot); - this.statuses.add(_elem206); + IndexStatus _elem218; + _elem218 = new IndexStatus(); + _elem218.read(iprot); + this.statuses.add(_elem218); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STATUSES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.statuses.size())); - for (IndexStatus _iter207 : this.statuses) { - _iter207.write(oprot); + for (IndexStatus _iter219 : this.statuses) { + _iter219.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java index 4c9359e4e..8aaacf82c 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case LISTENERS: if (__field.type == TType.LIST) { { - TList _list228 = iprot.readListBegin(); - this.listeners = new ArrayList(Math.max(0, _list228.size)); - for (int _i229 = 0; - (_list228.size < 0) ? iprot.peekList() : (_i229 < _list228.size); - ++_i229) + TList _list244 = iprot.readListBegin(); + this.listeners = new ArrayList(Math.max(0, _list244.size)); + for (int _i245 = 0; + (_list244.size < 0) ? iprot.peekList() : (_i245 < _list244.size); + ++_i245) { - ListenerInfo _elem230; - _elem230 = new ListenerInfo(); - _elem230.read(iprot); - this.listeners.add(_elem230); + ListenerInfo _elem246; + _elem246 = new ListenerInfo(); + _elem246.read(iprot); + this.listeners.add(_elem246); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LISTENERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.listeners.size())); - for (ListenerInfo _iter231 : this.listeners) { - _iter231.write(oprot); + for (ListenerInfo _iter247 : this.listeners) { + _iter247.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListPartsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/ListPartsReq.java index ee82647a8..9c6e07215 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListPartsReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListPartsReq.java @@ -275,15 +275,15 @@ public void read(TProtocol iprot) throws TException { case PART_IDS: if (__field.type == TType.LIST) { { - TList _list102 = iprot.readListBegin(); - this.part_ids = new ArrayList(Math.max(0, _list102.size)); - for (int _i103 = 0; - (_list102.size < 0) ? iprot.peekList() : (_i103 < _list102.size); - ++_i103) + TList _list114 = iprot.readListBegin(); + this.part_ids = new ArrayList(Math.max(0, _list114.size)); + for (int _i115 = 0; + (_list114.size < 0) ? iprot.peekList() : (_i115 < _list114.size); + ++_i115) { - int _elem104; - _elem104 = iprot.readI32(); - this.part_ids.add(_elem104); + int _elem116; + _elem116 = iprot.readI32(); + this.part_ids.add(_elem116); } iprot.readListEnd(); } @@ -315,8 +315,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PART_IDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.part_ids.size())); - for (int _iter105 : this.part_ids) { - oprot.writeI32(_iter105); + for (int _iter117 : this.part_ids) { + oprot.writeI32(_iter117); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListPartsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListPartsResp.java index 015f3b935..758c6f9a0 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListPartsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListPartsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list106 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list106.size)); - for (int _i107 = 0; - (_list106.size < 0) ? iprot.peekList() : (_i107 < _list106.size); - ++_i107) + TList _list118 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list118.size)); + for (int _i119 = 0; + (_list118.size < 0) ? iprot.peekList() : (_i119 < _list118.size); + ++_i119) { - PartItem _elem108; - _elem108 = new PartItem(); - _elem108.read(iprot); - this.parts.add(_elem108); + PartItem _elem120; + _elem120 = new PartItem(); + _elem120.read(iprot); + this.parts.add(_elem120); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.parts.size())); - for (PartItem _iter109 : this.parts) { - _iter109.write(oprot); + for (PartItem _iter121 : this.parts) { + _iter121.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java index ea478aeef..537b0b495 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ROLES: if (__field.type == TType.LIST) { { - TList _list184 = iprot.readListBegin(); - this.roles = new ArrayList(Math.max(0, _list184.size)); - for (int _i185 = 0; - (_list184.size < 0) ? iprot.peekList() : (_i185 < _list184.size); - ++_i185) + TList _list196 = iprot.readListBegin(); + this.roles = new ArrayList(Math.max(0, _list196.size)); + for (int _i197 = 0; + (_list196.size < 0) ? iprot.peekList() : (_i197 < _list196.size); + ++_i197) { - RoleItem _elem186; - _elem186 = new RoleItem(); - _elem186.read(iprot); - this.roles.add(_elem186); + RoleItem _elem198; + _elem198 = new RoleItem(); + _elem198.read(iprot); + this.roles.add(_elem198); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ROLES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.roles.size())); - for (RoleItem _iter187 : this.roles) { - _iter187.write(oprot); + for (RoleItem _iter199 : this.roles) { + _iter199.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java index 7e67870a3..28163db3a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list302 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list302.size)); - for (int _i303 = 0; - (_list302.size < 0) ? iprot.peekList() : (_i303 < _list302.size); - ++_i303) + TList _list318 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list318.size)); + for (int _i319 = 0; + (_list318.size < 0) ? iprot.peekList() : (_i319 < _list318.size); + ++_i319) { - Session _elem304; - _elem304 = new Session(); - _elem304.read(iprot); - this.sessions.add(_elem304); + Session _elem320; + _elem320 = new Session(); + _elem320.read(iprot); + this.sessions.add(_elem320); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter305 : this.sessions) { - _iter305.write(oprot); + for (Session _iter321 : this.sessions) { + _iter321.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java index 278492ed5..c409ba5d3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case SNAPSHOTS: if (__field.type == TType.LIST) { { - TList _list200 = iprot.readListBegin(); - this.snapshots = new ArrayList(Math.max(0, _list200.size)); - for (int _i201 = 0; - (_list200.size < 0) ? iprot.peekList() : (_i201 < _list200.size); - ++_i201) + TList _list212 = iprot.readListBegin(); + this.snapshots = new ArrayList(Math.max(0, _list212.size)); + for (int _i213 = 0; + (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); + ++_i213) { - Snapshot _elem202; - _elem202 = new Snapshot(); - _elem202.read(iprot); - this.snapshots.add(_elem202); + Snapshot _elem214; + _elem214 = new Snapshot(); + _elem214.read(iprot); + this.snapshots.add(_elem214); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SNAPSHOTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.snapshots.size())); - for (Snapshot _iter203 : this.snapshots) { - _iter203.write(oprot); + for (Snapshot _iter215 : this.snapshots) { + _iter215.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSpacesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSpacesResp.java index ffaafce34..268e89f7d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSpacesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSpacesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case SPACES: if (__field.type == TType.LIST) { { - TList _list70 = iprot.readListBegin(); - this.spaces = new ArrayList(Math.max(0, _list70.size)); - for (int _i71 = 0; - (_list70.size < 0) ? iprot.peekList() : (_i71 < _list70.size); - ++_i71) + TList _list74 = iprot.readListBegin(); + this.spaces = new ArrayList(Math.max(0, _list74.size)); + for (int _i75 = 0; + (_list74.size < 0) ? iprot.peekList() : (_i75 < _list74.size); + ++_i75) { - IdName _elem72; - _elem72 = new IdName(); - _elem72.read(iprot); - this.spaces.add(_elem72); + IdName _elem76; + _elem76 = new IdName(); + _elem76.read(iprot); + this.spaces.add(_elem76); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.spaces.size())); - for (IdName _iter73 : this.spaces) { - _iter73.write(oprot); + for (IdName _iter77 : this.spaces) { + _iter77.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java index 042054f62..c7ac5a393 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list167 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list167.size)); - for (int _i168 = 0; - (_list167.size < 0) ? iprot.peekList() : (_i168 < _list167.size); - ++_i168) + TList _list179 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list179.size)); + for (int _i180 = 0; + (_list179.size < 0) ? iprot.peekList() : (_i180 < _list179.size); + ++_i180) { - IndexItem _elem169; - _elem169 = new IndexItem(); - _elem169.read(iprot); - this.items.add(_elem169); + IndexItem _elem181; + _elem181 = new IndexItem(); + _elem181.read(iprot); + this.items.add(_elem181); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter170 : this.items) { - _iter170.write(oprot); + for (IndexItem _iter182 : this.items) { + _iter182.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListTagsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListTagsResp.java index 276c852c0..a24fca7f8 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListTagsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListTagsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case TAGS: if (__field.type == TType.LIST) { { - TList _list78 = iprot.readListBegin(); - this.tags = new ArrayList(Math.max(0, _list78.size)); - for (int _i79 = 0; - (_list78.size < 0) ? iprot.peekList() : (_i79 < _list78.size); - ++_i79) + TList _list82 = iprot.readListBegin(); + this.tags = new ArrayList(Math.max(0, _list82.size)); + for (int _i83 = 0; + (_list82.size < 0) ? iprot.peekList() : (_i83 < _list82.size); + ++_i83) { - TagItem _elem80; - _elem80 = new TagItem(); - _elem80.read(iprot); - this.tags.add(_elem80); + TagItem _elem84; + _elem84 = new TagItem(); + _elem84.read(iprot); + this.tags.add(_elem84); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TAGS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.tags.size())); - for (TagItem _iter81 : this.tags) { - _iter81.write(oprot); + for (TagItem _iter85 : this.tags) { + _iter85.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java index cae213fbf..dbaa37e01 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java @@ -350,17 +350,17 @@ public void read(TProtocol iprot) throws TException { case USERS: if (__field.type == TType.MAP) { { - TMap _map179 = iprot.readMapBegin(); - this.users = new HashMap(Math.max(0, 2*_map179.size)); - for (int _i180 = 0; - (_map179.size < 0) ? iprot.peekMap() : (_i180 < _map179.size); - ++_i180) + TMap _map191 = iprot.readMapBegin(); + this.users = new HashMap(Math.max(0, 2*_map191.size)); + for (int _i192 = 0; + (_map191.size < 0) ? iprot.peekMap() : (_i192 < _map191.size); + ++_i192) { - byte[] _key181; - byte[] _val182; - _key181 = iprot.readBinary(); - _val182 = iprot.readBinary(); - this.users.put(_key181, _val182); + byte[] _key193; + byte[] _val194; + _key193 = iprot.readBinary(); + _val194 = iprot.readBinary(); + this.users.put(_key193, _val194); } iprot.readMapEnd(); } @@ -399,9 +399,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(USERS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.users.size())); - for (Map.Entry _iter183 : this.users.entrySet()) { - oprot.writeBinary(_iter183.getKey()); - oprot.writeBinary(_iter183.getValue()); + for (Map.Entry _iter195 : this.users.entrySet()) { + oprot.writeBinary(_iter195.getKey()); + oprot.writeBinary(_iter195.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java index b6b47f564..0fd330bf7 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ZONES: if (__field.type == TType.LIST) { { - TList _list220 = iprot.readListBegin(); - this.zones = new ArrayList(Math.max(0, _list220.size)); - for (int _i221 = 0; - (_list220.size < 0) ? iprot.peekList() : (_i221 < _list220.size); - ++_i221) + TList _list236 = iprot.readListBegin(); + this.zones = new ArrayList(Math.max(0, _list236.size)); + for (int _i237 = 0; + (_list236.size < 0) ? iprot.peekList() : (_i237 < _list236.size); + ++_i237) { - Zone _elem222; - _elem222 = new Zone(); - _elem222.read(iprot); - this.zones.add(_elem222); + Zone _elem238; + _elem238 = new Zone(); + _elem238.read(iprot); + this.zones.add(_elem238); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.zones.size())); - for (Zone _iter223 : this.zones) { - _iter223.write(oprot); + for (Zone _iter239 : this.zones) { + _iter239.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java new file mode 100644 index 000000000..8437c68b1 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java @@ -0,0 +1,375 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class MergeZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("MergeZoneReq"); + private static final TField ZONES_FIELD_DESC = new TField("zones", TType.LIST, (short)1); + private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)2); + + public List zones; + public byte[] zone_name; + public static final int ZONES = 1; + public static final int ZONE_NAME = 2; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(ZONES, new FieldMetaData("zones", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.STRING)))); + tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(MergeZoneReq.class, metaDataMap); + } + + public MergeZoneReq() { + } + + public MergeZoneReq( + List zones, + byte[] zone_name) { + this(); + this.zones = zones; + this.zone_name = zone_name; + } + + public static class Builder { + private List zones; + private byte[] zone_name; + + public Builder() { + } + + public Builder setZones(final List zones) { + this.zones = zones; + return this; + } + + public Builder setZone_name(final byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public MergeZoneReq build() { + MergeZoneReq result = new MergeZoneReq(); + result.setZones(this.zones); + result.setZone_name(this.zone_name); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public MergeZoneReq(MergeZoneReq other) { + if (other.isSetZones()) { + this.zones = TBaseHelper.deepCopy(other.zones); + } + if (other.isSetZone_name()) { + this.zone_name = TBaseHelper.deepCopy(other.zone_name); + } + } + + public MergeZoneReq deepCopy() { + return new MergeZoneReq(this); + } + + public List getZones() { + return this.zones; + } + + public MergeZoneReq setZones(List zones) { + this.zones = zones; + return this; + } + + public void unsetZones() { + this.zones = null; + } + + // Returns true if field zones is set (has been assigned a value) and false otherwise + public boolean isSetZones() { + return this.zones != null; + } + + public void setZonesIsSet(boolean __value) { + if (!__value) { + this.zones = null; + } + } + + public byte[] getZone_name() { + return this.zone_name; + } + + public MergeZoneReq setZone_name(byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public void unsetZone_name() { + this.zone_name = null; + } + + // Returns true if field zone_name is set (has been assigned a value) and false otherwise + public boolean isSetZone_name() { + return this.zone_name != null; + } + + public void setZone_nameIsSet(boolean __value) { + if (!__value) { + this.zone_name = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case ZONES: + if (__value == null) { + unsetZones(); + } else { + setZones((List)__value); + } + break; + + case ZONE_NAME: + if (__value == null) { + unsetZone_name(); + } else { + setZone_name((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case ZONES: + return getZones(); + + case ZONE_NAME: + return getZone_name(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof MergeZoneReq)) + return false; + MergeZoneReq that = (MergeZoneReq)_that; + + if (!TBaseHelper.equalsSlow(this.isSetZones(), that.isSetZones(), this.zones, that.zones)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {zones, zone_name}); + } + + @Override + public int compareTo(MergeZoneReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetZones()).compareTo(other.isSetZones()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(zones, other.zones); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case ZONES: + if (__field.type == TType.LIST) { + { + TList _list220 = iprot.readListBegin(); + this.zones = new ArrayList(Math.max(0, _list220.size)); + for (int _i221 = 0; + (_list220.size < 0) ? iprot.peekList() : (_i221 < _list220.size); + ++_i221) + { + byte[] _elem222; + _elem222 = iprot.readBinary(); + this.zones.add(_elem222); + } + iprot.readListEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ZONE_NAME: + if (__field.type == TType.STRING) { + this.zone_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.zones != null) { + oprot.writeFieldBegin(ZONES_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRING, this.zones.size())); + for (byte[] _iter223 : this.zones) { + oprot.writeBinary(_iter223); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + if (this.zone_name != null) { + oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); + oprot.writeBinary(this.zone_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("MergeZoneReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("zones"); + sb.append(space); + sb.append(":").append(space); + if (this.getZones() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getZones(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("zone_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getZone_name() == null) { + sb.append("null"); + } else { + int __zone_name_size = Math.min(this.getZone_name().length, 128); + for (int i = 0; i < __zone_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); + } + if (this.getZone_name().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java index 935646e9c..4d333aa95 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java @@ -61,6 +61,12 @@ public interface Iface { public ListEdgesResp listEdges(ListEdgesReq req) throws TException; + public ExecResp addHosts(AddHostsReq req) throws TException; + + public ExecResp addHostsIntoZone(AddHostsIntoZoneReq req) throws TException; + + public ExecResp dropHosts(DropHostsReq req) throws TException; + public ListHostsResp listHosts(ListHostsReq req) throws TException; public GetPartsAllocResp getPartsAlloc(GetPartsAllocReq req) throws TException; @@ -139,13 +145,13 @@ public interface Iface { public AdminJobResp runAdminJob(AdminJobReq req) throws TException; - public ExecResp addZone(AddZoneReq req) throws TException; + public ExecResp mergeZone(MergeZoneReq req) throws TException; public ExecResp dropZone(DropZoneReq req) throws TException; - public ExecResp addHostIntoZone(AddHostIntoZoneReq req) throws TException; + public ExecResp splitZone(SplitZoneReq req) throws TException; - public ExecResp dropHostFromZone(DropHostFromZoneReq req) throws TException; + public ExecResp renameZone(RenameZoneReq req) throws TException; public GetZoneResp getZone(GetZoneReq req) throws TException; @@ -229,6 +235,12 @@ public interface AsyncIface { public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler) throws TException; + public void addHosts(AddHostsReq req, AsyncMethodCallback resultHandler) throws TException; + + public void addHostsIntoZone(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler) throws TException; + + public void dropHosts(DropHostsReq req, AsyncMethodCallback resultHandler) throws TException; + public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler) throws TException; public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler) throws TException; @@ -307,13 +319,13 @@ public interface AsyncIface { public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler) throws TException; - public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler) throws TException; + public void mergeZone(MergeZoneReq req, AsyncMethodCallback resultHandler) throws TException; public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler) throws TException; - public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler) throws TException; + public void splitZone(SplitZoneReq req, AsyncMethodCallback resultHandler) throws TException; - public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler) throws TException; + public void renameZone(RenameZoneReq req, AsyncMethodCallback resultHandler) throws TException; public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler) throws TException; @@ -1069,6 +1081,141 @@ public ListEdgesResp recv_listEdges() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "listEdges failed: unknown result"); } + public ExecResp addHosts(AddHostsReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.addHosts", null); + this.setContextStack(ctx); + send_addHosts(req); + return recv_addHosts(); + } + + public void send_addHosts(AddHostsReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.addHosts", null); + oprot_.writeMessageBegin(new TMessage("addHosts", TMessageType.CALL, seqid_)); + addHosts_args args = new addHosts_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.addHosts", args); + return; + } + + public ExecResp recv_addHosts() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.addHosts"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + addHosts_result result = new addHosts_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.addHosts", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "addHosts failed: unknown result"); + } + + public ExecResp addHostsIntoZone(AddHostsIntoZoneReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.addHostsIntoZone", null); + this.setContextStack(ctx); + send_addHostsIntoZone(req); + return recv_addHostsIntoZone(); + } + + public void send_addHostsIntoZone(AddHostsIntoZoneReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.addHostsIntoZone", null); + oprot_.writeMessageBegin(new TMessage("addHostsIntoZone", TMessageType.CALL, seqid_)); + addHostsIntoZone_args args = new addHostsIntoZone_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.addHostsIntoZone", args); + return; + } + + public ExecResp recv_addHostsIntoZone() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.addHostsIntoZone"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + addHostsIntoZone_result result = new addHostsIntoZone_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.addHostsIntoZone", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "addHostsIntoZone failed: unknown result"); + } + + public ExecResp dropHosts(DropHostsReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.dropHosts", null); + this.setContextStack(ctx); + send_dropHosts(req); + return recv_dropHosts(); + } + + public void send_dropHosts(DropHostsReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.dropHosts", null); + oprot_.writeMessageBegin(new TMessage("dropHosts", TMessageType.CALL, seqid_)); + dropHosts_args args = new dropHosts_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.dropHosts", args); + return; + } + + public ExecResp recv_dropHosts() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.dropHosts"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + dropHosts_result result = new dropHosts_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.dropHosts", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "dropHosts failed: unknown result"); + } + public ListHostsResp listHosts(ListHostsReq req) throws TException { ContextStack ctx = getContextStack("MetaService.listHosts", null); @@ -2824,49 +2971,49 @@ public AdminJobResp recv_runAdminJob() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "runAdminJob failed: unknown result"); } - public ExecResp addZone(AddZoneReq req) throws TException + public ExecResp mergeZone(MergeZoneReq req) throws TException { - ContextStack ctx = getContextStack("MetaService.addZone", null); + ContextStack ctx = getContextStack("MetaService.mergeZone", null); this.setContextStack(ctx); - send_addZone(req); - return recv_addZone(); + send_mergeZone(req); + return recv_mergeZone(); } - public void send_addZone(AddZoneReq req) throws TException + public void send_mergeZone(MergeZoneReq req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.addZone", null); - oprot_.writeMessageBegin(new TMessage("addZone", TMessageType.CALL, seqid_)); - addZone_args args = new addZone_args(); + super.preWrite(ctx, "MetaService.mergeZone", null); + oprot_.writeMessageBegin(new TMessage("mergeZone", TMessageType.CALL, seqid_)); + mergeZone_args args = new mergeZone_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.addZone", args); + super.postWrite(ctx, "MetaService.mergeZone", args); return; } - public ExecResp recv_addZone() throws TException + public ExecResp recv_mergeZone() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "MetaService.addZone"); + super.preRead(ctx, "MetaService.mergeZone"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - addZone_result result = new addZone_result(); + mergeZone_result result = new mergeZone_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.addZone", result); + super.postRead(ctx, "MetaService.mergeZone", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "addZone failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "mergeZone failed: unknown result"); } public ExecResp dropZone(DropZoneReq req) throws TException @@ -2914,94 +3061,94 @@ public ExecResp recv_dropZone() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "dropZone failed: unknown result"); } - public ExecResp addHostIntoZone(AddHostIntoZoneReq req) throws TException + public ExecResp splitZone(SplitZoneReq req) throws TException { - ContextStack ctx = getContextStack("MetaService.addHostIntoZone", null); + ContextStack ctx = getContextStack("MetaService.splitZone", null); this.setContextStack(ctx); - send_addHostIntoZone(req); - return recv_addHostIntoZone(); + send_splitZone(req); + return recv_splitZone(); } - public void send_addHostIntoZone(AddHostIntoZoneReq req) throws TException + public void send_splitZone(SplitZoneReq req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.addHostIntoZone", null); - oprot_.writeMessageBegin(new TMessage("addHostIntoZone", TMessageType.CALL, seqid_)); - addHostIntoZone_args args = new addHostIntoZone_args(); + super.preWrite(ctx, "MetaService.splitZone", null); + oprot_.writeMessageBegin(new TMessage("splitZone", TMessageType.CALL, seqid_)); + splitZone_args args = new splitZone_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.addHostIntoZone", args); + super.postWrite(ctx, "MetaService.splitZone", args); return; } - public ExecResp recv_addHostIntoZone() throws TException + public ExecResp recv_splitZone() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "MetaService.addHostIntoZone"); + super.preRead(ctx, "MetaService.splitZone"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - addHostIntoZone_result result = new addHostIntoZone_result(); + splitZone_result result = new splitZone_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.addHostIntoZone", result); + super.postRead(ctx, "MetaService.splitZone", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "addHostIntoZone failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "splitZone failed: unknown result"); } - public ExecResp dropHostFromZone(DropHostFromZoneReq req) throws TException + public ExecResp renameZone(RenameZoneReq req) throws TException { - ContextStack ctx = getContextStack("MetaService.dropHostFromZone", null); + ContextStack ctx = getContextStack("MetaService.renameZone", null); this.setContextStack(ctx); - send_dropHostFromZone(req); - return recv_dropHostFromZone(); + send_renameZone(req); + return recv_renameZone(); } - public void send_dropHostFromZone(DropHostFromZoneReq req) throws TException + public void send_renameZone(RenameZoneReq req) throws TException { ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.dropHostFromZone", null); - oprot_.writeMessageBegin(new TMessage("dropHostFromZone", TMessageType.CALL, seqid_)); - dropHostFromZone_args args = new dropHostFromZone_args(); + super.preWrite(ctx, "MetaService.renameZone", null); + oprot_.writeMessageBegin(new TMessage("renameZone", TMessageType.CALL, seqid_)); + renameZone_args args = new renameZone_args(); args.req = req; args.write(oprot_); oprot_.writeMessageEnd(); oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.dropHostFromZone", args); + super.postWrite(ctx, "MetaService.renameZone", args); return; } - public ExecResp recv_dropHostFromZone() throws TException + public ExecResp recv_renameZone() throws TException { ContextStack ctx = super.getContextStack(); long bytes; TMessageType mtype; - super.preRead(ctx, "MetaService.dropHostFromZone"); + super.preRead(ctx, "MetaService.renameZone"); TMessage msg = iprot_.readMessageBegin(); if (msg.type == TMessageType.EXCEPTION) { TApplicationException x = TApplicationException.read(iprot_); iprot_.readMessageEnd(); throw x; } - dropHostFromZone_result result = new dropHostFromZone_result(); + renameZone_result result = new renameZone_result(); result.read(iprot_); iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.dropHostFromZone", result); + super.postRead(ctx, "MetaService.renameZone", result); if (result.isSetSuccess()) { return result.success; } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "dropHostFromZone failed: unknown result"); + throw new TApplicationException(TApplicationException.MISSING_RESULT, "renameZone failed: unknown result"); } public GetZoneResp getZone(GetZoneReq req) throws TException @@ -4102,17 +4249,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler408) throws TException { + public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler427) throws TException { checkReady(); - createSpace_call method_call = new createSpace_call(req, resultHandler408, this, ___protocolFactory, ___transport); + createSpace_call method_call = new createSpace_call(req, resultHandler427, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpace_call extends TAsyncMethodCall { private CreateSpaceReq req; - public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler409, TAsyncClient client405, TProtocolFactory protocolFactory406, TNonblockingTransport transport407) throws TException { - super(client405, protocolFactory406, transport407, resultHandler409, false); + public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler428, TAsyncClient client424, TProtocolFactory protocolFactory425, TNonblockingTransport transport426) throws TException { + super(client424, protocolFactory425, transport426, resultHandler428, false); this.req = req; } @@ -4134,17 +4281,17 @@ public ExecResp getResult() throws TException { } } - public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler413) throws TException { + public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler432) throws TException { checkReady(); - dropSpace_call method_call = new dropSpace_call(req, resultHandler413, this, ___protocolFactory, ___transport); + dropSpace_call method_call = new dropSpace_call(req, resultHandler432, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSpace_call extends TAsyncMethodCall { private DropSpaceReq req; - public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler414, TAsyncClient client410, TProtocolFactory protocolFactory411, TNonblockingTransport transport412) throws TException { - super(client410, protocolFactory411, transport412, resultHandler414, false); + public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler433, TAsyncClient client429, TProtocolFactory protocolFactory430, TNonblockingTransport transport431) throws TException { + super(client429, protocolFactory430, transport431, resultHandler433, false); this.req = req; } @@ -4166,17 +4313,17 @@ public ExecResp getResult() throws TException { } } - public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler418) throws TException { + public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler437) throws TException { checkReady(); - getSpace_call method_call = new getSpace_call(req, resultHandler418, this, ___protocolFactory, ___transport); + getSpace_call method_call = new getSpace_call(req, resultHandler437, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSpace_call extends TAsyncMethodCall { private GetSpaceReq req; - public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler419, TAsyncClient client415, TProtocolFactory protocolFactory416, TNonblockingTransport transport417) throws TException { - super(client415, protocolFactory416, transport417, resultHandler419, false); + public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler438, TAsyncClient client434, TProtocolFactory protocolFactory435, TNonblockingTransport transport436) throws TException { + super(client434, protocolFactory435, transport436, resultHandler438, false); this.req = req; } @@ -4198,17 +4345,17 @@ public GetSpaceResp getResult() throws TException { } } - public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler423) throws TException { + public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler442) throws TException { checkReady(); - listSpaces_call method_call = new listSpaces_call(req, resultHandler423, this, ___protocolFactory, ___transport); + listSpaces_call method_call = new listSpaces_call(req, resultHandler442, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSpaces_call extends TAsyncMethodCall { private ListSpacesReq req; - public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler424, TAsyncClient client420, TProtocolFactory protocolFactory421, TNonblockingTransport transport422) throws TException { - super(client420, protocolFactory421, transport422, resultHandler424, false); + public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler443, TAsyncClient client439, TProtocolFactory protocolFactory440, TNonblockingTransport transport441) throws TException { + super(client439, protocolFactory440, transport441, resultHandler443, false); this.req = req; } @@ -4230,17 +4377,17 @@ public ListSpacesResp getResult() throws TException { } } - public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler428) throws TException { + public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler447) throws TException { checkReady(); - createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler428, this, ___protocolFactory, ___transport); + createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler447, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpaceAs_call extends TAsyncMethodCall { private CreateSpaceAsReq req; - public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler429, TAsyncClient client425, TProtocolFactory protocolFactory426, TNonblockingTransport transport427) throws TException { - super(client425, protocolFactory426, transport427, resultHandler429, false); + public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler448, TAsyncClient client444, TProtocolFactory protocolFactory445, TNonblockingTransport transport446) throws TException { + super(client444, protocolFactory445, transport446, resultHandler448, false); this.req = req; } @@ -4262,17 +4409,17 @@ public ExecResp getResult() throws TException { } } - public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler433) throws TException { + public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler452) throws TException { checkReady(); - createTag_call method_call = new createTag_call(req, resultHandler433, this, ___protocolFactory, ___transport); + createTag_call method_call = new createTag_call(req, resultHandler452, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTag_call extends TAsyncMethodCall { private CreateTagReq req; - public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler434, TAsyncClient client430, TProtocolFactory protocolFactory431, TNonblockingTransport transport432) throws TException { - super(client430, protocolFactory431, transport432, resultHandler434, false); + public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler453, TAsyncClient client449, TProtocolFactory protocolFactory450, TNonblockingTransport transport451) throws TException { + super(client449, protocolFactory450, transport451, resultHandler453, false); this.req = req; } @@ -4294,17 +4441,17 @@ public ExecResp getResult() throws TException { } } - public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler438) throws TException { + public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler457) throws TException { checkReady(); - alterTag_call method_call = new alterTag_call(req, resultHandler438, this, ___protocolFactory, ___transport); + alterTag_call method_call = new alterTag_call(req, resultHandler457, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterTag_call extends TAsyncMethodCall { private AlterTagReq req; - public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler439, TAsyncClient client435, TProtocolFactory protocolFactory436, TNonblockingTransport transport437) throws TException { - super(client435, protocolFactory436, transport437, resultHandler439, false); + public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler458, TAsyncClient client454, TProtocolFactory protocolFactory455, TNonblockingTransport transport456) throws TException { + super(client454, protocolFactory455, transport456, resultHandler458, false); this.req = req; } @@ -4326,17 +4473,17 @@ public ExecResp getResult() throws TException { } } - public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler443) throws TException { + public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler462) throws TException { checkReady(); - dropTag_call method_call = new dropTag_call(req, resultHandler443, this, ___protocolFactory, ___transport); + dropTag_call method_call = new dropTag_call(req, resultHandler462, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTag_call extends TAsyncMethodCall { private DropTagReq req; - public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler444, TAsyncClient client440, TProtocolFactory protocolFactory441, TNonblockingTransport transport442) throws TException { - super(client440, protocolFactory441, transport442, resultHandler444, false); + public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler463, TAsyncClient client459, TProtocolFactory protocolFactory460, TNonblockingTransport transport461) throws TException { + super(client459, protocolFactory460, transport461, resultHandler463, false); this.req = req; } @@ -4358,17 +4505,17 @@ public ExecResp getResult() throws TException { } } - public void getTag(GetTagReq req, AsyncMethodCallback resultHandler448) throws TException { + public void getTag(GetTagReq req, AsyncMethodCallback resultHandler467) throws TException { checkReady(); - getTag_call method_call = new getTag_call(req, resultHandler448, this, ___protocolFactory, ___transport); + getTag_call method_call = new getTag_call(req, resultHandler467, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTag_call extends TAsyncMethodCall { private GetTagReq req; - public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler449, TAsyncClient client445, TProtocolFactory protocolFactory446, TNonblockingTransport transport447) throws TException { - super(client445, protocolFactory446, transport447, resultHandler449, false); + public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler468, TAsyncClient client464, TProtocolFactory protocolFactory465, TNonblockingTransport transport466) throws TException { + super(client464, protocolFactory465, transport466, resultHandler468, false); this.req = req; } @@ -4390,17 +4537,17 @@ public GetTagResp getResult() throws TException { } } - public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler453) throws TException { + public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler472) throws TException { checkReady(); - listTags_call method_call = new listTags_call(req, resultHandler453, this, ___protocolFactory, ___transport); + listTags_call method_call = new listTags_call(req, resultHandler472, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTags_call extends TAsyncMethodCall { private ListTagsReq req; - public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler454, TAsyncClient client450, TProtocolFactory protocolFactory451, TNonblockingTransport transport452) throws TException { - super(client450, protocolFactory451, transport452, resultHandler454, false); + public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler473, TAsyncClient client469, TProtocolFactory protocolFactory470, TNonblockingTransport transport471) throws TException { + super(client469, protocolFactory470, transport471, resultHandler473, false); this.req = req; } @@ -4422,17 +4569,17 @@ public ListTagsResp getResult() throws TException { } } - public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler458) throws TException { + public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler477) throws TException { checkReady(); - createEdge_call method_call = new createEdge_call(req, resultHandler458, this, ___protocolFactory, ___transport); + createEdge_call method_call = new createEdge_call(req, resultHandler477, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdge_call extends TAsyncMethodCall { private CreateEdgeReq req; - public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler459, TAsyncClient client455, TProtocolFactory protocolFactory456, TNonblockingTransport transport457) throws TException { - super(client455, protocolFactory456, transport457, resultHandler459, false); + public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler478, TAsyncClient client474, TProtocolFactory protocolFactory475, TNonblockingTransport transport476) throws TException { + super(client474, protocolFactory475, transport476, resultHandler478, false); this.req = req; } @@ -4454,17 +4601,17 @@ public ExecResp getResult() throws TException { } } - public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler463) throws TException { + public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler482) throws TException { checkReady(); - alterEdge_call method_call = new alterEdge_call(req, resultHandler463, this, ___protocolFactory, ___transport); + alterEdge_call method_call = new alterEdge_call(req, resultHandler482, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterEdge_call extends TAsyncMethodCall { private AlterEdgeReq req; - public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler464, TAsyncClient client460, TProtocolFactory protocolFactory461, TNonblockingTransport transport462) throws TException { - super(client460, protocolFactory461, transport462, resultHandler464, false); + public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler483, TAsyncClient client479, TProtocolFactory protocolFactory480, TNonblockingTransport transport481) throws TException { + super(client479, protocolFactory480, transport481, resultHandler483, false); this.req = req; } @@ -4486,17 +4633,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler468) throws TException { + public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler487) throws TException { checkReady(); - dropEdge_call method_call = new dropEdge_call(req, resultHandler468, this, ___protocolFactory, ___transport); + dropEdge_call method_call = new dropEdge_call(req, resultHandler487, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdge_call extends TAsyncMethodCall { private DropEdgeReq req; - public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler469, TAsyncClient client465, TProtocolFactory protocolFactory466, TNonblockingTransport transport467) throws TException { - super(client465, protocolFactory466, transport467, resultHandler469, false); + public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler488, TAsyncClient client484, TProtocolFactory protocolFactory485, TNonblockingTransport transport486) throws TException { + super(client484, protocolFactory485, transport486, resultHandler488, false); this.req = req; } @@ -4518,17 +4665,17 @@ public ExecResp getResult() throws TException { } } - public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler473) throws TException { + public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler492) throws TException { checkReady(); - getEdge_call method_call = new getEdge_call(req, resultHandler473, this, ___protocolFactory, ___transport); + getEdge_call method_call = new getEdge_call(req, resultHandler492, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdge_call extends TAsyncMethodCall { private GetEdgeReq req; - public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler474, TAsyncClient client470, TProtocolFactory protocolFactory471, TNonblockingTransport transport472) throws TException { - super(client470, protocolFactory471, transport472, resultHandler474, false); + public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler493, TAsyncClient client489, TProtocolFactory protocolFactory490, TNonblockingTransport transport491) throws TException { + super(client489, protocolFactory490, transport491, resultHandler493, false); this.req = req; } @@ -4550,17 +4697,17 @@ public GetEdgeResp getResult() throws TException { } } - public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler478) throws TException { + public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler497) throws TException { checkReady(); - listEdges_call method_call = new listEdges_call(req, resultHandler478, this, ___protocolFactory, ___transport); + listEdges_call method_call = new listEdges_call(req, resultHandler497, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdges_call extends TAsyncMethodCall { private ListEdgesReq req; - public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler479, TAsyncClient client475, TProtocolFactory protocolFactory476, TNonblockingTransport transport477) throws TException { - super(client475, protocolFactory476, transport477, resultHandler479, false); + public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler498, TAsyncClient client494, TProtocolFactory protocolFactory495, TNonblockingTransport transport496) throws TException { + super(client494, protocolFactory495, transport496, resultHandler498, false); this.req = req; } @@ -4582,17 +4729,113 @@ public ListEdgesResp getResult() throws TException { } } - public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler483) throws TException { + public void addHosts(AddHostsReq req, AsyncMethodCallback resultHandler502) throws TException { + checkReady(); + addHosts_call method_call = new addHosts_call(req, resultHandler502, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class addHosts_call extends TAsyncMethodCall { + private AddHostsReq req; + public addHosts_call(AddHostsReq req, AsyncMethodCallback resultHandler503, TAsyncClient client499, TProtocolFactory protocolFactory500, TNonblockingTransport transport501) throws TException { + super(client499, protocolFactory500, transport501, resultHandler503, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("addHosts", TMessageType.CALL, 0)); + addHosts_args args = new addHosts_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_addHosts(); + } + } + + public void addHostsIntoZone(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler507) throws TException { + checkReady(); + addHostsIntoZone_call method_call = new addHostsIntoZone_call(req, resultHandler507, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class addHostsIntoZone_call extends TAsyncMethodCall { + private AddHostsIntoZoneReq req; + public addHostsIntoZone_call(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler508, TAsyncClient client504, TProtocolFactory protocolFactory505, TNonblockingTransport transport506) throws TException { + super(client504, protocolFactory505, transport506, resultHandler508, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("addHostsIntoZone", TMessageType.CALL, 0)); + addHostsIntoZone_args args = new addHostsIntoZone_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_addHostsIntoZone(); + } + } + + public void dropHosts(DropHostsReq req, AsyncMethodCallback resultHandler512) throws TException { + checkReady(); + dropHosts_call method_call = new dropHosts_call(req, resultHandler512, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class dropHosts_call extends TAsyncMethodCall { + private DropHostsReq req; + public dropHosts_call(DropHostsReq req, AsyncMethodCallback resultHandler513, TAsyncClient client509, TProtocolFactory protocolFactory510, TNonblockingTransport transport511) throws TException { + super(client509, protocolFactory510, transport511, resultHandler513, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("dropHosts", TMessageType.CALL, 0)); + dropHosts_args args = new dropHosts_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_dropHosts(); + } + } + + public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler517) throws TException { checkReady(); - listHosts_call method_call = new listHosts_call(req, resultHandler483, this, ___protocolFactory, ___transport); + listHosts_call method_call = new listHosts_call(req, resultHandler517, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listHosts_call extends TAsyncMethodCall { private ListHostsReq req; - public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler484, TAsyncClient client480, TProtocolFactory protocolFactory481, TNonblockingTransport transport482) throws TException { - super(client480, protocolFactory481, transport482, resultHandler484, false); + public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler518, TAsyncClient client514, TProtocolFactory protocolFactory515, TNonblockingTransport transport516) throws TException { + super(client514, protocolFactory515, transport516, resultHandler518, false); this.req = req; } @@ -4614,17 +4857,17 @@ public ListHostsResp getResult() throws TException { } } - public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler488) throws TException { + public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler522) throws TException { checkReady(); - getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler488, this, ___protocolFactory, ___transport); + getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler522, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getPartsAlloc_call extends TAsyncMethodCall { private GetPartsAllocReq req; - public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler489, TAsyncClient client485, TProtocolFactory protocolFactory486, TNonblockingTransport transport487) throws TException { - super(client485, protocolFactory486, transport487, resultHandler489, false); + public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler523, TAsyncClient client519, TProtocolFactory protocolFactory520, TNonblockingTransport transport521) throws TException { + super(client519, protocolFactory520, transport521, resultHandler523, false); this.req = req; } @@ -4646,17 +4889,17 @@ public GetPartsAllocResp getResult() throws TException { } } - public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler493) throws TException { + public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler527) throws TException { checkReady(); - listParts_call method_call = new listParts_call(req, resultHandler493, this, ___protocolFactory, ___transport); + listParts_call method_call = new listParts_call(req, resultHandler527, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listParts_call extends TAsyncMethodCall { private ListPartsReq req; - public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler494, TAsyncClient client490, TProtocolFactory protocolFactory491, TNonblockingTransport transport492) throws TException { - super(client490, protocolFactory491, transport492, resultHandler494, false); + public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler528, TAsyncClient client524, TProtocolFactory protocolFactory525, TNonblockingTransport transport526) throws TException { + super(client524, protocolFactory525, transport526, resultHandler528, false); this.req = req; } @@ -4678,17 +4921,17 @@ public ListPartsResp getResult() throws TException { } } - public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler498) throws TException { + public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler532) throws TException { checkReady(); - multiPut_call method_call = new multiPut_call(req, resultHandler498, this, ___protocolFactory, ___transport); + multiPut_call method_call = new multiPut_call(req, resultHandler532, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiPut_call extends TAsyncMethodCall { private MultiPutReq req; - public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler499, TAsyncClient client495, TProtocolFactory protocolFactory496, TNonblockingTransport transport497) throws TException { - super(client495, protocolFactory496, transport497, resultHandler499, false); + public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler533, TAsyncClient client529, TProtocolFactory protocolFactory530, TNonblockingTransport transport531) throws TException { + super(client529, protocolFactory530, transport531, resultHandler533, false); this.req = req; } @@ -4710,17 +4953,17 @@ public ExecResp getResult() throws TException { } } - public void get(GetReq req, AsyncMethodCallback resultHandler503) throws TException { + public void get(GetReq req, AsyncMethodCallback resultHandler537) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler503, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler537, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private GetReq req; - public get_call(GetReq req, AsyncMethodCallback resultHandler504, TAsyncClient client500, TProtocolFactory protocolFactory501, TNonblockingTransport transport502) throws TException { - super(client500, protocolFactory501, transport502, resultHandler504, false); + public get_call(GetReq req, AsyncMethodCallback resultHandler538, TAsyncClient client534, TProtocolFactory protocolFactory535, TNonblockingTransport transport536) throws TException { + super(client534, protocolFactory535, transport536, resultHandler538, false); this.req = req; } @@ -4742,17 +4985,17 @@ public GetResp getResult() throws TException { } } - public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler508) throws TException { + public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler542) throws TException { checkReady(); - multiGet_call method_call = new multiGet_call(req, resultHandler508, this, ___protocolFactory, ___transport); + multiGet_call method_call = new multiGet_call(req, resultHandler542, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiGet_call extends TAsyncMethodCall { private MultiGetReq req; - public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler509, TAsyncClient client505, TProtocolFactory protocolFactory506, TNonblockingTransport transport507) throws TException { - super(client505, protocolFactory506, transport507, resultHandler509, false); + public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler543, TAsyncClient client539, TProtocolFactory protocolFactory540, TNonblockingTransport transport541) throws TException { + super(client539, protocolFactory540, transport541, resultHandler543, false); this.req = req; } @@ -4774,17 +5017,17 @@ public MultiGetResp getResult() throws TException { } } - public void remove(RemoveReq req, AsyncMethodCallback resultHandler513) throws TException { + public void remove(RemoveReq req, AsyncMethodCallback resultHandler547) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler513, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler547, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private RemoveReq req; - public remove_call(RemoveReq req, AsyncMethodCallback resultHandler514, TAsyncClient client510, TProtocolFactory protocolFactory511, TNonblockingTransport transport512) throws TException { - super(client510, protocolFactory511, transport512, resultHandler514, false); + public remove_call(RemoveReq req, AsyncMethodCallback resultHandler548, TAsyncClient client544, TProtocolFactory protocolFactory545, TNonblockingTransport transport546) throws TException { + super(client544, protocolFactory545, transport546, resultHandler548, false); this.req = req; } @@ -4806,17 +5049,17 @@ public ExecResp getResult() throws TException { } } - public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler518) throws TException { + public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler552) throws TException { checkReady(); - removeRange_call method_call = new removeRange_call(req, resultHandler518, this, ___protocolFactory, ___transport); + removeRange_call method_call = new removeRange_call(req, resultHandler552, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeRange_call extends TAsyncMethodCall { private RemoveRangeReq req; - public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler519, TAsyncClient client515, TProtocolFactory protocolFactory516, TNonblockingTransport transport517) throws TException { - super(client515, protocolFactory516, transport517, resultHandler519, false); + public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler553, TAsyncClient client549, TProtocolFactory protocolFactory550, TNonblockingTransport transport551) throws TException { + super(client549, protocolFactory550, transport551, resultHandler553, false); this.req = req; } @@ -4838,17 +5081,17 @@ public ExecResp getResult() throws TException { } } - public void scan(ScanReq req, AsyncMethodCallback resultHandler523) throws TException { + public void scan(ScanReq req, AsyncMethodCallback resultHandler557) throws TException { checkReady(); - scan_call method_call = new scan_call(req, resultHandler523, this, ___protocolFactory, ___transport); + scan_call method_call = new scan_call(req, resultHandler557, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scan_call extends TAsyncMethodCall { private ScanReq req; - public scan_call(ScanReq req, AsyncMethodCallback resultHandler524, TAsyncClient client520, TProtocolFactory protocolFactory521, TNonblockingTransport transport522) throws TException { - super(client520, protocolFactory521, transport522, resultHandler524, false); + public scan_call(ScanReq req, AsyncMethodCallback resultHandler558, TAsyncClient client554, TProtocolFactory protocolFactory555, TNonblockingTransport transport556) throws TException { + super(client554, protocolFactory555, transport556, resultHandler558, false); this.req = req; } @@ -4870,17 +5113,17 @@ public ScanResp getResult() throws TException { } } - public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler528) throws TException { + public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler562) throws TException { checkReady(); - createTagIndex_call method_call = new createTagIndex_call(req, resultHandler528, this, ___protocolFactory, ___transport); + createTagIndex_call method_call = new createTagIndex_call(req, resultHandler562, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTagIndex_call extends TAsyncMethodCall { private CreateTagIndexReq req; - public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler529, TAsyncClient client525, TProtocolFactory protocolFactory526, TNonblockingTransport transport527) throws TException { - super(client525, protocolFactory526, transport527, resultHandler529, false); + public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler563, TAsyncClient client559, TProtocolFactory protocolFactory560, TNonblockingTransport transport561) throws TException { + super(client559, protocolFactory560, transport561, resultHandler563, false); this.req = req; } @@ -4902,17 +5145,17 @@ public ExecResp getResult() throws TException { } } - public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler533) throws TException { + public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler567) throws TException { checkReady(); - dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler533, this, ___protocolFactory, ___transport); + dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler567, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTagIndex_call extends TAsyncMethodCall { private DropTagIndexReq req; - public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler534, TAsyncClient client530, TProtocolFactory protocolFactory531, TNonblockingTransport transport532) throws TException { - super(client530, protocolFactory531, transport532, resultHandler534, false); + public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler568, TAsyncClient client564, TProtocolFactory protocolFactory565, TNonblockingTransport transport566) throws TException { + super(client564, protocolFactory565, transport566, resultHandler568, false); this.req = req; } @@ -4934,17 +5177,17 @@ public ExecResp getResult() throws TException { } } - public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler538) throws TException { + public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler572) throws TException { checkReady(); - getTagIndex_call method_call = new getTagIndex_call(req, resultHandler538, this, ___protocolFactory, ___transport); + getTagIndex_call method_call = new getTagIndex_call(req, resultHandler572, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTagIndex_call extends TAsyncMethodCall { private GetTagIndexReq req; - public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler539, TAsyncClient client535, TProtocolFactory protocolFactory536, TNonblockingTransport transport537) throws TException { - super(client535, protocolFactory536, transport537, resultHandler539, false); + public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler573, TAsyncClient client569, TProtocolFactory protocolFactory570, TNonblockingTransport transport571) throws TException { + super(client569, protocolFactory570, transport571, resultHandler573, false); this.req = req; } @@ -4966,17 +5209,17 @@ public GetTagIndexResp getResult() throws TException { } } - public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler543) throws TException { + public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler577) throws TException { checkReady(); - listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler543, this, ___protocolFactory, ___transport); + listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler577, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexes_call extends TAsyncMethodCall { private ListTagIndexesReq req; - public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler544, TAsyncClient client540, TProtocolFactory protocolFactory541, TNonblockingTransport transport542) throws TException { - super(client540, protocolFactory541, transport542, resultHandler544, false); + public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler578, TAsyncClient client574, TProtocolFactory protocolFactory575, TNonblockingTransport transport576) throws TException { + super(client574, protocolFactory575, transport576, resultHandler578, false); this.req = req; } @@ -4998,17 +5241,17 @@ public ListTagIndexesResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler548) throws TException { + public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler582) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler548, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler582, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler549, TAsyncClient client545, TProtocolFactory protocolFactory546, TNonblockingTransport transport547) throws TException { - super(client545, protocolFactory546, transport547, resultHandler549, false); + public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler583, TAsyncClient client579, TProtocolFactory protocolFactory580, TNonblockingTransport transport581) throws TException { + super(client579, protocolFactory580, transport581, resultHandler583, false); this.req = req; } @@ -5030,17 +5273,17 @@ public ExecResp getResult() throws TException { } } - public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler553) throws TException { + public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler587) throws TException { checkReady(); - listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler553, this, ___protocolFactory, ___transport); + listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler587, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler554, TAsyncClient client550, TProtocolFactory protocolFactory551, TNonblockingTransport transport552) throws TException { - super(client550, protocolFactory551, transport552, resultHandler554, false); + public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler588, TAsyncClient client584, TProtocolFactory protocolFactory585, TNonblockingTransport transport586) throws TException { + super(client584, protocolFactory585, transport586, resultHandler588, false); this.req = req; } @@ -5062,17 +5305,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler558) throws TException { + public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler592) throws TException { checkReady(); - createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler558, this, ___protocolFactory, ___transport); + createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler592, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdgeIndex_call extends TAsyncMethodCall { private CreateEdgeIndexReq req; - public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler559, TAsyncClient client555, TProtocolFactory protocolFactory556, TNonblockingTransport transport557) throws TException { - super(client555, protocolFactory556, transport557, resultHandler559, false); + public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler593, TAsyncClient client589, TProtocolFactory protocolFactory590, TNonblockingTransport transport591) throws TException { + super(client589, protocolFactory590, transport591, resultHandler593, false); this.req = req; } @@ -5094,17 +5337,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler563) throws TException { + public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler597) throws TException { checkReady(); - dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler563, this, ___protocolFactory, ___transport); + dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler597, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdgeIndex_call extends TAsyncMethodCall { private DropEdgeIndexReq req; - public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler564, TAsyncClient client560, TProtocolFactory protocolFactory561, TNonblockingTransport transport562) throws TException { - super(client560, protocolFactory561, transport562, resultHandler564, false); + public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler598, TAsyncClient client594, TProtocolFactory protocolFactory595, TNonblockingTransport transport596) throws TException { + super(client594, protocolFactory595, transport596, resultHandler598, false); this.req = req; } @@ -5126,17 +5369,17 @@ public ExecResp getResult() throws TException { } } - public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler568) throws TException { + public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler602) throws TException { checkReady(); - getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler568, this, ___protocolFactory, ___transport); + getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler602, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdgeIndex_call extends TAsyncMethodCall { private GetEdgeIndexReq req; - public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler569, TAsyncClient client565, TProtocolFactory protocolFactory566, TNonblockingTransport transport567) throws TException { - super(client565, protocolFactory566, transport567, resultHandler569, false); + public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler603, TAsyncClient client599, TProtocolFactory protocolFactory600, TNonblockingTransport transport601) throws TException { + super(client599, protocolFactory600, transport601, resultHandler603, false); this.req = req; } @@ -5158,17 +5401,17 @@ public GetEdgeIndexResp getResult() throws TException { } } - public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler573) throws TException { + public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler607) throws TException { checkReady(); - listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler573, this, ___protocolFactory, ___transport); + listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler607, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexes_call extends TAsyncMethodCall { private ListEdgeIndexesReq req; - public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler574, TAsyncClient client570, TProtocolFactory protocolFactory571, TNonblockingTransport transport572) throws TException { - super(client570, protocolFactory571, transport572, resultHandler574, false); + public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler608, TAsyncClient client604, TProtocolFactory protocolFactory605, TNonblockingTransport transport606) throws TException { + super(client604, protocolFactory605, transport606, resultHandler608, false); this.req = req; } @@ -5190,17 +5433,17 @@ public ListEdgeIndexesResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler578) throws TException { + public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler612) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler578, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler612, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler579, TAsyncClient client575, TProtocolFactory protocolFactory576, TNonblockingTransport transport577) throws TException { - super(client575, protocolFactory576, transport577, resultHandler579, false); + public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler613, TAsyncClient client609, TProtocolFactory protocolFactory610, TNonblockingTransport transport611) throws TException { + super(client609, protocolFactory610, transport611, resultHandler613, false); this.req = req; } @@ -5222,17 +5465,17 @@ public ExecResp getResult() throws TException { } } - public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler583) throws TException { + public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler617) throws TException { checkReady(); - listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler583, this, ___protocolFactory, ___transport); + listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler617, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler584, TAsyncClient client580, TProtocolFactory protocolFactory581, TNonblockingTransport transport582) throws TException { - super(client580, protocolFactory581, transport582, resultHandler584, false); + public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler618, TAsyncClient client614, TProtocolFactory protocolFactory615, TNonblockingTransport transport616) throws TException { + super(client614, protocolFactory615, transport616, resultHandler618, false); this.req = req; } @@ -5254,17 +5497,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler588) throws TException { + public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler622) throws TException { checkReady(); - createUser_call method_call = new createUser_call(req, resultHandler588, this, ___protocolFactory, ___transport); + createUser_call method_call = new createUser_call(req, resultHandler622, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createUser_call extends TAsyncMethodCall { private CreateUserReq req; - public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler589, TAsyncClient client585, TProtocolFactory protocolFactory586, TNonblockingTransport transport587) throws TException { - super(client585, protocolFactory586, transport587, resultHandler589, false); + public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler623, TAsyncClient client619, TProtocolFactory protocolFactory620, TNonblockingTransport transport621) throws TException { + super(client619, protocolFactory620, transport621, resultHandler623, false); this.req = req; } @@ -5286,17 +5529,17 @@ public ExecResp getResult() throws TException { } } - public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler593) throws TException { + public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler627) throws TException { checkReady(); - dropUser_call method_call = new dropUser_call(req, resultHandler593, this, ___protocolFactory, ___transport); + dropUser_call method_call = new dropUser_call(req, resultHandler627, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropUser_call extends TAsyncMethodCall { private DropUserReq req; - public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler594, TAsyncClient client590, TProtocolFactory protocolFactory591, TNonblockingTransport transport592) throws TException { - super(client590, protocolFactory591, transport592, resultHandler594, false); + public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler628, TAsyncClient client624, TProtocolFactory protocolFactory625, TNonblockingTransport transport626) throws TException { + super(client624, protocolFactory625, transport626, resultHandler628, false); this.req = req; } @@ -5318,17 +5561,17 @@ public ExecResp getResult() throws TException { } } - public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler598) throws TException { + public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler632) throws TException { checkReady(); - alterUser_call method_call = new alterUser_call(req, resultHandler598, this, ___protocolFactory, ___transport); + alterUser_call method_call = new alterUser_call(req, resultHandler632, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterUser_call extends TAsyncMethodCall { private AlterUserReq req; - public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler599, TAsyncClient client595, TProtocolFactory protocolFactory596, TNonblockingTransport transport597) throws TException { - super(client595, protocolFactory596, transport597, resultHandler599, false); + public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler633, TAsyncClient client629, TProtocolFactory protocolFactory630, TNonblockingTransport transport631) throws TException { + super(client629, protocolFactory630, transport631, resultHandler633, false); this.req = req; } @@ -5350,17 +5593,17 @@ public ExecResp getResult() throws TException { } } - public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler603) throws TException { + public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler637) throws TException { checkReady(); - grantRole_call method_call = new grantRole_call(req, resultHandler603, this, ___protocolFactory, ___transport); + grantRole_call method_call = new grantRole_call(req, resultHandler637, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class grantRole_call extends TAsyncMethodCall { private GrantRoleReq req; - public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler604, TAsyncClient client600, TProtocolFactory protocolFactory601, TNonblockingTransport transport602) throws TException { - super(client600, protocolFactory601, transport602, resultHandler604, false); + public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler638, TAsyncClient client634, TProtocolFactory protocolFactory635, TNonblockingTransport transport636) throws TException { + super(client634, protocolFactory635, transport636, resultHandler638, false); this.req = req; } @@ -5382,17 +5625,17 @@ public ExecResp getResult() throws TException { } } - public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler608) throws TException { + public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler642) throws TException { checkReady(); - revokeRole_call method_call = new revokeRole_call(req, resultHandler608, this, ___protocolFactory, ___transport); + revokeRole_call method_call = new revokeRole_call(req, resultHandler642, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class revokeRole_call extends TAsyncMethodCall { private RevokeRoleReq req; - public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler609, TAsyncClient client605, TProtocolFactory protocolFactory606, TNonblockingTransport transport607) throws TException { - super(client605, protocolFactory606, transport607, resultHandler609, false); + public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler643, TAsyncClient client639, TProtocolFactory protocolFactory640, TNonblockingTransport transport641) throws TException { + super(client639, protocolFactory640, transport641, resultHandler643, false); this.req = req; } @@ -5414,17 +5657,17 @@ public ExecResp getResult() throws TException { } } - public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler613) throws TException { + public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler647) throws TException { checkReady(); - listUsers_call method_call = new listUsers_call(req, resultHandler613, this, ___protocolFactory, ___transport); + listUsers_call method_call = new listUsers_call(req, resultHandler647, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listUsers_call extends TAsyncMethodCall { private ListUsersReq req; - public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler614, TAsyncClient client610, TProtocolFactory protocolFactory611, TNonblockingTransport transport612) throws TException { - super(client610, protocolFactory611, transport612, resultHandler614, false); + public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler648, TAsyncClient client644, TProtocolFactory protocolFactory645, TNonblockingTransport transport646) throws TException { + super(client644, protocolFactory645, transport646, resultHandler648, false); this.req = req; } @@ -5446,17 +5689,17 @@ public ListUsersResp getResult() throws TException { } } - public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler618) throws TException { + public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler652) throws TException { checkReady(); - listRoles_call method_call = new listRoles_call(req, resultHandler618, this, ___protocolFactory, ___transport); + listRoles_call method_call = new listRoles_call(req, resultHandler652, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listRoles_call extends TAsyncMethodCall { private ListRolesReq req; - public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler619, TAsyncClient client615, TProtocolFactory protocolFactory616, TNonblockingTransport transport617) throws TException { - super(client615, protocolFactory616, transport617, resultHandler619, false); + public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler653, TAsyncClient client649, TProtocolFactory protocolFactory650, TNonblockingTransport transport651) throws TException { + super(client649, protocolFactory650, transport651, resultHandler653, false); this.req = req; } @@ -5478,17 +5721,17 @@ public ListRolesResp getResult() throws TException { } } - public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler623) throws TException { + public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler657) throws TException { checkReady(); - getUserRoles_call method_call = new getUserRoles_call(req, resultHandler623, this, ___protocolFactory, ___transport); + getUserRoles_call method_call = new getUserRoles_call(req, resultHandler657, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUserRoles_call extends TAsyncMethodCall { private GetUserRolesReq req; - public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler624, TAsyncClient client620, TProtocolFactory protocolFactory621, TNonblockingTransport transport622) throws TException { - super(client620, protocolFactory621, transport622, resultHandler624, false); + public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler658, TAsyncClient client654, TProtocolFactory protocolFactory655, TNonblockingTransport transport656) throws TException { + super(client654, protocolFactory655, transport656, resultHandler658, false); this.req = req; } @@ -5510,17 +5753,17 @@ public ListRolesResp getResult() throws TException { } } - public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler628) throws TException { + public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler662) throws TException { checkReady(); - changePassword_call method_call = new changePassword_call(req, resultHandler628, this, ___protocolFactory, ___transport); + changePassword_call method_call = new changePassword_call(req, resultHandler662, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class changePassword_call extends TAsyncMethodCall { private ChangePasswordReq req; - public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler629, TAsyncClient client625, TProtocolFactory protocolFactory626, TNonblockingTransport transport627) throws TException { - super(client625, protocolFactory626, transport627, resultHandler629, false); + public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler663, TAsyncClient client659, TProtocolFactory protocolFactory660, TNonblockingTransport transport661) throws TException { + super(client659, protocolFactory660, transport661, resultHandler663, false); this.req = req; } @@ -5542,17 +5785,17 @@ public ExecResp getResult() throws TException { } } - public void heartBeat(HBReq req, AsyncMethodCallback resultHandler633) throws TException { + public void heartBeat(HBReq req, AsyncMethodCallback resultHandler667) throws TException { checkReady(); - heartBeat_call method_call = new heartBeat_call(req, resultHandler633, this, ___protocolFactory, ___transport); + heartBeat_call method_call = new heartBeat_call(req, resultHandler667, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class heartBeat_call extends TAsyncMethodCall { private HBReq req; - public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler634, TAsyncClient client630, TProtocolFactory protocolFactory631, TNonblockingTransport transport632) throws TException { - super(client630, protocolFactory631, transport632, resultHandler634, false); + public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler668, TAsyncClient client664, TProtocolFactory protocolFactory665, TNonblockingTransport transport666) throws TException { + super(client664, protocolFactory665, transport666, resultHandler668, false); this.req = req; } @@ -5574,17 +5817,17 @@ public HBResp getResult() throws TException { } } - public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler638) throws TException { + public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler672) throws TException { checkReady(); - regConfig_call method_call = new regConfig_call(req, resultHandler638, this, ___protocolFactory, ___transport); + regConfig_call method_call = new regConfig_call(req, resultHandler672, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class regConfig_call extends TAsyncMethodCall { private RegConfigReq req; - public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler639, TAsyncClient client635, TProtocolFactory protocolFactory636, TNonblockingTransport transport637) throws TException { - super(client635, protocolFactory636, transport637, resultHandler639, false); + public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler673, TAsyncClient client669, TProtocolFactory protocolFactory670, TNonblockingTransport transport671) throws TException { + super(client669, protocolFactory670, transport671, resultHandler673, false); this.req = req; } @@ -5606,17 +5849,17 @@ public ExecResp getResult() throws TException { } } - public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler643) throws TException { + public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler677) throws TException { checkReady(); - getConfig_call method_call = new getConfig_call(req, resultHandler643, this, ___protocolFactory, ___transport); + getConfig_call method_call = new getConfig_call(req, resultHandler677, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getConfig_call extends TAsyncMethodCall { private GetConfigReq req; - public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler644, TAsyncClient client640, TProtocolFactory protocolFactory641, TNonblockingTransport transport642) throws TException { - super(client640, protocolFactory641, transport642, resultHandler644, false); + public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler678, TAsyncClient client674, TProtocolFactory protocolFactory675, TNonblockingTransport transport676) throws TException { + super(client674, protocolFactory675, transport676, resultHandler678, false); this.req = req; } @@ -5638,17 +5881,17 @@ public GetConfigResp getResult() throws TException { } } - public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler648) throws TException { + public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler682) throws TException { checkReady(); - setConfig_call method_call = new setConfig_call(req, resultHandler648, this, ___protocolFactory, ___transport); + setConfig_call method_call = new setConfig_call(req, resultHandler682, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class setConfig_call extends TAsyncMethodCall { private SetConfigReq req; - public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler649, TAsyncClient client645, TProtocolFactory protocolFactory646, TNonblockingTransport transport647) throws TException { - super(client645, protocolFactory646, transport647, resultHandler649, false); + public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler683, TAsyncClient client679, TProtocolFactory protocolFactory680, TNonblockingTransport transport681) throws TException { + super(client679, protocolFactory680, transport681, resultHandler683, false); this.req = req; } @@ -5670,17 +5913,17 @@ public ExecResp getResult() throws TException { } } - public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler653) throws TException { + public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler687) throws TException { checkReady(); - listConfigs_call method_call = new listConfigs_call(req, resultHandler653, this, ___protocolFactory, ___transport); + listConfigs_call method_call = new listConfigs_call(req, resultHandler687, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listConfigs_call extends TAsyncMethodCall { private ListConfigsReq req; - public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler654, TAsyncClient client650, TProtocolFactory protocolFactory651, TNonblockingTransport transport652) throws TException { - super(client650, protocolFactory651, transport652, resultHandler654, false); + public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler688, TAsyncClient client684, TProtocolFactory protocolFactory685, TNonblockingTransport transport686) throws TException { + super(client684, protocolFactory685, transport686, resultHandler688, false); this.req = req; } @@ -5702,17 +5945,17 @@ public ListConfigsResp getResult() throws TException { } } - public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler658) throws TException { + public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler692) throws TException { checkReady(); - createSnapshot_call method_call = new createSnapshot_call(req, resultHandler658, this, ___protocolFactory, ___transport); + createSnapshot_call method_call = new createSnapshot_call(req, resultHandler692, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSnapshot_call extends TAsyncMethodCall { private CreateSnapshotReq req; - public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler659, TAsyncClient client655, TProtocolFactory protocolFactory656, TNonblockingTransport transport657) throws TException { - super(client655, protocolFactory656, transport657, resultHandler659, false); + public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler693, TAsyncClient client689, TProtocolFactory protocolFactory690, TNonblockingTransport transport691) throws TException { + super(client689, protocolFactory690, transport691, resultHandler693, false); this.req = req; } @@ -5734,17 +5977,17 @@ public ExecResp getResult() throws TException { } } - public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler663) throws TException { + public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler697) throws TException { checkReady(); - dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler663, this, ___protocolFactory, ___transport); + dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler697, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSnapshot_call extends TAsyncMethodCall { private DropSnapshotReq req; - public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler664, TAsyncClient client660, TProtocolFactory protocolFactory661, TNonblockingTransport transport662) throws TException { - super(client660, protocolFactory661, transport662, resultHandler664, false); + public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler698, TAsyncClient client694, TProtocolFactory protocolFactory695, TNonblockingTransport transport696) throws TException { + super(client694, protocolFactory695, transport696, resultHandler698, false); this.req = req; } @@ -5766,17 +6009,17 @@ public ExecResp getResult() throws TException { } } - public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler668) throws TException { + public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler702) throws TException { checkReady(); - listSnapshots_call method_call = new listSnapshots_call(req, resultHandler668, this, ___protocolFactory, ___transport); + listSnapshots_call method_call = new listSnapshots_call(req, resultHandler702, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSnapshots_call extends TAsyncMethodCall { private ListSnapshotsReq req; - public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler669, TAsyncClient client665, TProtocolFactory protocolFactory666, TNonblockingTransport transport667) throws TException { - super(client665, protocolFactory666, transport667, resultHandler669, false); + public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler703, TAsyncClient client699, TProtocolFactory protocolFactory700, TNonblockingTransport transport701) throws TException { + super(client699, protocolFactory700, transport701, resultHandler703, false); this.req = req; } @@ -5798,17 +6041,17 @@ public ListSnapshotsResp getResult() throws TException { } } - public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler673) throws TException { + public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler707) throws TException { checkReady(); - runAdminJob_call method_call = new runAdminJob_call(req, resultHandler673, this, ___protocolFactory, ___transport); + runAdminJob_call method_call = new runAdminJob_call(req, resultHandler707, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class runAdminJob_call extends TAsyncMethodCall { private AdminJobReq req; - public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler674, TAsyncClient client670, TProtocolFactory protocolFactory671, TNonblockingTransport transport672) throws TException { - super(client670, protocolFactory671, transport672, resultHandler674, false); + public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler708, TAsyncClient client704, TProtocolFactory protocolFactory705, TNonblockingTransport transport706) throws TException { + super(client704, protocolFactory705, transport706, resultHandler708, false); this.req = req; } @@ -5830,23 +6073,23 @@ public AdminJobResp getResult() throws TException { } } - public void addZone(AddZoneReq req, AsyncMethodCallback resultHandler678) throws TException { + public void mergeZone(MergeZoneReq req, AsyncMethodCallback resultHandler712) throws TException { checkReady(); - addZone_call method_call = new addZone_call(req, resultHandler678, this, ___protocolFactory, ___transport); + mergeZone_call method_call = new mergeZone_call(req, resultHandler712, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class addZone_call extends TAsyncMethodCall { - private AddZoneReq req; - public addZone_call(AddZoneReq req, AsyncMethodCallback resultHandler679, TAsyncClient client675, TProtocolFactory protocolFactory676, TNonblockingTransport transport677) throws TException { - super(client675, protocolFactory676, transport677, resultHandler679, false); + public static class mergeZone_call extends TAsyncMethodCall { + private MergeZoneReq req; + public mergeZone_call(MergeZoneReq req, AsyncMethodCallback resultHandler713, TAsyncClient client709, TProtocolFactory protocolFactory710, TNonblockingTransport transport711) throws TException { + super(client709, protocolFactory710, transport711, resultHandler713, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("addZone", TMessageType.CALL, 0)); - addZone_args args = new addZone_args(); + prot.writeMessageBegin(new TMessage("mergeZone", TMessageType.CALL, 0)); + mergeZone_args args = new mergeZone_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); @@ -5858,21 +6101,21 @@ public ExecResp getResult() throws TException { } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_addZone(); + return (new Client(prot)).recv_mergeZone(); } } - public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler683) throws TException { + public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler717) throws TException { checkReady(); - dropZone_call method_call = new dropZone_call(req, resultHandler683, this, ___protocolFactory, ___transport); + dropZone_call method_call = new dropZone_call(req, resultHandler717, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropZone_call extends TAsyncMethodCall { private DropZoneReq req; - public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler684, TAsyncClient client680, TProtocolFactory protocolFactory681, TNonblockingTransport transport682) throws TException { - super(client680, protocolFactory681, transport682, resultHandler684, false); + public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler718, TAsyncClient client714, TProtocolFactory protocolFactory715, TNonblockingTransport transport716) throws TException { + super(client714, protocolFactory715, transport716, resultHandler718, false); this.req = req; } @@ -5894,23 +6137,23 @@ public ExecResp getResult() throws TException { } } - public void addHostIntoZone(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler688) throws TException { + public void splitZone(SplitZoneReq req, AsyncMethodCallback resultHandler722) throws TException { checkReady(); - addHostIntoZone_call method_call = new addHostIntoZone_call(req, resultHandler688, this, ___protocolFactory, ___transport); + splitZone_call method_call = new splitZone_call(req, resultHandler722, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class addHostIntoZone_call extends TAsyncMethodCall { - private AddHostIntoZoneReq req; - public addHostIntoZone_call(AddHostIntoZoneReq req, AsyncMethodCallback resultHandler689, TAsyncClient client685, TProtocolFactory protocolFactory686, TNonblockingTransport transport687) throws TException { - super(client685, protocolFactory686, transport687, resultHandler689, false); + public static class splitZone_call extends TAsyncMethodCall { + private SplitZoneReq req; + public splitZone_call(SplitZoneReq req, AsyncMethodCallback resultHandler723, TAsyncClient client719, TProtocolFactory protocolFactory720, TNonblockingTransport transport721) throws TException { + super(client719, protocolFactory720, transport721, resultHandler723, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("addHostIntoZone", TMessageType.CALL, 0)); - addHostIntoZone_args args = new addHostIntoZone_args(); + prot.writeMessageBegin(new TMessage("splitZone", TMessageType.CALL, 0)); + splitZone_args args = new splitZone_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); @@ -5922,27 +6165,27 @@ public ExecResp getResult() throws TException { } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_addHostIntoZone(); + return (new Client(prot)).recv_splitZone(); } } - public void dropHostFromZone(DropHostFromZoneReq req, AsyncMethodCallback resultHandler693) throws TException { + public void renameZone(RenameZoneReq req, AsyncMethodCallback resultHandler727) throws TException { checkReady(); - dropHostFromZone_call method_call = new dropHostFromZone_call(req, resultHandler693, this, ___protocolFactory, ___transport); + renameZone_call method_call = new renameZone_call(req, resultHandler727, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } - public static class dropHostFromZone_call extends TAsyncMethodCall { - private DropHostFromZoneReq req; - public dropHostFromZone_call(DropHostFromZoneReq req, AsyncMethodCallback resultHandler694, TAsyncClient client690, TProtocolFactory protocolFactory691, TNonblockingTransport transport692) throws TException { - super(client690, protocolFactory691, transport692, resultHandler694, false); + public static class renameZone_call extends TAsyncMethodCall { + private RenameZoneReq req; + public renameZone_call(RenameZoneReq req, AsyncMethodCallback resultHandler728, TAsyncClient client724, TProtocolFactory protocolFactory725, TNonblockingTransport transport726) throws TException { + super(client724, protocolFactory725, transport726, resultHandler728, false); this.req = req; } public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("dropHostFromZone", TMessageType.CALL, 0)); - dropHostFromZone_args args = new dropHostFromZone_args(); + prot.writeMessageBegin(new TMessage("renameZone", TMessageType.CALL, 0)); + renameZone_args args = new renameZone_args(); args.setReq(req); args.write(prot); prot.writeMessageEnd(); @@ -5954,21 +6197,21 @@ public ExecResp getResult() throws TException { } TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_dropHostFromZone(); + return (new Client(prot)).recv_renameZone(); } } - public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler698) throws TException { + public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler732) throws TException { checkReady(); - getZone_call method_call = new getZone_call(req, resultHandler698, this, ___protocolFactory, ___transport); + getZone_call method_call = new getZone_call(req, resultHandler732, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getZone_call extends TAsyncMethodCall { private GetZoneReq req; - public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler699, TAsyncClient client695, TProtocolFactory protocolFactory696, TNonblockingTransport transport697) throws TException { - super(client695, protocolFactory696, transport697, resultHandler699, false); + public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler733, TAsyncClient client729, TProtocolFactory protocolFactory730, TNonblockingTransport transport731) throws TException { + super(client729, protocolFactory730, transport731, resultHandler733, false); this.req = req; } @@ -5990,17 +6233,17 @@ public GetZoneResp getResult() throws TException { } } - public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler703) throws TException { + public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler737) throws TException { checkReady(); - listZones_call method_call = new listZones_call(req, resultHandler703, this, ___protocolFactory, ___transport); + listZones_call method_call = new listZones_call(req, resultHandler737, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listZones_call extends TAsyncMethodCall { private ListZonesReq req; - public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler704, TAsyncClient client700, TProtocolFactory protocolFactory701, TNonblockingTransport transport702) throws TException { - super(client700, protocolFactory701, transport702, resultHandler704, false); + public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler738, TAsyncClient client734, TProtocolFactory protocolFactory735, TNonblockingTransport transport736) throws TException { + super(client734, protocolFactory735, transport736, resultHandler738, false); this.req = req; } @@ -6022,17 +6265,17 @@ public ListZonesResp getResult() throws TException { } } - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler708) throws TException { + public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler742) throws TException { checkReady(); - createBackup_call method_call = new createBackup_call(req, resultHandler708, this, ___protocolFactory, ___transport); + createBackup_call method_call = new createBackup_call(req, resultHandler742, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createBackup_call extends TAsyncMethodCall { private CreateBackupReq req; - public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler709, TAsyncClient client705, TProtocolFactory protocolFactory706, TNonblockingTransport transport707) throws TException { - super(client705, protocolFactory706, transport707, resultHandler709, false); + public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler743, TAsyncClient client739, TProtocolFactory protocolFactory740, TNonblockingTransport transport741) throws TException { + super(client739, protocolFactory740, transport741, resultHandler743, false); this.req = req; } @@ -6054,17 +6297,17 @@ public CreateBackupResp getResult() throws TException { } } - public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler713) throws TException { + public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler747) throws TException { checkReady(); - restoreMeta_call method_call = new restoreMeta_call(req, resultHandler713, this, ___protocolFactory, ___transport); + restoreMeta_call method_call = new restoreMeta_call(req, resultHandler747, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class restoreMeta_call extends TAsyncMethodCall { private RestoreMetaReq req; - public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler714, TAsyncClient client710, TProtocolFactory protocolFactory711, TNonblockingTransport transport712) throws TException { - super(client710, protocolFactory711, transport712, resultHandler714, false); + public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler748, TAsyncClient client744, TProtocolFactory protocolFactory745, TNonblockingTransport transport746) throws TException { + super(client744, protocolFactory745, transport746, resultHandler748, false); this.req = req; } @@ -6086,17 +6329,17 @@ public ExecResp getResult() throws TException { } } - public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler718) throws TException { + public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler752) throws TException { checkReady(); - addListener_call method_call = new addListener_call(req, resultHandler718, this, ___protocolFactory, ___transport); + addListener_call method_call = new addListener_call(req, resultHandler752, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addListener_call extends TAsyncMethodCall { private AddListenerReq req; - public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler719, TAsyncClient client715, TProtocolFactory protocolFactory716, TNonblockingTransport transport717) throws TException { - super(client715, protocolFactory716, transport717, resultHandler719, false); + public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler753, TAsyncClient client749, TProtocolFactory protocolFactory750, TNonblockingTransport transport751) throws TException { + super(client749, protocolFactory750, transport751, resultHandler753, false); this.req = req; } @@ -6118,17 +6361,17 @@ public ExecResp getResult() throws TException { } } - public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler723) throws TException { + public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler757) throws TException { checkReady(); - removeListener_call method_call = new removeListener_call(req, resultHandler723, this, ___protocolFactory, ___transport); + removeListener_call method_call = new removeListener_call(req, resultHandler757, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeListener_call extends TAsyncMethodCall { private RemoveListenerReq req; - public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler724, TAsyncClient client720, TProtocolFactory protocolFactory721, TNonblockingTransport transport722) throws TException { - super(client720, protocolFactory721, transport722, resultHandler724, false); + public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler758, TAsyncClient client754, TProtocolFactory protocolFactory755, TNonblockingTransport transport756) throws TException { + super(client754, protocolFactory755, transport756, resultHandler758, false); this.req = req; } @@ -6150,17 +6393,17 @@ public ExecResp getResult() throws TException { } } - public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler728) throws TException { + public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler762) throws TException { checkReady(); - listListener_call method_call = new listListener_call(req, resultHandler728, this, ___protocolFactory, ___transport); + listListener_call method_call = new listListener_call(req, resultHandler762, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listListener_call extends TAsyncMethodCall { private ListListenerReq req; - public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler729, TAsyncClient client725, TProtocolFactory protocolFactory726, TNonblockingTransport transport727) throws TException { - super(client725, protocolFactory726, transport727, resultHandler729, false); + public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler763, TAsyncClient client759, TProtocolFactory protocolFactory760, TNonblockingTransport transport761) throws TException { + super(client759, protocolFactory760, transport761, resultHandler763, false); this.req = req; } @@ -6182,17 +6425,17 @@ public ListListenerResp getResult() throws TException { } } - public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler733) throws TException { + public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler767) throws TException { checkReady(); - getStats_call method_call = new getStats_call(req, resultHandler733, this, ___protocolFactory, ___transport); + getStats_call method_call = new getStats_call(req, resultHandler767, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getStats_call extends TAsyncMethodCall { private GetStatsReq req; - public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler734, TAsyncClient client730, TProtocolFactory protocolFactory731, TNonblockingTransport transport732) throws TException { - super(client730, protocolFactory731, transport732, resultHandler734, false); + public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler768, TAsyncClient client764, TProtocolFactory protocolFactory765, TNonblockingTransport transport766) throws TException { + super(client764, protocolFactory765, transport766, resultHandler768, false); this.req = req; } @@ -6214,17 +6457,17 @@ public GetStatsResp getResult() throws TException { } } - public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler738) throws TException { + public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler772) throws TException { checkReady(); - signInFTService_call method_call = new signInFTService_call(req, resultHandler738, this, ___protocolFactory, ___transport); + signInFTService_call method_call = new signInFTService_call(req, resultHandler772, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signInFTService_call extends TAsyncMethodCall { private SignInFTServiceReq req; - public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler739, TAsyncClient client735, TProtocolFactory protocolFactory736, TNonblockingTransport transport737) throws TException { - super(client735, protocolFactory736, transport737, resultHandler739, false); + public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler773, TAsyncClient client769, TProtocolFactory protocolFactory770, TNonblockingTransport transport771) throws TException { + super(client769, protocolFactory770, transport771, resultHandler773, false); this.req = req; } @@ -6246,17 +6489,17 @@ public ExecResp getResult() throws TException { } } - public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler743) throws TException { + public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler777) throws TException { checkReady(); - signOutFTService_call method_call = new signOutFTService_call(req, resultHandler743, this, ___protocolFactory, ___transport); + signOutFTService_call method_call = new signOutFTService_call(req, resultHandler777, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signOutFTService_call extends TAsyncMethodCall { private SignOutFTServiceReq req; - public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler744, TAsyncClient client740, TProtocolFactory protocolFactory741, TNonblockingTransport transport742) throws TException { - super(client740, protocolFactory741, transport742, resultHandler744, false); + public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler778, TAsyncClient client774, TProtocolFactory protocolFactory775, TNonblockingTransport transport776) throws TException { + super(client774, protocolFactory775, transport776, resultHandler778, false); this.req = req; } @@ -6278,17 +6521,17 @@ public ExecResp getResult() throws TException { } } - public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler748) throws TException { + public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler782) throws TException { checkReady(); - listFTClients_call method_call = new listFTClients_call(req, resultHandler748, this, ___protocolFactory, ___transport); + listFTClients_call method_call = new listFTClients_call(req, resultHandler782, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTClients_call extends TAsyncMethodCall { private ListFTClientsReq req; - public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler749, TAsyncClient client745, TProtocolFactory protocolFactory746, TNonblockingTransport transport747) throws TException { - super(client745, protocolFactory746, transport747, resultHandler749, false); + public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler783, TAsyncClient client779, TProtocolFactory protocolFactory780, TNonblockingTransport transport781) throws TException { + super(client779, protocolFactory780, transport781, resultHandler783, false); this.req = req; } @@ -6310,17 +6553,17 @@ public ListFTClientsResp getResult() throws TException { } } - public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler753) throws TException { + public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler787) throws TException { checkReady(); - createFTIndex_call method_call = new createFTIndex_call(req, resultHandler753, this, ___protocolFactory, ___transport); + createFTIndex_call method_call = new createFTIndex_call(req, resultHandler787, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createFTIndex_call extends TAsyncMethodCall { private CreateFTIndexReq req; - public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler754, TAsyncClient client750, TProtocolFactory protocolFactory751, TNonblockingTransport transport752) throws TException { - super(client750, protocolFactory751, transport752, resultHandler754, false); + public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler788, TAsyncClient client784, TProtocolFactory protocolFactory785, TNonblockingTransport transport786) throws TException { + super(client784, protocolFactory785, transport786, resultHandler788, false); this.req = req; } @@ -6342,17 +6585,17 @@ public ExecResp getResult() throws TException { } } - public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler758) throws TException { + public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler792) throws TException { checkReady(); - dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler758, this, ___protocolFactory, ___transport); + dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler792, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropFTIndex_call extends TAsyncMethodCall { private DropFTIndexReq req; - public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler759, TAsyncClient client755, TProtocolFactory protocolFactory756, TNonblockingTransport transport757) throws TException { - super(client755, protocolFactory756, transport757, resultHandler759, false); + public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler793, TAsyncClient client789, TProtocolFactory protocolFactory790, TNonblockingTransport transport791) throws TException { + super(client789, protocolFactory790, transport791, resultHandler793, false); this.req = req; } @@ -6374,17 +6617,17 @@ public ExecResp getResult() throws TException { } } - public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler763) throws TException { + public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler797) throws TException { checkReady(); - listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler763, this, ___protocolFactory, ___transport); + listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler797, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTIndexes_call extends TAsyncMethodCall { private ListFTIndexesReq req; - public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler764, TAsyncClient client760, TProtocolFactory protocolFactory761, TNonblockingTransport transport762) throws TException { - super(client760, protocolFactory761, transport762, resultHandler764, false); + public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler798, TAsyncClient client794, TProtocolFactory protocolFactory795, TNonblockingTransport transport796) throws TException { + super(client794, protocolFactory795, transport796, resultHandler798, false); this.req = req; } @@ -6406,17 +6649,17 @@ public ListFTIndexesResp getResult() throws TException { } } - public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler768) throws TException { + public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler802) throws TException { checkReady(); - createSession_call method_call = new createSession_call(req, resultHandler768, this, ___protocolFactory, ___transport); + createSession_call method_call = new createSession_call(req, resultHandler802, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSession_call extends TAsyncMethodCall { private CreateSessionReq req; - public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler769, TAsyncClient client765, TProtocolFactory protocolFactory766, TNonblockingTransport transport767) throws TException { - super(client765, protocolFactory766, transport767, resultHandler769, false); + public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler803, TAsyncClient client799, TProtocolFactory protocolFactory800, TNonblockingTransport transport801) throws TException { + super(client799, protocolFactory800, transport801, resultHandler803, false); this.req = req; } @@ -6438,17 +6681,17 @@ public CreateSessionResp getResult() throws TException { } } - public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler773) throws TException { + public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler807) throws TException { checkReady(); - updateSessions_call method_call = new updateSessions_call(req, resultHandler773, this, ___protocolFactory, ___transport); + updateSessions_call method_call = new updateSessions_call(req, resultHandler807, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateSessions_call extends TAsyncMethodCall { private UpdateSessionsReq req; - public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler774, TAsyncClient client770, TProtocolFactory protocolFactory771, TNonblockingTransport transport772) throws TException { - super(client770, protocolFactory771, transport772, resultHandler774, false); + public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler808, TAsyncClient client804, TProtocolFactory protocolFactory805, TNonblockingTransport transport806) throws TException { + super(client804, protocolFactory805, transport806, resultHandler808, false); this.req = req; } @@ -6470,17 +6713,17 @@ public UpdateSessionsResp getResult() throws TException { } } - public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler778) throws TException { + public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler812) throws TException { checkReady(); - listSessions_call method_call = new listSessions_call(req, resultHandler778, this, ___protocolFactory, ___transport); + listSessions_call method_call = new listSessions_call(req, resultHandler812, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSessions_call extends TAsyncMethodCall { private ListSessionsReq req; - public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler779, TAsyncClient client775, TProtocolFactory protocolFactory776, TNonblockingTransport transport777) throws TException { - super(client775, protocolFactory776, transport777, resultHandler779, false); + public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler813, TAsyncClient client809, TProtocolFactory protocolFactory810, TNonblockingTransport transport811) throws TException { + super(client809, protocolFactory810, transport811, resultHandler813, false); this.req = req; } @@ -6502,17 +6745,17 @@ public ListSessionsResp getResult() throws TException { } } - public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler783) throws TException { + public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler817) throws TException { checkReady(); - getSession_call method_call = new getSession_call(req, resultHandler783, this, ___protocolFactory, ___transport); + getSession_call method_call = new getSession_call(req, resultHandler817, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSession_call extends TAsyncMethodCall { private GetSessionReq req; - public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler784, TAsyncClient client780, TProtocolFactory protocolFactory781, TNonblockingTransport transport782) throws TException { - super(client780, protocolFactory781, transport782, resultHandler784, false); + public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler818, TAsyncClient client814, TProtocolFactory protocolFactory815, TNonblockingTransport transport816) throws TException { + super(client814, protocolFactory815, transport816, resultHandler818, false); this.req = req; } @@ -6534,17 +6777,17 @@ public GetSessionResp getResult() throws TException { } } - public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler788) throws TException { + public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler822) throws TException { checkReady(); - removeSession_call method_call = new removeSession_call(req, resultHandler788, this, ___protocolFactory, ___transport); + removeSession_call method_call = new removeSession_call(req, resultHandler822, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeSession_call extends TAsyncMethodCall { private RemoveSessionReq req; - public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler789, TAsyncClient client785, TProtocolFactory protocolFactory786, TNonblockingTransport transport787) throws TException { - super(client785, protocolFactory786, transport787, resultHandler789, false); + public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler823, TAsyncClient client819, TProtocolFactory protocolFactory820, TNonblockingTransport transport821) throws TException { + super(client819, protocolFactory820, transport821, resultHandler823, false); this.req = req; } @@ -6566,17 +6809,17 @@ public ExecResp getResult() throws TException { } } - public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler793) throws TException { + public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler827) throws TException { checkReady(); - killQuery_call method_call = new killQuery_call(req, resultHandler793, this, ___protocolFactory, ___transport); + killQuery_call method_call = new killQuery_call(req, resultHandler827, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class killQuery_call extends TAsyncMethodCall { private KillQueryReq req; - public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler794, TAsyncClient client790, TProtocolFactory protocolFactory791, TNonblockingTransport transport792) throws TException { - super(client790, protocolFactory791, transport792, resultHandler794, false); + public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler828, TAsyncClient client824, TProtocolFactory protocolFactory825, TNonblockingTransport transport826) throws TException { + super(client824, protocolFactory825, transport826, resultHandler828, false); this.req = req; } @@ -6598,17 +6841,17 @@ public ExecResp getResult() throws TException { } } - public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler798) throws TException { + public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler832) throws TException { checkReady(); - reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler798, this, ___protocolFactory, ___transport); + reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler832, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class reportTaskFinish_call extends TAsyncMethodCall { private ReportTaskReq req; - public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler799, TAsyncClient client795, TProtocolFactory protocolFactory796, TNonblockingTransport transport797) throws TException { - super(client795, protocolFactory796, transport797, resultHandler799, false); + public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler833, TAsyncClient client829, TProtocolFactory protocolFactory830, TNonblockingTransport transport831) throws TException { + super(client829, protocolFactory830, transport831, resultHandler833, false); this.req = req; } @@ -6630,17 +6873,17 @@ public ExecResp getResult() throws TException { } } - public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler803) throws TException { + public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler837) throws TException { checkReady(); - listCluster_call method_call = new listCluster_call(req, resultHandler803, this, ___protocolFactory, ___transport); + listCluster_call method_call = new listCluster_call(req, resultHandler837, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listCluster_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler804, TAsyncClient client800, TProtocolFactory protocolFactory801, TNonblockingTransport transport802) throws TException { - super(client800, protocolFactory801, transport802, resultHandler804, false); + public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler838, TAsyncClient client834, TProtocolFactory protocolFactory835, TNonblockingTransport transport836) throws TException { + super(client834, protocolFactory835, transport836, resultHandler838, false); this.req = req; } @@ -6662,17 +6905,17 @@ public ListClusterInfoResp getResult() throws TException { } } - public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler808) throws TException { + public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler842) throws TException { checkReady(); - getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler808, this, ___protocolFactory, ___transport); + getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler842, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getMetaDirInfo_call extends TAsyncMethodCall { private GetMetaDirInfoReq req; - public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler809, TAsyncClient client805, TProtocolFactory protocolFactory806, TNonblockingTransport transport807) throws TException { - super(client805, protocolFactory806, transport807, resultHandler809, false); + public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler843, TAsyncClient client839, TProtocolFactory protocolFactory840, TNonblockingTransport transport841) throws TException { + super(client839, protocolFactory840, transport841, resultHandler843, false); this.req = req; } @@ -6694,17 +6937,17 @@ public GetMetaDirInfoResp getResult() throws TException { } } - public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler813) throws TException { + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler847) throws TException { checkReady(); - verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler813, this, ___protocolFactory, ___transport); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler847, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class verifyClientVersion_call extends TAsyncMethodCall { private VerifyClientVersionReq req; - public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler814, TAsyncClient client810, TProtocolFactory protocolFactory811, TNonblockingTransport transport812) throws TException { - super(client810, protocolFactory811, transport812, resultHandler814, false); + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler848, TAsyncClient client844, TProtocolFactory protocolFactory845, TNonblockingTransport transport846) throws TException { + super(client844, protocolFactory845, transport846, resultHandler848, false); this.req = req; } @@ -6749,6 +6992,9 @@ public Processor(Iface iface) processMap_.put("dropEdge", new dropEdge()); processMap_.put("getEdge", new getEdge()); processMap_.put("listEdges", new listEdges()); + processMap_.put("addHosts", new addHosts()); + processMap_.put("addHostsIntoZone", new addHostsIntoZone()); + processMap_.put("dropHosts", new dropHosts()); processMap_.put("listHosts", new listHosts()); processMap_.put("getPartsAlloc", new getPartsAlloc()); processMap_.put("listParts", new listParts()); @@ -6788,10 +7034,10 @@ public Processor(Iface iface) processMap_.put("dropSnapshot", new dropSnapshot()); processMap_.put("listSnapshots", new listSnapshots()); processMap_.put("runAdminJob", new runAdminJob()); - processMap_.put("addZone", new addZone()); + processMap_.put("mergeZone", new mergeZone()); processMap_.put("dropZone", new dropZone()); - processMap_.put("addHostIntoZone", new addHostIntoZone()); - processMap_.put("dropHostFromZone", new dropHostFromZone()); + processMap_.put("splitZone", new splitZone()); + processMap_.put("renameZone", new renameZone()); processMap_.put("getZone", new getZone()); processMap_.put("listZones", new listZones()); processMap_.put("createBackup", new createBackup()); @@ -7163,6 +7409,69 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class addHosts implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.addHosts", server_ctx); + addHosts_args args = new addHosts_args(); + event_handler_.preRead(handler_ctx, "MetaService.addHosts"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.addHosts", args); + addHosts_result result = new addHosts_result(); + result.success = iface_.addHosts(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.addHosts", result); + oprot.writeMessageBegin(new TMessage("addHosts", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.addHosts", result); + } + + } + + private class addHostsIntoZone implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.addHostsIntoZone", server_ctx); + addHostsIntoZone_args args = new addHostsIntoZone_args(); + event_handler_.preRead(handler_ctx, "MetaService.addHostsIntoZone"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.addHostsIntoZone", args); + addHostsIntoZone_result result = new addHostsIntoZone_result(); + result.success = iface_.addHostsIntoZone(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.addHostsIntoZone", result); + oprot.writeMessageBegin(new TMessage("addHostsIntoZone", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.addHostsIntoZone", result); + } + + } + + private class dropHosts implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.dropHosts", server_ctx); + dropHosts_args args = new dropHosts_args(); + event_handler_.preRead(handler_ctx, "MetaService.dropHosts"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.dropHosts", args); + dropHosts_result result = new dropHosts_result(); + result.success = iface_.dropHosts(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.dropHosts", result); + oprot.writeMessageBegin(new TMessage("dropHosts", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.dropHosts", result); + } + + } + private class listHosts implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -7982,23 +8291,23 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class addZone implements ProcessFunction { + private class mergeZone implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("MetaService.addZone", server_ctx); - addZone_args args = new addZone_args(); - event_handler_.preRead(handler_ctx, "MetaService.addZone"); + Object handler_ctx = event_handler_.getContext("MetaService.mergeZone", server_ctx); + mergeZone_args args = new mergeZone_args(); + event_handler_.preRead(handler_ctx, "MetaService.mergeZone"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.addZone", args); - addZone_result result = new addZone_result(); - result.success = iface_.addZone(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.addZone", result); - oprot.writeMessageBegin(new TMessage("addZone", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "MetaService.mergeZone", args); + mergeZone_result result = new mergeZone_result(); + result.success = iface_.mergeZone(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.mergeZone", result); + oprot.writeMessageBegin(new TMessage("mergeZone", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.addZone", result); + event_handler_.postWrite(handler_ctx, "MetaService.mergeZone", result); } } @@ -8024,44 +8333,44 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class addHostIntoZone implements ProcessFunction { + private class splitZone implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("MetaService.addHostIntoZone", server_ctx); - addHostIntoZone_args args = new addHostIntoZone_args(); - event_handler_.preRead(handler_ctx, "MetaService.addHostIntoZone"); + Object handler_ctx = event_handler_.getContext("MetaService.splitZone", server_ctx); + splitZone_args args = new splitZone_args(); + event_handler_.preRead(handler_ctx, "MetaService.splitZone"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.addHostIntoZone", args); - addHostIntoZone_result result = new addHostIntoZone_result(); - result.success = iface_.addHostIntoZone(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.addHostIntoZone", result); - oprot.writeMessageBegin(new TMessage("addHostIntoZone", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "MetaService.splitZone", args); + splitZone_result result = new splitZone_result(); + result.success = iface_.splitZone(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.splitZone", result); + oprot.writeMessageBegin(new TMessage("splitZone", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.addHostIntoZone", result); + event_handler_.postWrite(handler_ctx, "MetaService.splitZone", result); } } - private class dropHostFromZone implements ProcessFunction { + private class renameZone implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { - Object handler_ctx = event_handler_.getContext("MetaService.dropHostFromZone", server_ctx); - dropHostFromZone_args args = new dropHostFromZone_args(); - event_handler_.preRead(handler_ctx, "MetaService.dropHostFromZone"); + Object handler_ctx = event_handler_.getContext("MetaService.renameZone", server_ctx); + renameZone_args args = new renameZone_args(); + event_handler_.preRead(handler_ctx, "MetaService.renameZone"); args.read(iprot); iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.dropHostFromZone", args); - dropHostFromZone_result result = new dropHostFromZone_result(); - result.success = iface_.dropHostFromZone(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.dropHostFromZone", result); - oprot.writeMessageBegin(new TMessage("dropHostFromZone", TMessageType.REPLY, seqid)); + event_handler_.postRead(handler_ctx, "MetaService.renameZone", args); + renameZone_result result = new renameZone_result(); + result.success = iface_.renameZone(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.renameZone", result); + oprot.writeMessageBegin(new TMessage("renameZone", TMessageType.REPLY, seqid)); result.write(oprot); oprot.writeMessageEnd(); oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.dropHostFromZone", result); + event_handler_.postWrite(handler_ctx, "MetaService.renameZone", result); } } @@ -9759,9 +10068,1314 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getSpace_result)) + if (!(_that instanceof getSpace_result)) + return false; + getSpace_result that = (getSpace_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(getSpace_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new GetSpaceResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("getSpace_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class listSpaces_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSpaces_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public ListSpacesReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ListSpacesReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(listSpaces_args.class, metaDataMap); + } + + public listSpaces_args() { + } + + public listSpaces_args( + ListSpacesReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public listSpaces_args(listSpaces_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public listSpaces_args deepCopy() { + return new listSpaces_args(this); + } + + public ListSpacesReq getReq() { + return this.req; + } + + public listSpaces_args setReq(ListSpacesReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((ListSpacesReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof listSpaces_args)) + return false; + listSpaces_args that = (listSpaces_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(listSpaces_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new ListSpacesReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("listSpaces_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class listSpaces_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSpaces_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ListSpacesResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ListSpacesResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(listSpaces_result.class, metaDataMap); + } + + public listSpaces_result() { + } + + public listSpaces_result( + ListSpacesResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public listSpaces_result(listSpaces_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public listSpaces_result deepCopy() { + return new listSpaces_result(this); + } + + public ListSpacesResp getSuccess() { + return this.success; + } + + public listSpaces_result setSuccess(ListSpacesResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ListSpacesResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof listSpaces_result)) + return false; + listSpaces_result that = (listSpaces_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(listSpaces_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ListSpacesResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("listSpaces_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class createSpaceAs_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public CreateSpaceAsReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, CreateSpaceAsReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(createSpaceAs_args.class, metaDataMap); + } + + public createSpaceAs_args() { + } + + public createSpaceAs_args( + CreateSpaceAsReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public createSpaceAs_args(createSpaceAs_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public createSpaceAs_args deepCopy() { + return new createSpaceAs_args(this); + } + + public CreateSpaceAsReq getReq() { + return this.req; + } + + public createSpaceAs_args setReq(CreateSpaceAsReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((CreateSpaceAsReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof createSpaceAs_args)) + return false; + createSpaceAs_args that = (createSpaceAs_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(createSpaceAs_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new CreateSpaceAsReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("createSpaceAs_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class createSpaceAs_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ExecResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ExecResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(createSpaceAs_result.class, metaDataMap); + } + + public createSpaceAs_result() { + } + + public createSpaceAs_result( + ExecResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public createSpaceAs_result(createSpaceAs_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public createSpaceAs_result deepCopy() { + return new createSpaceAs_result(this); + } + + public ExecResp getSuccess() { + return this.success; + } + + public createSpaceAs_result setSuccess(ExecResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ExecResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof createSpaceAs_result)) + return false; + createSpaceAs_result that = (createSpaceAs_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(createSpaceAs_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ExecResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("createSpaceAs_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class createTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTag_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public CreateTagReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, CreateTagReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(createTag_args.class, metaDataMap); + } + + public createTag_args() { + } + + public createTag_args( + CreateTagReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public createTag_args(createTag_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public createTag_args deepCopy() { + return new createTag_args(this); + } + + public CreateTagReq getReq() { + return this.req; + } + + public createTag_args setReq(CreateTagReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((CreateTagReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof createTag_args)) + return false; + createTag_args that = (createTag_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(createTag_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new CreateTagReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("createTag_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class createTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTag_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ExecResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ExecResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(createTag_result.class, metaDataMap); + } + + public createTag_result() { + } + + public createTag_result( + ExecResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public createTag_result(createTag_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public createTag_result deepCopy() { + return new createTag_result(this); + } + + public ExecResp getSuccess() { + return this.success; + } + + public createTag_result setSuccess(ExecResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ExecResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof createTag_result)) return false; - getSpace_result that = (getSpace_result)_that; + createTag_result that = (createTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -9774,7 +11388,7 @@ public int hashCode() { } @Override - public int compareTo(getSpace_result other) { + public int compareTo(createTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -9809,7 +11423,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetSpaceResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -9850,7 +11464,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getSpace_result"); + StringBuilder sb = new StringBuilder("createTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9877,11 +11491,11 @@ public void validate() throws TException { } - public static class listSpaces_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSpaces_args"); + public static class alterTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListSpacesReq req; + public AlterTagReq req; public static final int REQ = 1; // isset id assignments @@ -9891,19 +11505,19 @@ public static class listSpaces_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSpacesReq.class))); + new StructMetaData(TType.STRUCT, AlterTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSpaces_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterTag_args.class, metaDataMap); } - public listSpaces_args() { + public alterTag_args() { } - public listSpaces_args( - ListSpacesReq req) { + public alterTag_args( + AlterTagReq req) { this(); this.req = req; } @@ -9911,21 +11525,21 @@ public listSpaces_args( /** * Performs a deep copy on other. */ - public listSpaces_args(listSpaces_args other) { + public alterTag_args(alterTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listSpaces_args deepCopy() { - return new listSpaces_args(this); + public alterTag_args deepCopy() { + return new alterTag_args(this); } - public ListSpacesReq getReq() { + public AlterTagReq getReq() { return this.req; } - public listSpaces_args setReq(ListSpacesReq req) { + public alterTag_args setReq(AlterTagReq req) { this.req = req; return this; } @@ -9951,7 +11565,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListSpacesReq)__value); + setReq((AlterTagReq)__value); } break; @@ -9976,9 +11590,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSpaces_args)) + if (!(_that instanceof alterTag_args)) return false; - listSpaces_args that = (listSpaces_args)_that; + alterTag_args that = (alterTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -9991,7 +11605,7 @@ public int hashCode() { } @Override - public int compareTo(listSpaces_args other) { + public int compareTo(alterTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10026,7 +11640,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListSpacesReq(); + this.req = new AlterTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10068,7 +11682,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSpaces_args"); + StringBuilder sb = new StringBuilder("alterTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10095,11 +11709,11 @@ public void validate() throws TException { } - public static class listSpaces_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSpaces_result"); + public static class alterTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListSpacesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -10109,19 +11723,19 @@ public static class listSpaces_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSpacesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSpaces_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterTag_result.class, metaDataMap); } - public listSpaces_result() { + public alterTag_result() { } - public listSpaces_result( - ListSpacesResp success) { + public alterTag_result( + ExecResp success) { this(); this.success = success; } @@ -10129,21 +11743,21 @@ public listSpaces_result( /** * Performs a deep copy on other. */ - public listSpaces_result(listSpaces_result other) { + public alterTag_result(alterTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listSpaces_result deepCopy() { - return new listSpaces_result(this); + public alterTag_result deepCopy() { + return new alterTag_result(this); } - public ListSpacesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listSpaces_result setSuccess(ListSpacesResp success) { + public alterTag_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -10169,7 +11783,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListSpacesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -10194,9 +11808,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSpaces_result)) + if (!(_that instanceof alterTag_result)) return false; - listSpaces_result that = (listSpaces_result)_that; + alterTag_result that = (alterTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -10209,7 +11823,7 @@ public int hashCode() { } @Override - public int compareTo(listSpaces_result other) { + public int compareTo(alterTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10244,7 +11858,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListSpacesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10285,7 +11899,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSpaces_result"); + StringBuilder sb = new StringBuilder("alterTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10312,11 +11926,11 @@ public void validate() throws TException { } - public static class createSpaceAs_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_args"); + public static class dropTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateSpaceAsReq req; + public DropTagReq req; public static final int REQ = 1; // isset id assignments @@ -10326,19 +11940,19 @@ public static class createSpaceAs_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateSpaceAsReq.class))); + new StructMetaData(TType.STRUCT, DropTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSpaceAs_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTag_args.class, metaDataMap); } - public createSpaceAs_args() { + public dropTag_args() { } - public createSpaceAs_args( - CreateSpaceAsReq req) { + public dropTag_args( + DropTagReq req) { this(); this.req = req; } @@ -10346,21 +11960,21 @@ public createSpaceAs_args( /** * Performs a deep copy on other. */ - public createSpaceAs_args(createSpaceAs_args other) { + public dropTag_args(dropTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createSpaceAs_args deepCopy() { - return new createSpaceAs_args(this); + public dropTag_args deepCopy() { + return new dropTag_args(this); } - public CreateSpaceAsReq getReq() { + public DropTagReq getReq() { return this.req; } - public createSpaceAs_args setReq(CreateSpaceAsReq req) { + public dropTag_args setReq(DropTagReq req) { this.req = req; return this; } @@ -10386,7 +12000,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateSpaceAsReq)__value); + setReq((DropTagReq)__value); } break; @@ -10411,9 +12025,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSpaceAs_args)) + if (!(_that instanceof dropTag_args)) return false; - createSpaceAs_args that = (createSpaceAs_args)_that; + dropTag_args that = (dropTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -10426,7 +12040,7 @@ public int hashCode() { } @Override - public int compareTo(createSpaceAs_args other) { + public int compareTo(dropTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10461,7 +12075,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateSpaceAsReq(); + this.req = new DropTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10503,7 +12117,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpaceAs_args"); + StringBuilder sb = new StringBuilder("dropTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10530,8 +12144,8 @@ public void validate() throws TException { } - public static class createSpaceAs_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_result"); + public static class dropTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -10549,13 +12163,13 @@ public static class createSpaceAs_result implements TBase, java.io.Serializable, } static { - FieldMetaData.addStructMetaDataMap(createSpaceAs_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTag_result.class, metaDataMap); } - public createSpaceAs_result() { + public dropTag_result() { } - public createSpaceAs_result( + public dropTag_result( ExecResp success) { this(); this.success = success; @@ -10564,21 +12178,21 @@ public createSpaceAs_result( /** * Performs a deep copy on other. */ - public createSpaceAs_result(createSpaceAs_result other) { + public dropTag_result(dropTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createSpaceAs_result deepCopy() { - return new createSpaceAs_result(this); + public dropTag_result deepCopy() { + return new dropTag_result(this); } public ExecResp getSuccess() { return this.success; } - public createSpaceAs_result setSuccess(ExecResp success) { + public dropTag_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -10629,9 +12243,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSpaceAs_result)) + if (!(_that instanceof dropTag_result)) return false; - createSpaceAs_result that = (createSpaceAs_result)_that; + dropTag_result that = (dropTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -10644,7 +12258,7 @@ public int hashCode() { } @Override - public int compareTo(createSpaceAs_result other) { + public int compareTo(dropTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10720,7 +12334,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpaceAs_result"); + StringBuilder sb = new StringBuilder("dropTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10747,11 +12361,11 @@ public void validate() throws TException { } - public static class createTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTag_args"); + public static class getTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateTagReq req; + public GetTagReq req; public static final int REQ = 1; // isset id assignments @@ -10761,19 +12375,19 @@ public static class createTag_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateTagReq.class))); + new StructMetaData(TType.STRUCT, GetTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTag_args.class, metaDataMap); } - public createTag_args() { + public getTag_args() { } - public createTag_args( - CreateTagReq req) { + public getTag_args( + GetTagReq req) { this(); this.req = req; } @@ -10781,21 +12395,21 @@ public createTag_args( /** * Performs a deep copy on other. */ - public createTag_args(createTag_args other) { + public getTag_args(getTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createTag_args deepCopy() { - return new createTag_args(this); + public getTag_args deepCopy() { + return new getTag_args(this); } - public CreateTagReq getReq() { + public GetTagReq getReq() { return this.req; } - public createTag_args setReq(CreateTagReq req) { + public getTag_args setReq(GetTagReq req) { this.req = req; return this; } @@ -10821,7 +12435,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateTagReq)__value); + setReq((GetTagReq)__value); } break; @@ -10846,9 +12460,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTag_args)) + if (!(_that instanceof getTag_args)) return false; - createTag_args that = (createTag_args)_that; + getTag_args that = (getTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -10861,7 +12475,7 @@ public int hashCode() { } @Override - public int compareTo(createTag_args other) { + public int compareTo(getTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10896,7 +12510,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateTagReq(); + this.req = new GetTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10938,7 +12552,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTag_args"); + StringBuilder sb = new StringBuilder("getTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10965,11 +12579,11 @@ public void validate() throws TException { } - public static class createTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTag_result"); + public static class getTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetTagResp success; public static final int SUCCESS = 0; // isset id assignments @@ -10979,19 +12593,19 @@ public static class createTag_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetTagResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTag_result.class, metaDataMap); } - public createTag_result() { + public getTag_result() { } - public createTag_result( - ExecResp success) { + public getTag_result( + GetTagResp success) { this(); this.success = success; } @@ -10999,21 +12613,21 @@ public createTag_result( /** * Performs a deep copy on other. */ - public createTag_result(createTag_result other) { + public getTag_result(getTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createTag_result deepCopy() { - return new createTag_result(this); + public getTag_result deepCopy() { + return new getTag_result(this); } - public ExecResp getSuccess() { + public GetTagResp getSuccess() { return this.success; } - public createTag_result setSuccess(ExecResp success) { + public getTag_result setSuccess(GetTagResp success) { this.success = success; return this; } @@ -11039,7 +12653,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetTagResp)__value); } break; @@ -11064,9 +12678,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTag_result)) + if (!(_that instanceof getTag_result)) return false; - createTag_result that = (createTag_result)_that; + getTag_result that = (getTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -11079,7 +12693,7 @@ public int hashCode() { } @Override - public int compareTo(createTag_result other) { + public int compareTo(getTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11114,7 +12728,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetTagResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11155,7 +12769,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTag_result"); + StringBuilder sb = new StringBuilder("getTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11182,11 +12796,11 @@ public void validate() throws TException { } - public static class alterTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterTag_args"); + public static class listTags_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTags_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AlterTagReq req; + public ListTagsReq req; public static final int REQ = 1; // isset id assignments @@ -11196,19 +12810,19 @@ public static class alterTag_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AlterTagReq.class))); + new StructMetaData(TType.STRUCT, ListTagsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTags_args.class, metaDataMap); } - public alterTag_args() { + public listTags_args() { } - public alterTag_args( - AlterTagReq req) { + public listTags_args( + ListTagsReq req) { this(); this.req = req; } @@ -11216,21 +12830,21 @@ public alterTag_args( /** * Performs a deep copy on other. */ - public alterTag_args(alterTag_args other) { + public listTags_args(listTags_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public alterTag_args deepCopy() { - return new alterTag_args(this); + public listTags_args deepCopy() { + return new listTags_args(this); } - public AlterTagReq getReq() { + public ListTagsReq getReq() { return this.req; } - public alterTag_args setReq(AlterTagReq req) { + public listTags_args setReq(ListTagsReq req) { this.req = req; return this; } @@ -11256,7 +12870,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AlterTagReq)__value); + setReq((ListTagsReq)__value); } break; @@ -11281,9 +12895,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterTag_args)) + if (!(_that instanceof listTags_args)) return false; - alterTag_args that = (alterTag_args)_that; + listTags_args that = (listTags_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -11296,7 +12910,7 @@ public int hashCode() { } @Override - public int compareTo(alterTag_args other) { + public int compareTo(listTags_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11331,7 +12945,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AlterTagReq(); + this.req = new ListTagsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11373,7 +12987,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterTag_args"); + StringBuilder sb = new StringBuilder("listTags_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11400,11 +13014,11 @@ public void validate() throws TException { } - public static class alterTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterTag_result"); + public static class listTags_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTags_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListTagsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -11414,19 +13028,19 @@ public static class alterTag_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListTagsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTags_result.class, metaDataMap); } - public alterTag_result() { + public listTags_result() { } - public alterTag_result( - ExecResp success) { + public listTags_result( + ListTagsResp success) { this(); this.success = success; } @@ -11434,21 +13048,21 @@ public alterTag_result( /** * Performs a deep copy on other. */ - public alterTag_result(alterTag_result other) { + public listTags_result(listTags_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public alterTag_result deepCopy() { - return new alterTag_result(this); + public listTags_result deepCopy() { + return new listTags_result(this); } - public ExecResp getSuccess() { + public ListTagsResp getSuccess() { return this.success; } - public alterTag_result setSuccess(ExecResp success) { + public listTags_result setSuccess(ListTagsResp success) { this.success = success; return this; } @@ -11474,7 +13088,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListTagsResp)__value); } break; @@ -11499,9 +13113,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterTag_result)) + if (!(_that instanceof listTags_result)) return false; - alterTag_result that = (alterTag_result)_that; + listTags_result that = (listTags_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -11514,7 +13128,7 @@ public int hashCode() { } @Override - public int compareTo(alterTag_result other) { + public int compareTo(listTags_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11549,7 +13163,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListTagsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11590,7 +13204,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterTag_result"); + StringBuilder sb = new StringBuilder("listTags_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11617,11 +13231,11 @@ public void validate() throws TException { } - public static class dropTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTag_args"); + public static class createEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropTagReq req; + public CreateEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -11631,19 +13245,19 @@ public static class dropTag_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropTagReq.class))); + new StructMetaData(TType.STRUCT, CreateEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdge_args.class, metaDataMap); } - public dropTag_args() { + public createEdge_args() { } - public dropTag_args( - DropTagReq req) { + public createEdge_args( + CreateEdgeReq req) { this(); this.req = req; } @@ -11651,21 +13265,21 @@ public dropTag_args( /** * Performs a deep copy on other. */ - public dropTag_args(dropTag_args other) { + public createEdge_args(createEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropTag_args deepCopy() { - return new dropTag_args(this); + public createEdge_args deepCopy() { + return new createEdge_args(this); } - public DropTagReq getReq() { + public CreateEdgeReq getReq() { return this.req; } - public dropTag_args setReq(DropTagReq req) { + public createEdge_args setReq(CreateEdgeReq req) { this.req = req; return this; } @@ -11691,7 +13305,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropTagReq)__value); + setReq((CreateEdgeReq)__value); } break; @@ -11716,9 +13330,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTag_args)) + if (!(_that instanceof createEdge_args)) return false; - dropTag_args that = (dropTag_args)_that; + createEdge_args that = (createEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -11731,7 +13345,7 @@ public int hashCode() { } @Override - public int compareTo(dropTag_args other) { + public int compareTo(createEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11766,7 +13380,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropTagReq(); + this.req = new CreateEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11808,7 +13422,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTag_args"); + StringBuilder sb = new StringBuilder("createEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11835,8 +13449,8 @@ public void validate() throws TException { } - public static class dropTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTag_result"); + public static class createEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -11854,13 +13468,13 @@ public static class dropTag_result implements TBase, java.io.Serializable, Clone } static { - FieldMetaData.addStructMetaDataMap(dropTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdge_result.class, metaDataMap); } - public dropTag_result() { + public createEdge_result() { } - public dropTag_result( + public createEdge_result( ExecResp success) { this(); this.success = success; @@ -11869,21 +13483,21 @@ public dropTag_result( /** * Performs a deep copy on other. */ - public dropTag_result(dropTag_result other) { + public createEdge_result(createEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropTag_result deepCopy() { - return new dropTag_result(this); + public createEdge_result deepCopy() { + return new createEdge_result(this); } public ExecResp getSuccess() { return this.success; } - public dropTag_result setSuccess(ExecResp success) { + public createEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -11934,9 +13548,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTag_result)) + if (!(_that instanceof createEdge_result)) return false; - dropTag_result that = (dropTag_result)_that; + createEdge_result that = (createEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -11949,7 +13563,7 @@ public int hashCode() { } @Override - public int compareTo(dropTag_result other) { + public int compareTo(createEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12025,7 +13639,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTag_result"); + StringBuilder sb = new StringBuilder("createEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12052,11 +13666,11 @@ public void validate() throws TException { } - public static class getTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTag_args"); + public static class alterEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetTagReq req; + public AlterEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -12066,19 +13680,19 @@ public static class getTag_args implements TBase, java.io.Serializable, Cloneabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagReq.class))); + new StructMetaData(TType.STRUCT, AlterEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterEdge_args.class, metaDataMap); } - public getTag_args() { + public alterEdge_args() { } - public getTag_args( - GetTagReq req) { + public alterEdge_args( + AlterEdgeReq req) { this(); this.req = req; } @@ -12086,21 +13700,21 @@ public getTag_args( /** * Performs a deep copy on other. */ - public getTag_args(getTag_args other) { + public alterEdge_args(alterEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getTag_args deepCopy() { - return new getTag_args(this); + public alterEdge_args deepCopy() { + return new alterEdge_args(this); } - public GetTagReq getReq() { + public AlterEdgeReq getReq() { return this.req; } - public getTag_args setReq(GetTagReq req) { + public alterEdge_args setReq(AlterEdgeReq req) { this.req = req; return this; } @@ -12126,7 +13740,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetTagReq)__value); + setReq((AlterEdgeReq)__value); } break; @@ -12151,9 +13765,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTag_args)) + if (!(_that instanceof alterEdge_args)) return false; - getTag_args that = (getTag_args)_that; + alterEdge_args that = (alterEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -12166,7 +13780,7 @@ public int hashCode() { } @Override - public int compareTo(getTag_args other) { + public int compareTo(alterEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12201,7 +13815,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetTagReq(); + this.req = new AlterEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12243,7 +13857,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTag_args"); + StringBuilder sb = new StringBuilder("alterEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12270,11 +13884,11 @@ public void validate() throws TException { } - public static class getTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTag_result"); + public static class alterEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetTagResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -12284,19 +13898,19 @@ public static class getTag_result implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterEdge_result.class, metaDataMap); } - public getTag_result() { + public alterEdge_result() { } - public getTag_result( - GetTagResp success) { + public alterEdge_result( + ExecResp success) { this(); this.success = success; } @@ -12304,21 +13918,21 @@ public getTag_result( /** * Performs a deep copy on other. */ - public getTag_result(getTag_result other) { + public alterEdge_result(alterEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getTag_result deepCopy() { - return new getTag_result(this); + public alterEdge_result deepCopy() { + return new alterEdge_result(this); } - public GetTagResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public getTag_result setSuccess(GetTagResp success) { + public alterEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -12344,7 +13958,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetTagResp)__value); + setSuccess((ExecResp)__value); } break; @@ -12369,9 +13983,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTag_result)) + if (!(_that instanceof alterEdge_result)) return false; - getTag_result that = (getTag_result)_that; + alterEdge_result that = (alterEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -12384,7 +13998,7 @@ public int hashCode() { } @Override - public int compareTo(getTag_result other) { + public int compareTo(alterEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12419,7 +14033,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetTagResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12460,7 +14074,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTag_result"); + StringBuilder sb = new StringBuilder("alterEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12487,11 +14101,11 @@ public void validate() throws TException { } - public static class listTags_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTags_args"); + public static class dropEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListTagsReq req; + public DropEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -12501,19 +14115,19 @@ public static class listTags_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagsReq.class))); + new StructMetaData(TType.STRUCT, DropEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTags_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdge_args.class, metaDataMap); } - public listTags_args() { + public dropEdge_args() { } - public listTags_args( - ListTagsReq req) { + public dropEdge_args( + DropEdgeReq req) { this(); this.req = req; } @@ -12521,21 +14135,21 @@ public listTags_args( /** * Performs a deep copy on other. */ - public listTags_args(listTags_args other) { + public dropEdge_args(dropEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listTags_args deepCopy() { - return new listTags_args(this); + public dropEdge_args deepCopy() { + return new dropEdge_args(this); } - public ListTagsReq getReq() { + public DropEdgeReq getReq() { return this.req; } - public listTags_args setReq(ListTagsReq req) { + public dropEdge_args setReq(DropEdgeReq req) { this.req = req; return this; } @@ -12561,7 +14175,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListTagsReq)__value); + setReq((DropEdgeReq)__value); } break; @@ -12586,9 +14200,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTags_args)) + if (!(_that instanceof dropEdge_args)) return false; - listTags_args that = (listTags_args)_that; + dropEdge_args that = (dropEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -12601,7 +14215,7 @@ public int hashCode() { } @Override - public int compareTo(listTags_args other) { + public int compareTo(dropEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12636,7 +14250,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListTagsReq(); + this.req = new DropEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12678,7 +14292,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTags_args"); + StringBuilder sb = new StringBuilder("dropEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12705,11 +14319,11 @@ public void validate() throws TException { } - public static class listTags_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTags_result"); + public static class dropEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListTagsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -12719,19 +14333,19 @@ public static class listTags_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTags_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdge_result.class, metaDataMap); } - public listTags_result() { + public dropEdge_result() { } - public listTags_result( - ListTagsResp success) { + public dropEdge_result( + ExecResp success) { this(); this.success = success; } @@ -12739,21 +14353,21 @@ public listTags_result( /** * Performs a deep copy on other. */ - public listTags_result(listTags_result other) { + public dropEdge_result(dropEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listTags_result deepCopy() { - return new listTags_result(this); + public dropEdge_result deepCopy() { + return new dropEdge_result(this); } - public ListTagsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listTags_result setSuccess(ListTagsResp success) { + public dropEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -12779,7 +14393,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListTagsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -12804,9 +14418,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTags_result)) + if (!(_that instanceof dropEdge_result)) return false; - listTags_result that = (listTags_result)_that; + dropEdge_result that = (dropEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -12819,7 +14433,7 @@ public int hashCode() { } @Override - public int compareTo(listTags_result other) { + public int compareTo(dropEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12854,7 +14468,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListTagsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12895,7 +14509,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTags_result"); + StringBuilder sb = new StringBuilder("dropEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12922,11 +14536,11 @@ public void validate() throws TException { } - public static class createEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdge_args"); + public static class getEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateEdgeReq req; + public GetEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -12936,19 +14550,19 @@ public static class createEdge_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateEdgeReq.class))); + new StructMetaData(TType.STRUCT, GetEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdge_args.class, metaDataMap); } - public createEdge_args() { + public getEdge_args() { } - public createEdge_args( - CreateEdgeReq req) { + public getEdge_args( + GetEdgeReq req) { this(); this.req = req; } @@ -12956,21 +14570,21 @@ public createEdge_args( /** * Performs a deep copy on other. */ - public createEdge_args(createEdge_args other) { + public getEdge_args(getEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createEdge_args deepCopy() { - return new createEdge_args(this); + public getEdge_args deepCopy() { + return new getEdge_args(this); } - public CreateEdgeReq getReq() { + public GetEdgeReq getReq() { return this.req; } - public createEdge_args setReq(CreateEdgeReq req) { + public getEdge_args setReq(GetEdgeReq req) { this.req = req; return this; } @@ -12996,7 +14610,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateEdgeReq)__value); + setReq((GetEdgeReq)__value); } break; @@ -13021,9 +14635,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdge_args)) + if (!(_that instanceof getEdge_args)) return false; - createEdge_args that = (createEdge_args)_that; + getEdge_args that = (getEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -13036,7 +14650,7 @@ public int hashCode() { } @Override - public int compareTo(createEdge_args other) { + public int compareTo(getEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13071,7 +14685,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateEdgeReq(); + this.req = new GetEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13113,7 +14727,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdge_args"); + StringBuilder sb = new StringBuilder("getEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13140,11 +14754,11 @@ public void validate() throws TException { } - public static class createEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdge_result"); + public static class getEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetEdgeResp success; public static final int SUCCESS = 0; // isset id assignments @@ -13154,19 +14768,19 @@ public static class createEdge_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetEdgeResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdge_result.class, metaDataMap); } - public createEdge_result() { + public getEdge_result() { } - public createEdge_result( - ExecResp success) { + public getEdge_result( + GetEdgeResp success) { this(); this.success = success; } @@ -13174,21 +14788,21 @@ public createEdge_result( /** * Performs a deep copy on other. */ - public createEdge_result(createEdge_result other) { + public getEdge_result(getEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createEdge_result deepCopy() { - return new createEdge_result(this); + public getEdge_result deepCopy() { + return new getEdge_result(this); } - public ExecResp getSuccess() { + public GetEdgeResp getSuccess() { return this.success; } - public createEdge_result setSuccess(ExecResp success) { + public getEdge_result setSuccess(GetEdgeResp success) { this.success = success; return this; } @@ -13214,7 +14828,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetEdgeResp)__value); } break; @@ -13239,9 +14853,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdge_result)) + if (!(_that instanceof getEdge_result)) return false; - createEdge_result that = (createEdge_result)_that; + getEdge_result that = (getEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -13254,7 +14868,7 @@ public int hashCode() { } @Override - public int compareTo(createEdge_result other) { + public int compareTo(getEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13289,7 +14903,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetEdgeResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13330,7 +14944,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdge_result"); + StringBuilder sb = new StringBuilder("getEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13357,11 +14971,11 @@ public void validate() throws TException { } - public static class alterEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterEdge_args"); + public static class listEdges_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdges_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AlterEdgeReq req; + public ListEdgesReq req; public static final int REQ = 1; // isset id assignments @@ -13371,19 +14985,19 @@ public static class alterEdge_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AlterEdgeReq.class))); + new StructMetaData(TType.STRUCT, ListEdgesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdges_args.class, metaDataMap); } - public alterEdge_args() { + public listEdges_args() { } - public alterEdge_args( - AlterEdgeReq req) { + public listEdges_args( + ListEdgesReq req) { this(); this.req = req; } @@ -13391,21 +15005,21 @@ public alterEdge_args( /** * Performs a deep copy on other. */ - public alterEdge_args(alterEdge_args other) { + public listEdges_args(listEdges_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public alterEdge_args deepCopy() { - return new alterEdge_args(this); + public listEdges_args deepCopy() { + return new listEdges_args(this); } - public AlterEdgeReq getReq() { + public ListEdgesReq getReq() { return this.req; } - public alterEdge_args setReq(AlterEdgeReq req) { + public listEdges_args setReq(ListEdgesReq req) { this.req = req; return this; } @@ -13431,7 +15045,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AlterEdgeReq)__value); + setReq((ListEdgesReq)__value); } break; @@ -13456,9 +15070,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterEdge_args)) + if (!(_that instanceof listEdges_args)) return false; - alterEdge_args that = (alterEdge_args)_that; + listEdges_args that = (listEdges_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -13471,7 +15085,7 @@ public int hashCode() { } @Override - public int compareTo(alterEdge_args other) { + public int compareTo(listEdges_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13506,7 +15120,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AlterEdgeReq(); + this.req = new ListEdgesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13548,7 +15162,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterEdge_args"); + StringBuilder sb = new StringBuilder("listEdges_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13575,11 +15189,11 @@ public void validate() throws TException { } - public static class alterEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterEdge_result"); + public static class listEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdges_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListEdgesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -13589,19 +15203,19 @@ public static class alterEdge_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListEdgesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdges_result.class, metaDataMap); } - public alterEdge_result() { + public listEdges_result() { } - public alterEdge_result( - ExecResp success) { + public listEdges_result( + ListEdgesResp success) { this(); this.success = success; } @@ -13609,21 +15223,21 @@ public alterEdge_result( /** * Performs a deep copy on other. */ - public alterEdge_result(alterEdge_result other) { + public listEdges_result(listEdges_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public alterEdge_result deepCopy() { - return new alterEdge_result(this); + public listEdges_result deepCopy() { + return new listEdges_result(this); } - public ExecResp getSuccess() { + public ListEdgesResp getSuccess() { return this.success; } - public alterEdge_result setSuccess(ExecResp success) { + public listEdges_result setSuccess(ListEdgesResp success) { this.success = success; return this; } @@ -13649,7 +15263,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListEdgesResp)__value); } break; @@ -13674,9 +15288,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterEdge_result)) + if (!(_that instanceof listEdges_result)) return false; - alterEdge_result that = (alterEdge_result)_that; + listEdges_result that = (listEdges_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -13689,7 +15303,7 @@ public int hashCode() { } @Override - public int compareTo(alterEdge_result other) { + public int compareTo(listEdges_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13724,7 +15338,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListEdgesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13765,7 +15379,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterEdge_result"); + StringBuilder sb = new StringBuilder("listEdges_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13792,11 +15406,11 @@ public void validate() throws TException { } - public static class dropEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdge_args"); + public static class addHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHosts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropEdgeReq req; + public AddHostsReq req; public static final int REQ = 1; // isset id assignments @@ -13806,19 +15420,19 @@ public static class dropEdge_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropEdgeReq.class))); + new StructMetaData(TType.STRUCT, AddHostsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHosts_args.class, metaDataMap); } - public dropEdge_args() { + public addHosts_args() { } - public dropEdge_args( - DropEdgeReq req) { + public addHosts_args( + AddHostsReq req) { this(); this.req = req; } @@ -13826,21 +15440,21 @@ public dropEdge_args( /** * Performs a deep copy on other. */ - public dropEdge_args(dropEdge_args other) { + public addHosts_args(addHosts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropEdge_args deepCopy() { - return new dropEdge_args(this); + public addHosts_args deepCopy() { + return new addHosts_args(this); } - public DropEdgeReq getReq() { + public AddHostsReq getReq() { return this.req; } - public dropEdge_args setReq(DropEdgeReq req) { + public addHosts_args setReq(AddHostsReq req) { this.req = req; return this; } @@ -13866,7 +15480,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropEdgeReq)__value); + setReq((AddHostsReq)__value); } break; @@ -13891,9 +15505,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdge_args)) + if (!(_that instanceof addHosts_args)) return false; - dropEdge_args that = (dropEdge_args)_that; + addHosts_args that = (addHosts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -13906,7 +15520,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdge_args other) { + public int compareTo(addHosts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13941,7 +15555,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropEdgeReq(); + this.req = new AddHostsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13983,7 +15597,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdge_args"); + StringBuilder sb = new StringBuilder("addHosts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14010,8 +15624,8 @@ public void validate() throws TException { } - public static class dropEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdge_result"); + public static class addHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHosts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -14029,13 +15643,13 @@ public static class dropEdge_result implements TBase, java.io.Serializable, Clon } static { - FieldMetaData.addStructMetaDataMap(dropEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHosts_result.class, metaDataMap); } - public dropEdge_result() { + public addHosts_result() { } - public dropEdge_result( + public addHosts_result( ExecResp success) { this(); this.success = success; @@ -14044,21 +15658,21 @@ public dropEdge_result( /** * Performs a deep copy on other. */ - public dropEdge_result(dropEdge_result other) { + public addHosts_result(addHosts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropEdge_result deepCopy() { - return new dropEdge_result(this); + public addHosts_result deepCopy() { + return new addHosts_result(this); } public ExecResp getSuccess() { return this.success; } - public dropEdge_result setSuccess(ExecResp success) { + public addHosts_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -14109,9 +15723,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdge_result)) + if (!(_that instanceof addHosts_result)) return false; - dropEdge_result that = (dropEdge_result)_that; + addHosts_result that = (addHosts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -14124,7 +15738,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdge_result other) { + public int compareTo(addHosts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14200,7 +15814,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdge_result"); + StringBuilder sb = new StringBuilder("addHosts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14227,11 +15841,11 @@ public void validate() throws TException { } - public static class getEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdge_args"); + public static class addHostsIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetEdgeReq req; + public AddHostsIntoZoneReq req; public static final int REQ = 1; // isset id assignments @@ -14241,19 +15855,19 @@ public static class getEdge_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeReq.class))); + new StructMetaData(TType.STRUCT, AddHostsIntoZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostsIntoZone_args.class, metaDataMap); } - public getEdge_args() { + public addHostsIntoZone_args() { } - public getEdge_args( - GetEdgeReq req) { + public addHostsIntoZone_args( + AddHostsIntoZoneReq req) { this(); this.req = req; } @@ -14261,21 +15875,21 @@ public getEdge_args( /** * Performs a deep copy on other. */ - public getEdge_args(getEdge_args other) { + public addHostsIntoZone_args(addHostsIntoZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getEdge_args deepCopy() { - return new getEdge_args(this); + public addHostsIntoZone_args deepCopy() { + return new addHostsIntoZone_args(this); } - public GetEdgeReq getReq() { + public AddHostsIntoZoneReq getReq() { return this.req; } - public getEdge_args setReq(GetEdgeReq req) { + public addHostsIntoZone_args setReq(AddHostsIntoZoneReq req) { this.req = req; return this; } @@ -14301,7 +15915,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetEdgeReq)__value); + setReq((AddHostsIntoZoneReq)__value); } break; @@ -14326,9 +15940,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdge_args)) + if (!(_that instanceof addHostsIntoZone_args)) return false; - getEdge_args that = (getEdge_args)_that; + addHostsIntoZone_args that = (addHostsIntoZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -14341,7 +15955,7 @@ public int hashCode() { } @Override - public int compareTo(getEdge_args other) { + public int compareTo(addHostsIntoZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14376,7 +15990,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetEdgeReq(); + this.req = new AddHostsIntoZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14418,7 +16032,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdge_args"); + StringBuilder sb = new StringBuilder("addHostsIntoZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14445,11 +16059,11 @@ public void validate() throws TException { } - public static class getEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdge_result"); + public static class addHostsIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetEdgeResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -14459,19 +16073,19 @@ public static class getEdge_result implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostsIntoZone_result.class, metaDataMap); } - public getEdge_result() { + public addHostsIntoZone_result() { } - public getEdge_result( - GetEdgeResp success) { + public addHostsIntoZone_result( + ExecResp success) { this(); this.success = success; } @@ -14479,21 +16093,21 @@ public getEdge_result( /** * Performs a deep copy on other. */ - public getEdge_result(getEdge_result other) { + public addHostsIntoZone_result(addHostsIntoZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getEdge_result deepCopy() { - return new getEdge_result(this); + public addHostsIntoZone_result deepCopy() { + return new addHostsIntoZone_result(this); } - public GetEdgeResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public getEdge_result setSuccess(GetEdgeResp success) { + public addHostsIntoZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -14519,7 +16133,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetEdgeResp)__value); + setSuccess((ExecResp)__value); } break; @@ -14544,9 +16158,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdge_result)) + if (!(_that instanceof addHostsIntoZone_result)) return false; - getEdge_result that = (getEdge_result)_that; + addHostsIntoZone_result that = (addHostsIntoZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -14559,7 +16173,7 @@ public int hashCode() { } @Override - public int compareTo(getEdge_result other) { + public int compareTo(addHostsIntoZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14594,7 +16208,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetEdgeResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14635,7 +16249,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdge_result"); + StringBuilder sb = new StringBuilder("addHostsIntoZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14662,11 +16276,11 @@ public void validate() throws TException { } - public static class listEdges_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdges_args"); + public static class dropHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHosts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListEdgesReq req; + public DropHostsReq req; public static final int REQ = 1; // isset id assignments @@ -14676,19 +16290,19 @@ public static class listEdges_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgesReq.class))); + new StructMetaData(TType.STRUCT, DropHostsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdges_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHosts_args.class, metaDataMap); } - public listEdges_args() { + public dropHosts_args() { } - public listEdges_args( - ListEdgesReq req) { + public dropHosts_args( + DropHostsReq req) { this(); this.req = req; } @@ -14696,21 +16310,21 @@ public listEdges_args( /** * Performs a deep copy on other. */ - public listEdges_args(listEdges_args other) { + public dropHosts_args(dropHosts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listEdges_args deepCopy() { - return new listEdges_args(this); + public dropHosts_args deepCopy() { + return new dropHosts_args(this); } - public ListEdgesReq getReq() { + public DropHostsReq getReq() { return this.req; } - public listEdges_args setReq(ListEdgesReq req) { + public dropHosts_args setReq(DropHostsReq req) { this.req = req; return this; } @@ -14736,7 +16350,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListEdgesReq)__value); + setReq((DropHostsReq)__value); } break; @@ -14761,9 +16375,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdges_args)) + if (!(_that instanceof dropHosts_args)) return false; - listEdges_args that = (listEdges_args)_that; + dropHosts_args that = (dropHosts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -14776,7 +16390,7 @@ public int hashCode() { } @Override - public int compareTo(listEdges_args other) { + public int compareTo(dropHosts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14811,7 +16425,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListEdgesReq(); + this.req = new DropHostsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14853,7 +16467,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdges_args"); + StringBuilder sb = new StringBuilder("dropHosts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14880,11 +16494,11 @@ public void validate() throws TException { } - public static class listEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdges_result"); + public static class dropHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHosts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListEdgesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -14894,19 +16508,19 @@ public static class listEdges_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdges_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHosts_result.class, metaDataMap); } - public listEdges_result() { + public dropHosts_result() { } - public listEdges_result( - ListEdgesResp success) { + public dropHosts_result( + ExecResp success) { this(); this.success = success; } @@ -14914,21 +16528,21 @@ public listEdges_result( /** * Performs a deep copy on other. */ - public listEdges_result(listEdges_result other) { + public dropHosts_result(dropHosts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listEdges_result deepCopy() { - return new listEdges_result(this); + public dropHosts_result deepCopy() { + return new dropHosts_result(this); } - public ListEdgesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listEdges_result setSuccess(ListEdgesResp success) { + public dropHosts_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -14954,7 +16568,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListEdgesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -14979,9 +16593,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdges_result)) + if (!(_that instanceof dropHosts_result)) return false; - listEdges_result that = (listEdges_result)_that; + dropHosts_result that = (dropHosts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -14994,7 +16608,7 @@ public int hashCode() { } @Override - public int compareTo(listEdges_result other) { + public int compareTo(dropHosts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15029,7 +16643,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListEdgesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -15070,7 +16684,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdges_result"); + StringBuilder sb = new StringBuilder("dropHosts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -31947,11 +33561,11 @@ public void validate() throws TException { } - public static class addZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZone_args"); + public static class mergeZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("mergeZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddZoneReq req; + public MergeZoneReq req; public static final int REQ = 1; // isset id assignments @@ -31961,19 +33575,19 @@ public static class addZone_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddZoneReq.class))); + new StructMetaData(TType.STRUCT, MergeZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(mergeZone_args.class, metaDataMap); } - public addZone_args() { + public mergeZone_args() { } - public addZone_args( - AddZoneReq req) { + public mergeZone_args( + MergeZoneReq req) { this(); this.req = req; } @@ -31981,21 +33595,21 @@ public addZone_args( /** * Performs a deep copy on other. */ - public addZone_args(addZone_args other) { + public mergeZone_args(mergeZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addZone_args deepCopy() { - return new addZone_args(this); + public mergeZone_args deepCopy() { + return new mergeZone_args(this); } - public AddZoneReq getReq() { + public MergeZoneReq getReq() { return this.req; } - public addZone_args setReq(AddZoneReq req) { + public mergeZone_args setReq(MergeZoneReq req) { this.req = req; return this; } @@ -32021,7 +33635,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddZoneReq)__value); + setReq((MergeZoneReq)__value); } break; @@ -32046,9 +33660,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addZone_args)) + if (!(_that instanceof mergeZone_args)) return false; - addZone_args that = (addZone_args)_that; + mergeZone_args that = (mergeZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -32061,7 +33675,7 @@ public int hashCode() { } @Override - public int compareTo(addZone_args other) { + public int compareTo(mergeZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32096,7 +33710,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddZoneReq(); + this.req = new MergeZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -32138,7 +33752,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZone_args"); + StringBuilder sb = new StringBuilder("mergeZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32165,8 +33779,8 @@ public void validate() throws TException { } - public static class addZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addZone_result"); + public static class mergeZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("mergeZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -32184,13 +33798,13 @@ public static class addZone_result implements TBase, java.io.Serializable, Clone } static { - FieldMetaData.addStructMetaDataMap(addZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(mergeZone_result.class, metaDataMap); } - public addZone_result() { + public mergeZone_result() { } - public addZone_result( + public mergeZone_result( ExecResp success) { this(); this.success = success; @@ -32199,21 +33813,21 @@ public addZone_result( /** * Performs a deep copy on other. */ - public addZone_result(addZone_result other) { + public mergeZone_result(mergeZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addZone_result deepCopy() { - return new addZone_result(this); + public mergeZone_result deepCopy() { + return new mergeZone_result(this); } public ExecResp getSuccess() { return this.success; } - public addZone_result setSuccess(ExecResp success) { + public mergeZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -32264,9 +33878,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addZone_result)) + if (!(_that instanceof mergeZone_result)) return false; - addZone_result that = (addZone_result)_that; + mergeZone_result that = (mergeZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -32279,7 +33893,7 @@ public int hashCode() { } @Override - public int compareTo(addZone_result other) { + public int compareTo(mergeZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32355,7 +33969,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addZone_result"); + StringBuilder sb = new StringBuilder("mergeZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -32817,11 +34431,11 @@ public void validate() throws TException { } - public static class addHostIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_args"); + public static class splitZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("splitZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddHostIntoZoneReq req; + public SplitZoneReq req; public static final int REQ = 1; // isset id assignments @@ -32831,19 +34445,19 @@ public static class addHostIntoZone_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddHostIntoZoneReq.class))); + new StructMetaData(TType.STRUCT, SplitZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addHostIntoZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(splitZone_args.class, metaDataMap); } - public addHostIntoZone_args() { + public splitZone_args() { } - public addHostIntoZone_args( - AddHostIntoZoneReq req) { + public splitZone_args( + SplitZoneReq req) { this(); this.req = req; } @@ -32851,21 +34465,21 @@ public addHostIntoZone_args( /** * Performs a deep copy on other. */ - public addHostIntoZone_args(addHostIntoZone_args other) { + public splitZone_args(splitZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addHostIntoZone_args deepCopy() { - return new addHostIntoZone_args(this); + public splitZone_args deepCopy() { + return new splitZone_args(this); } - public AddHostIntoZoneReq getReq() { + public SplitZoneReq getReq() { return this.req; } - public addHostIntoZone_args setReq(AddHostIntoZoneReq req) { + public splitZone_args setReq(SplitZoneReq req) { this.req = req; return this; } @@ -32891,7 +34505,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddHostIntoZoneReq)__value); + setReq((SplitZoneReq)__value); } break; @@ -32916,9 +34530,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostIntoZone_args)) + if (!(_that instanceof splitZone_args)) return false; - addHostIntoZone_args that = (addHostIntoZone_args)_that; + splitZone_args that = (splitZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -32931,7 +34545,7 @@ public int hashCode() { } @Override - public int compareTo(addHostIntoZone_args other) { + public int compareTo(splitZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -32966,7 +34580,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddHostIntoZoneReq(); + this.req = new SplitZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33008,7 +34622,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostIntoZone_args"); + StringBuilder sb = new StringBuilder("splitZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33035,8 +34649,8 @@ public void validate() throws TException { } - public static class addHostIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostIntoZone_result"); + public static class splitZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("splitZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -33054,13 +34668,13 @@ public static class addHostIntoZone_result implements TBase, java.io.Serializabl } static { - FieldMetaData.addStructMetaDataMap(addHostIntoZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(splitZone_result.class, metaDataMap); } - public addHostIntoZone_result() { + public splitZone_result() { } - public addHostIntoZone_result( + public splitZone_result( ExecResp success) { this(); this.success = success; @@ -33069,21 +34683,21 @@ public addHostIntoZone_result( /** * Performs a deep copy on other. */ - public addHostIntoZone_result(addHostIntoZone_result other) { + public splitZone_result(splitZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addHostIntoZone_result deepCopy() { - return new addHostIntoZone_result(this); + public splitZone_result deepCopy() { + return new splitZone_result(this); } public ExecResp getSuccess() { return this.success; } - public addHostIntoZone_result setSuccess(ExecResp success) { + public splitZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -33134,9 +34748,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostIntoZone_result)) + if (!(_that instanceof splitZone_result)) return false; - addHostIntoZone_result that = (addHostIntoZone_result)_that; + splitZone_result that = (splitZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -33149,7 +34763,7 @@ public int hashCode() { } @Override - public int compareTo(addHostIntoZone_result other) { + public int compareTo(splitZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33225,7 +34839,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostIntoZone_result"); + StringBuilder sb = new StringBuilder("splitZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33252,11 +34866,11 @@ public void validate() throws TException { } - public static class dropHostFromZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_args"); + public static class renameZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("renameZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropHostFromZoneReq req; + public RenameZoneReq req; public static final int REQ = 1; // isset id assignments @@ -33266,19 +34880,19 @@ public static class dropHostFromZone_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropHostFromZoneReq.class))); + new StructMetaData(TType.STRUCT, RenameZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropHostFromZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(renameZone_args.class, metaDataMap); } - public dropHostFromZone_args() { + public renameZone_args() { } - public dropHostFromZone_args( - DropHostFromZoneReq req) { + public renameZone_args( + RenameZoneReq req) { this(); this.req = req; } @@ -33286,21 +34900,21 @@ public dropHostFromZone_args( /** * Performs a deep copy on other. */ - public dropHostFromZone_args(dropHostFromZone_args other) { + public renameZone_args(renameZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropHostFromZone_args deepCopy() { - return new dropHostFromZone_args(this); + public renameZone_args deepCopy() { + return new renameZone_args(this); } - public DropHostFromZoneReq getReq() { + public RenameZoneReq getReq() { return this.req; } - public dropHostFromZone_args setReq(DropHostFromZoneReq req) { + public renameZone_args setReq(RenameZoneReq req) { this.req = req; return this; } @@ -33326,7 +34940,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropHostFromZoneReq)__value); + setReq((RenameZoneReq)__value); } break; @@ -33351,9 +34965,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropHostFromZone_args)) + if (!(_that instanceof renameZone_args)) return false; - dropHostFromZone_args that = (dropHostFromZone_args)_that; + renameZone_args that = (renameZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -33366,7 +34980,7 @@ public int hashCode() { } @Override - public int compareTo(dropHostFromZone_args other) { + public int compareTo(renameZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33401,7 +35015,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropHostFromZoneReq(); + this.req = new RenameZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -33443,7 +35057,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHostFromZone_args"); + StringBuilder sb = new StringBuilder("renameZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -33470,8 +35084,8 @@ public void validate() throws TException { } - public static class dropHostFromZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHostFromZone_result"); + public static class renameZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("renameZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -33489,13 +35103,13 @@ public static class dropHostFromZone_result implements TBase, java.io.Serializab } static { - FieldMetaData.addStructMetaDataMap(dropHostFromZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(renameZone_result.class, metaDataMap); } - public dropHostFromZone_result() { + public renameZone_result() { } - public dropHostFromZone_result( + public renameZone_result( ExecResp success) { this(); this.success = success; @@ -33504,21 +35118,21 @@ public dropHostFromZone_result( /** * Performs a deep copy on other. */ - public dropHostFromZone_result(dropHostFromZone_result other) { + public renameZone_result(renameZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropHostFromZone_result deepCopy() { - return new dropHostFromZone_result(this); + public renameZone_result deepCopy() { + return new renameZone_result(this); } public ExecResp getSuccess() { return this.success; } - public dropHostFromZone_result setSuccess(ExecResp success) { + public renameZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -33569,9 +35183,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropHostFromZone_result)) + if (!(_that instanceof renameZone_result)) return false; - dropHostFromZone_result that = (dropHostFromZone_result)_that; + renameZone_result that = (renameZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -33584,7 +35198,7 @@ public int hashCode() { } @Override - public int compareTo(dropHostFromZone_result other) { + public int compareTo(renameZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -33660,7 +35274,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHostFromZone_result"); + StringBuilder sb = new StringBuilder("renameZone_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MultiGetReq.java b/client/src/main/generated/com/vesoft/nebula/meta/MultiGetReq.java index 223eae4ba..a26550280 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MultiGetReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MultiGetReq.java @@ -267,15 +267,15 @@ public void read(TProtocol iprot) throws TException { case KEYS: if (__field.type == TType.LIST) { { - TList _list128 = iprot.readListBegin(); - this.keys = new ArrayList(Math.max(0, _list128.size)); - for (int _i129 = 0; - (_list128.size < 0) ? iprot.peekList() : (_i129 < _list128.size); - ++_i129) + TList _list140 = iprot.readListBegin(); + this.keys = new ArrayList(Math.max(0, _list140.size)); + for (int _i141 = 0; + (_list140.size < 0) ? iprot.peekList() : (_i141 < _list140.size); + ++_i141) { - byte[] _elem130; - _elem130 = iprot.readBinary(); - this.keys.add(_elem130); + byte[] _elem142; + _elem142 = iprot.readBinary(); + this.keys.add(_elem142); } iprot.readListEnd(); } @@ -309,8 +309,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KEYS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.keys.size())); - for (byte[] _iter131 : this.keys) { - oprot.writeBinary(_iter131); + for (byte[] _iter143 : this.keys) { + oprot.writeBinary(_iter143); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MultiGetResp.java b/client/src/main/generated/com/vesoft/nebula/meta/MultiGetResp.java index ddc829b43..033b40021 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MultiGetResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MultiGetResp.java @@ -349,15 +349,15 @@ public void read(TProtocol iprot) throws TException { case VALUES: if (__field.type == TType.LIST) { { - TList _list132 = iprot.readListBegin(); - this.values = new ArrayList(Math.max(0, _list132.size)); - for (int _i133 = 0; - (_list132.size < 0) ? iprot.peekList() : (_i133 < _list132.size); - ++_i133) + TList _list144 = iprot.readListBegin(); + this.values = new ArrayList(Math.max(0, _list144.size)); + for (int _i145 = 0; + (_list144.size < 0) ? iprot.peekList() : (_i145 < _list144.size); + ++_i145) { - byte[] _elem134; - _elem134 = iprot.readBinary(); - this.values.add(_elem134); + byte[] _elem146; + _elem146 = iprot.readBinary(); + this.values.add(_elem146); } iprot.readListEnd(); } @@ -396,8 +396,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(VALUES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.values.size())); - for (byte[] _iter135 : this.values) { - oprot.writeBinary(_iter135); + for (byte[] _iter147 : this.values) { + oprot.writeBinary(_iter147); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MultiPutReq.java b/client/src/main/generated/com/vesoft/nebula/meta/MultiPutReq.java index 13d7a71f1..d339afbc5 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MultiPutReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MultiPutReq.java @@ -267,16 +267,16 @@ public void read(TProtocol iprot) throws TException { case PAIRS: if (__field.type == TType.LIST) { { - TList _list124 = iprot.readListBegin(); - this.pairs = new ArrayList(Math.max(0, _list124.size)); - for (int _i125 = 0; - (_list124.size < 0) ? iprot.peekList() : (_i125 < _list124.size); - ++_i125) + TList _list136 = iprot.readListBegin(); + this.pairs = new ArrayList(Math.max(0, _list136.size)); + for (int _i137 = 0; + (_list136.size < 0) ? iprot.peekList() : (_i137 < _list136.size); + ++_i137) { - com.vesoft.nebula.KeyValue _elem126; - _elem126 = new com.vesoft.nebula.KeyValue(); - _elem126.read(iprot); - this.pairs.add(_elem126); + com.vesoft.nebula.KeyValue _elem138; + _elem138 = new com.vesoft.nebula.KeyValue(); + _elem138.read(iprot); + this.pairs.add(_elem138); } iprot.readListEnd(); } @@ -310,8 +310,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PAIRS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.pairs.size())); - for (com.vesoft.nebula.KeyValue _iter127 : this.pairs) { - _iter127.write(oprot); + for (com.vesoft.nebula.KeyValue _iter139 : this.pairs) { + _iter139.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PartItem.java b/client/src/main/generated/com/vesoft/nebula/meta/PartItem.java index cd84fd08b..93df38f22 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/PartItem.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/PartItem.java @@ -419,16 +419,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list94 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list94.size)); - for (int _i95 = 0; - (_list94.size < 0) ? iprot.peekList() : (_i95 < _list94.size); - ++_i95) + TList _list106 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list106.size)); + for (int _i107 = 0; + (_list106.size < 0) ? iprot.peekList() : (_i107 < _list106.size); + ++_i107) { - com.vesoft.nebula.HostAddr _elem96; - _elem96 = new com.vesoft.nebula.HostAddr(); - _elem96.read(iprot); - this.peers.add(_elem96); + com.vesoft.nebula.HostAddr _elem108; + _elem108 = new com.vesoft.nebula.HostAddr(); + _elem108.read(iprot); + this.peers.add(_elem108); } iprot.readListEnd(); } @@ -439,16 +439,16 @@ public void read(TProtocol iprot) throws TException { case LOSTS: if (__field.type == TType.LIST) { { - TList _list97 = iprot.readListBegin(); - this.losts = new ArrayList(Math.max(0, _list97.size)); - for (int _i98 = 0; - (_list97.size < 0) ? iprot.peekList() : (_i98 < _list97.size); - ++_i98) + TList _list109 = iprot.readListBegin(); + this.losts = new ArrayList(Math.max(0, _list109.size)); + for (int _i110 = 0; + (_list109.size < 0) ? iprot.peekList() : (_i110 < _list109.size); + ++_i110) { - com.vesoft.nebula.HostAddr _elem99; - _elem99 = new com.vesoft.nebula.HostAddr(); - _elem99.read(iprot); - this.losts.add(_elem99); + com.vesoft.nebula.HostAddr _elem111; + _elem111 = new com.vesoft.nebula.HostAddr(); + _elem111.read(iprot); + this.losts.add(_elem111); } iprot.readListEnd(); } @@ -490,8 +490,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter100 : this.peers) { - _iter100.write(oprot); + for (com.vesoft.nebula.HostAddr _iter112 : this.peers) { + _iter112.write(oprot); } oprot.writeListEnd(); } @@ -501,8 +501,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.losts.size())); - for (com.vesoft.nebula.HostAddr _iter101 : this.losts) { - _iter101.write(oprot); + for (com.vesoft.nebula.HostAddr _iter113 : this.losts) { + _iter113.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java b/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java index 8ef493cd1..3ace0c8e3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/PartitionList.java @@ -198,15 +198,15 @@ public void read(TProtocol iprot) throws TException { case PART_LIST: if (__field.type == TType.LIST) { { - TList _list140 = iprot.readListBegin(); - this.part_list = new ArrayList(Math.max(0, _list140.size)); - for (int _i141 = 0; - (_list140.size < 0) ? iprot.peekList() : (_i141 < _list140.size); - ++_i141) + TList _list152 = iprot.readListBegin(); + this.part_list = new ArrayList(Math.max(0, _list152.size)); + for (int _i153 = 0; + (_list152.size < 0) ? iprot.peekList() : (_i153 < _list152.size); + ++_i153) { - int _elem142; - _elem142 = iprot.readI32(); - this.part_list.add(_elem142); + int _elem154; + _elem154 = iprot.readI32(); + this.part_list.add(_elem154); } iprot.readListEnd(); } @@ -235,8 +235,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PART_LIST_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.part_list.size())); - for (int _iter143 : this.part_list) { - oprot.writeI32(_iter143); + for (int _iter155 : this.part_list) { + oprot.writeI32(_iter155); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java b/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java new file mode 100644 index 000000000..fc77cc24b --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java @@ -0,0 +1,88 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + + +import com.facebook.thrift.IntRangeSet; +import java.util.Map; +import java.util.HashMap; + +@SuppressWarnings({ "unused" }) +public enum PropertyType implements com.facebook.thrift.TEnum { + UNKNOWN(0), + BOOL(1), + INT64(2), + VID(3), + FLOAT(4), + DOUBLE(5), + STRING(6), + FIXED_STRING(7), + INT8(8), + INT16(9), + INT32(10), + TIMESTAMP(21), + DATE(24), + DATETIME(25), + TIME(26), + GEOGRAPHY(31); + + private final int value; + + private PropertyType(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static PropertyType findByValue(int value) { + switch (value) { + case 0: + return UNKNOWN; + case 1: + return BOOL; + case 2: + return INT64; + case 3: + return VID; + case 4: + return FLOAT; + case 5: + return DOUBLE; + case 6: + return STRING; + case 7: + return FIXED_STRING; + case 8: + return INT8; + case 9: + return INT16; + case 10: + return INT32; + case 21: + return TIMESTAMP; + case 24: + return DATE; + case 25: + return DATETIME; + case 26: + return TIME; + case 31: + return GEOGRAPHY; + default: + return null; + } + } +} diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java index 54437a9a1..dabc1b017 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list188 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list188.size)); - for (int _i189 = 0; - (_list188.size < 0) ? iprot.peekList() : (_i189 < _list188.size); - ++_i189) + TList _list200 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list200.size)); + for (int _i201 = 0; + (_list200.size < 0) ? iprot.peekList() : (_i201 < _list200.size); + ++_i201) { - ConfigItem _elem190; - _elem190 = new ConfigItem(); - _elem190.read(iprot); - this.items.add(_elem190); + ConfigItem _elem202; + _elem202 = new ConfigItem(); + _elem202.read(iprot); + this.items.add(_elem202); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter191 : this.items) { - _iter191.write(oprot); + for (ConfigItem _iter203 : this.items) { + _iter203.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RenameZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RenameZoneReq.java new file mode 100644 index 000000000..94e8d778b --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/RenameZoneReq.java @@ -0,0 +1,360 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class RenameZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("RenameZoneReq"); + private static final TField ORIGINAL_ZONE_NAME_FIELD_DESC = new TField("original_zone_name", TType.STRING, (short)1); + private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)2); + + public byte[] original_zone_name; + public byte[] zone_name; + public static final int ORIGINAL_ZONE_NAME = 1; + public static final int ZONE_NAME = 2; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(ORIGINAL_ZONE_NAME, new FieldMetaData("original_zone_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(RenameZoneReq.class, metaDataMap); + } + + public RenameZoneReq() { + } + + public RenameZoneReq( + byte[] original_zone_name, + byte[] zone_name) { + this(); + this.original_zone_name = original_zone_name; + this.zone_name = zone_name; + } + + public static class Builder { + private byte[] original_zone_name; + private byte[] zone_name; + + public Builder() { + } + + public Builder setOriginal_zone_name(final byte[] original_zone_name) { + this.original_zone_name = original_zone_name; + return this; + } + + public Builder setZone_name(final byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public RenameZoneReq build() { + RenameZoneReq result = new RenameZoneReq(); + result.setOriginal_zone_name(this.original_zone_name); + result.setZone_name(this.zone_name); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public RenameZoneReq(RenameZoneReq other) { + if (other.isSetOriginal_zone_name()) { + this.original_zone_name = TBaseHelper.deepCopy(other.original_zone_name); + } + if (other.isSetZone_name()) { + this.zone_name = TBaseHelper.deepCopy(other.zone_name); + } + } + + public RenameZoneReq deepCopy() { + return new RenameZoneReq(this); + } + + public byte[] getOriginal_zone_name() { + return this.original_zone_name; + } + + public RenameZoneReq setOriginal_zone_name(byte[] original_zone_name) { + this.original_zone_name = original_zone_name; + return this; + } + + public void unsetOriginal_zone_name() { + this.original_zone_name = null; + } + + // Returns true if field original_zone_name is set (has been assigned a value) and false otherwise + public boolean isSetOriginal_zone_name() { + return this.original_zone_name != null; + } + + public void setOriginal_zone_nameIsSet(boolean __value) { + if (!__value) { + this.original_zone_name = null; + } + } + + public byte[] getZone_name() { + return this.zone_name; + } + + public RenameZoneReq setZone_name(byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public void unsetZone_name() { + this.zone_name = null; + } + + // Returns true if field zone_name is set (has been assigned a value) and false otherwise + public boolean isSetZone_name() { + return this.zone_name != null; + } + + public void setZone_nameIsSet(boolean __value) { + if (!__value) { + this.zone_name = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case ORIGINAL_ZONE_NAME: + if (__value == null) { + unsetOriginal_zone_name(); + } else { + setOriginal_zone_name((byte[])__value); + } + break; + + case ZONE_NAME: + if (__value == null) { + unsetZone_name(); + } else { + setZone_name((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case ORIGINAL_ZONE_NAME: + return getOriginal_zone_name(); + + case ZONE_NAME: + return getZone_name(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof RenameZoneReq)) + return false; + RenameZoneReq that = (RenameZoneReq)_that; + + if (!TBaseHelper.equalsSlow(this.isSetOriginal_zone_name(), that.isSetOriginal_zone_name(), this.original_zone_name, that.original_zone_name)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {original_zone_name, zone_name}); + } + + @Override + public int compareTo(RenameZoneReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetOriginal_zone_name()).compareTo(other.isSetOriginal_zone_name()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(original_zone_name, other.original_zone_name); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case ORIGINAL_ZONE_NAME: + if (__field.type == TType.STRING) { + this.original_zone_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ZONE_NAME: + if (__field.type == TType.STRING) { + this.zone_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.original_zone_name != null) { + oprot.writeFieldBegin(ORIGINAL_ZONE_NAME_FIELD_DESC); + oprot.writeBinary(this.original_zone_name); + oprot.writeFieldEnd(); + } + if (this.zone_name != null) { + oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); + oprot.writeBinary(this.zone_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("RenameZoneReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("original_zone_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getOriginal_zone_name() == null) { + sb.append("null"); + } else { + int __original_zone_name_size = Math.min(this.getOriginal_zone_name().length, 128); + for (int i = 0; i < __original_zone_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getOriginal_zone_name()[i]).length() > 1 ? Integer.toHexString(this.getOriginal_zone_name()[i]).substring(Integer.toHexString(this.getOriginal_zone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getOriginal_zone_name()[i]).toUpperCase()); + } + if (this.getOriginal_zone_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("zone_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getZone_name() == null) { + sb.append("null"); + } else { + int __zone_name_size = Math.min(this.getZone_name().length, 128); + for (int i = 0; i < __zone_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); + } + if (this.getZone_name().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java index 650ba0c1b..647b86cf3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java @@ -261,15 +261,15 @@ public void read(TProtocol iprot) throws TException { case FILES: if (__field.type == TType.LIST) { { - TList _list253 = iprot.readListBegin(); - this.files = new ArrayList(Math.max(0, _list253.size)); - for (int _i254 = 0; - (_list253.size < 0) ? iprot.peekList() : (_i254 < _list253.size); - ++_i254) + TList _list269 = iprot.readListBegin(); + this.files = new ArrayList(Math.max(0, _list269.size)); + for (int _i270 = 0; + (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); + ++_i270) { - byte[] _elem255; - _elem255 = iprot.readBinary(); - this.files.add(_elem255); + byte[] _elem271; + _elem271 = iprot.readBinary(); + this.files.add(_elem271); } iprot.readListEnd(); } @@ -280,16 +280,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list256 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list256.size)); - for (int _i257 = 0; - (_list256.size < 0) ? iprot.peekList() : (_i257 < _list256.size); - ++_i257) + TList _list272 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list272.size)); + for (int _i273 = 0; + (_list272.size < 0) ? iprot.peekList() : (_i273 < _list272.size); + ++_i273) { - HostPair _elem258; - _elem258 = new HostPair(); - _elem258.read(iprot); - this.hosts.add(_elem258); + HostPair _elem274; + _elem274 = new HostPair(); + _elem274.read(iprot); + this.hosts.add(_elem274); } iprot.readListEnd(); } @@ -318,8 +318,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.files.size())); - for (byte[] _iter259 : this.files) { - oprot.writeBinary(_iter259); + for (byte[] _iter275 : this.files) { + oprot.writeBinary(_iter275); } oprot.writeListEnd(); } @@ -329,8 +329,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (HostPair _iter260 : this.hosts) { - _iter260.write(oprot); + for (HostPair _iter276 : this.hosts) { + _iter276.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ScanResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ScanResp.java index 7e982b158..0f81dfcd0 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ScanResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ScanResp.java @@ -349,15 +349,15 @@ public void read(TProtocol iprot) throws TException { case VALUES: if (__field.type == TType.LIST) { { - TList _list136 = iprot.readListBegin(); - this.values = new ArrayList(Math.max(0, _list136.size)); - for (int _i137 = 0; - (_list136.size < 0) ? iprot.peekList() : (_i137 < _list136.size); - ++_i137) + TList _list148 = iprot.readListBegin(); + this.values = new ArrayList(Math.max(0, _list148.size)); + for (int _i149 = 0; + (_list148.size < 0) ? iprot.peekList() : (_i149 < _list148.size); + ++_i149) { - byte[] _elem138; - _elem138 = iprot.readBinary(); - this.values.add(_elem138); + byte[] _elem150; + _elem150 = iprot.readBinary(); + this.values.add(_elem150); } iprot.readListEnd(); } @@ -396,8 +396,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(VALUES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.values.size())); - for (byte[] _iter139 : this.values) { - oprot.writeBinary(_iter139); + for (byte[] _iter151 : this.values) { + oprot.writeBinary(_iter151); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java b/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java new file mode 100644 index 000000000..7f4a2d88e --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java @@ -0,0 +1,239 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial", "unchecked" }) +public class SchemaID extends TUnion implements Comparable { + private static final TStruct STRUCT_DESC = new TStruct("SchemaID"); + private static final TField TAG_ID_FIELD_DESC = new TField("tag_id", TType.I32, (short)1); + private static final TField EDGE_TYPE_FIELD_DESC = new TField("edge_type", TType.I32, (short)2); + + public static final int TAG_ID = 1; + public static final int EDGE_TYPE = 2; + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(TAG_ID, new FieldMetaData("tag_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(EDGE_TYPE, new FieldMetaData("edge_type", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + public SchemaID() { + super(); + } + + public SchemaID(int setField, Object __value) { + super(setField, __value); + } + + public SchemaID(SchemaID other) { + super(other); + } + + public SchemaID deepCopy() { + return new SchemaID(this); + } + + public static SchemaID tag_id(int __value) { + SchemaID x = new SchemaID(); + x.setTag_id(__value); + return x; + } + + public static SchemaID edge_type(int __value) { + SchemaID x = new SchemaID(); + x.setEdge_type(__value); + return x; + } + + + @Override + protected void checkType(short setField, Object __value) throws ClassCastException { + switch (setField) { + case TAG_ID: + if (__value instanceof Integer) { + break; + } + throw new ClassCastException("Was expecting value of type Integer for field 'tag_id', but got " + __value.getClass().getSimpleName()); + case EDGE_TYPE: + if (__value instanceof Integer) { + break; + } + throw new ClassCastException("Was expecting value of type Integer for field 'edge_type', but got " + __value.getClass().getSimpleName()); + default: + throw new IllegalArgumentException("Unknown field id " + setField); + } + } + + @Override + public void read(TProtocol iprot) throws TException { + setField_ = 0; + value_ = null; + iprot.readStructBegin(metaDataMap); + TField __field = iprot.readFieldBegin(); + if (__field.type != TType.STOP) + { + value_ = readValue(iprot, __field); + if (value_ != null) + { + switch (__field.id) { + case TAG_ID: + if (__field.type == TAG_ID_FIELD_DESC.type) { + setField_ = __field.id; + } + break; + case EDGE_TYPE: + if (__field.type == EDGE_TYPE_FIELD_DESC.type) { + setField_ = __field.id; + } + break; + } + } + iprot.readFieldEnd(); + TField __stopField = iprot.readFieldBegin(); + if (__stopField.type != TType.STOP) { + throw new TProtocolException(TProtocolException.INVALID_DATA, "Union 'SchemaID' is missing a STOP byte"); + } + } + iprot.readStructEnd(); + } + + @Override + protected Object readValue(TProtocol iprot, TField __field) throws TException { + switch (__field.id) { + case TAG_ID: + if (__field.type == TAG_ID_FIELD_DESC.type) { + Integer tag_id; + tag_id = iprot.readI32(); + return tag_id; + } + break; + case EDGE_TYPE: + if (__field.type == EDGE_TYPE_FIELD_DESC.type) { + Integer edge_type; + edge_type = iprot.readI32(); + return edge_type; + } + break; + } + TProtocolUtil.skip(iprot, __field.type); + return null; + } + + @Override + protected void writeValue(TProtocol oprot, short setField, Object __value) throws TException { + switch (setField) { + case TAG_ID: + Integer tag_id = (Integer)getFieldValue(); + oprot.writeI32(tag_id); + return; + case EDGE_TYPE: + Integer edge_type = (Integer)getFieldValue(); + oprot.writeI32(edge_type); + return; + default: + throw new IllegalStateException("Cannot write union with unknown field " + setField); + } + } + + @Override + protected TField getFieldDesc(int setField) { + switch (setField) { + case TAG_ID: + return TAG_ID_FIELD_DESC; + case EDGE_TYPE: + return EDGE_TYPE_FIELD_DESC; + default: + throw new IllegalArgumentException("Unknown field id " + setField); + } + } + + @Override + protected TStruct getStructDesc() { + return STRUCT_DESC; + } + + @Override + protected Map getMetaDataMap() { return metaDataMap; } + + private Object __getValue(int expectedFieldId) { + if (getSetField() == expectedFieldId) { + return getFieldValue(); + } else { + throw new RuntimeException("Cannot get field '" + getFieldDesc(expectedFieldId).name + "' because union is currently set to " + getFieldDesc(getSetField()).name); + } + } + + private void __setValue(int fieldId, Object __value) { + if (__value == null) throw new NullPointerException(); + setField_ = fieldId; + value_ = __value; + } + + public int getTag_id() { + return (Integer) __getValue(TAG_ID); + } + + public void setTag_id(int __value) { + setField_ = TAG_ID; + value_ = __value; + } + + public int getEdge_type() { + return (Integer) __getValue(EDGE_TYPE); + } + + public void setEdge_type(int __value) { + setField_ = EDGE_TYPE; + value_ = __value; + } + + public boolean equals(Object other) { + if (other instanceof SchemaID) { + return equals((SchemaID)other); + } else { + return false; + } + } + + public boolean equals(SchemaID other) { + return equalsNobinaryImpl(other); + } + + @Override + public int compareTo(SchemaID other) { + return compareToImpl(other); + } + + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {getSetField(), getFieldValue()}); + } + +} diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Session.java b/client/src/main/generated/com/vesoft/nebula/meta/Session.java index b31bc3e05..3477ee02a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Session.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Session.java @@ -738,18 +738,18 @@ public void read(TProtocol iprot) throws TException { case CONFIGS: if (__field.type == TType.MAP) { { - TMap _map278 = iprot.readMapBegin(); - this.configs = new HashMap(Math.max(0, 2*_map278.size)); - for (int _i279 = 0; - (_map278.size < 0) ? iprot.peekMap() : (_i279 < _map278.size); - ++_i279) + TMap _map294 = iprot.readMapBegin(); + this.configs = new HashMap(Math.max(0, 2*_map294.size)); + for (int _i295 = 0; + (_map294.size < 0) ? iprot.peekMap() : (_i295 < _map294.size); + ++_i295) { - byte[] _key280; - com.vesoft.nebula.Value _val281; - _key280 = iprot.readBinary(); - _val281 = new com.vesoft.nebula.Value(); - _val281.read(iprot); - this.configs.put(_key280, _val281); + byte[] _key296; + com.vesoft.nebula.Value _val297; + _key296 = iprot.readBinary(); + _val297 = new com.vesoft.nebula.Value(); + _val297.read(iprot); + this.configs.put(_key296, _val297); } iprot.readMapEnd(); } @@ -760,18 +760,18 @@ public void read(TProtocol iprot) throws TException { case QUERIES: if (__field.type == TType.MAP) { { - TMap _map282 = iprot.readMapBegin(); - this.queries = new HashMap(Math.max(0, 2*_map282.size)); - for (int _i283 = 0; - (_map282.size < 0) ? iprot.peekMap() : (_i283 < _map282.size); - ++_i283) + TMap _map298 = iprot.readMapBegin(); + this.queries = new HashMap(Math.max(0, 2*_map298.size)); + for (int _i299 = 0; + (_map298.size < 0) ? iprot.peekMap() : (_i299 < _map298.size); + ++_i299) { - long _key284; - QueryDesc _val285; - _key284 = iprot.readI64(); - _val285 = new QueryDesc(); - _val285.read(iprot); - this.queries.put(_key284, _val285); + long _key300; + QueryDesc _val301; + _key300 = iprot.readI64(); + _val301 = new QueryDesc(); + _val301.read(iprot); + this.queries.put(_key300, _val301); } iprot.readMapEnd(); } @@ -832,9 +832,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CONFIGS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.configs.size())); - for (Map.Entry _iter286 : this.configs.entrySet()) { - oprot.writeBinary(_iter286.getKey()); - _iter286.getValue().write(oprot); + for (Map.Entry _iter302 : this.configs.entrySet()) { + oprot.writeBinary(_iter302.getKey()); + _iter302.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -844,9 +844,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, this.queries.size())); - for (Map.Entry _iter287 : this.queries.entrySet()) { - oprot.writeI64(_iter287.getKey()); - _iter287.getValue().write(oprot); + for (Map.Entry _iter303 : this.queries.entrySet()) { + oprot.writeI64(_iter303.getKey()); + _iter303.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java b/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java new file mode 100644 index 000000000..979afd30a --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java @@ -0,0 +1,839 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class SessionContext implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("SessionContext"); + private static final TField SESSION_ID_FIELD_DESC = new TField("session_id", TType.I64, (short)1); + private static final TField USER_NAME_FIELD_DESC = new TField("user_name", TType.STRING, (short)2); + private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)3); + private static final TField SCHEMA_FIELD_DESC = new TField("schema", TType.STRUCT, (short)4); + private static final TField SPACE_NAME_FIELD_DESC = new TField("space_name", TType.STRING, (short)5); + private static final TField PARAM_DICT_FIELD_DESC = new TField("param_dict", TType.MAP, (short)6); + private static final TField PARAM_FALGS_FIELD_DESC = new TField("param_falgs", TType.MAP, (short)7); + private static final TField IS_TERMINATED_FIELD_DESC = new TField("is_terminated", TType.BOOL, (short)8); + + public long session_id; + public byte[] user_name; + public int timezone; + public SessionSchema schema; + public byte[] space_name; + public Map param_dict; + public Map param_falgs; + public boolean is_terminated; + public static final int SESSION_ID = 1; + public static final int USER_NAME = 2; + public static final int TIMEZONE = 3; + public static final int SCHEMA = 4; + public static final int SPACE_NAME = 5; + public static final int PARAM_DICT = 6; + public static final int PARAM_FALGS = 7; + public static final int IS_TERMINATED = 8; + + // isset id assignments + private static final int __SESSION_ID_ISSET_ID = 0; + private static final int __TIMEZONE_ISSET_ID = 1; + private static final int __IS_TERMINATED_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SESSION_ID, new FieldMetaData("session_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(USER_NAME, new FieldMetaData("user_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(SCHEMA, new FieldMetaData("schema", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, SessionSchema.class))); + tmpMetaDataMap.put(SPACE_NAME, new FieldMetaData("space_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(PARAM_DICT, new FieldMetaData("param_dict", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); + tmpMetaDataMap.put(PARAM_FALGS, new FieldMetaData("param_falgs", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); + tmpMetaDataMap.put(IS_TERMINATED, new FieldMetaData("is_terminated", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(SessionContext.class, metaDataMap); + } + + public SessionContext() { + this.is_terminated = false; + + } + + public SessionContext( + long session_id, + byte[] user_name, + int timezone, + SessionSchema schema, + byte[] space_name, + Map param_dict, + Map param_falgs, + boolean is_terminated) { + this(); + this.session_id = session_id; + setSession_idIsSet(true); + this.user_name = user_name; + this.timezone = timezone; + setTimezoneIsSet(true); + this.schema = schema; + this.space_name = space_name; + this.param_dict = param_dict; + this.param_falgs = param_falgs; + this.is_terminated = is_terminated; + setIs_terminatedIsSet(true); + } + + public static class Builder { + private long session_id; + private byte[] user_name; + private int timezone; + private SessionSchema schema; + private byte[] space_name; + private Map param_dict; + private Map param_falgs; + private boolean is_terminated; + + BitSet __optional_isset = new BitSet(3); + + public Builder() { + } + + public Builder setSession_id(final long session_id) { + this.session_id = session_id; + __optional_isset.set(__SESSION_ID_ISSET_ID, true); + return this; + } + + public Builder setUser_name(final byte[] user_name) { + this.user_name = user_name; + return this; + } + + public Builder setTimezone(final int timezone) { + this.timezone = timezone; + __optional_isset.set(__TIMEZONE_ISSET_ID, true); + return this; + } + + public Builder setSchema(final SessionSchema schema) { + this.schema = schema; + return this; + } + + public Builder setSpace_name(final byte[] space_name) { + this.space_name = space_name; + return this; + } + + public Builder setParam_dict(final Map param_dict) { + this.param_dict = param_dict; + return this; + } + + public Builder setParam_falgs(final Map param_falgs) { + this.param_falgs = param_falgs; + return this; + } + + public Builder setIs_terminated(final boolean is_terminated) { + this.is_terminated = is_terminated; + __optional_isset.set(__IS_TERMINATED_ISSET_ID, true); + return this; + } + + public SessionContext build() { + SessionContext result = new SessionContext(); + if (__optional_isset.get(__SESSION_ID_ISSET_ID)) { + result.setSession_id(this.session_id); + } + result.setUser_name(this.user_name); + if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { + result.setTimezone(this.timezone); + } + result.setSchema(this.schema); + result.setSpace_name(this.space_name); + result.setParam_dict(this.param_dict); + result.setParam_falgs(this.param_falgs); + if (__optional_isset.get(__IS_TERMINATED_ISSET_ID)) { + result.setIs_terminated(this.is_terminated); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public SessionContext(SessionContext other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.session_id = TBaseHelper.deepCopy(other.session_id); + if (other.isSetUser_name()) { + this.user_name = TBaseHelper.deepCopy(other.user_name); + } + this.timezone = TBaseHelper.deepCopy(other.timezone); + if (other.isSetSchema()) { + this.schema = TBaseHelper.deepCopy(other.schema); + } + if (other.isSetSpace_name()) { + this.space_name = TBaseHelper.deepCopy(other.space_name); + } + if (other.isSetParam_dict()) { + this.param_dict = TBaseHelper.deepCopy(other.param_dict); + } + if (other.isSetParam_falgs()) { + this.param_falgs = TBaseHelper.deepCopy(other.param_falgs); + } + this.is_terminated = TBaseHelper.deepCopy(other.is_terminated); + } + + public SessionContext deepCopy() { + return new SessionContext(this); + } + + public long getSession_id() { + return this.session_id; + } + + public SessionContext setSession_id(long session_id) { + this.session_id = session_id; + setSession_idIsSet(true); + return this; + } + + public void unsetSession_id() { + __isset_bit_vector.clear(__SESSION_ID_ISSET_ID); + } + + // Returns true if field session_id is set (has been assigned a value) and false otherwise + public boolean isSetSession_id() { + return __isset_bit_vector.get(__SESSION_ID_ISSET_ID); + } + + public void setSession_idIsSet(boolean __value) { + __isset_bit_vector.set(__SESSION_ID_ISSET_ID, __value); + } + + public byte[] getUser_name() { + return this.user_name; + } + + public SessionContext setUser_name(byte[] user_name) { + this.user_name = user_name; + return this; + } + + public void unsetUser_name() { + this.user_name = null; + } + + // Returns true if field user_name is set (has been assigned a value) and false otherwise + public boolean isSetUser_name() { + return this.user_name != null; + } + + public void setUser_nameIsSet(boolean __value) { + if (!__value) { + this.user_name = null; + } + } + + public int getTimezone() { + return this.timezone; + } + + public SessionContext setTimezone(int timezone) { + this.timezone = timezone; + setTimezoneIsSet(true); + return this; + } + + public void unsetTimezone() { + __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); + } + + // Returns true if field timezone is set (has been assigned a value) and false otherwise + public boolean isSetTimezone() { + return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); + } + + public void setTimezoneIsSet(boolean __value) { + __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); + } + + public SessionSchema getSchema() { + return this.schema; + } + + public SessionContext setSchema(SessionSchema schema) { + this.schema = schema; + return this; + } + + public void unsetSchema() { + this.schema = null; + } + + // Returns true if field schema is set (has been assigned a value) and false otherwise + public boolean isSetSchema() { + return this.schema != null; + } + + public void setSchemaIsSet(boolean __value) { + if (!__value) { + this.schema = null; + } + } + + public byte[] getSpace_name() { + return this.space_name; + } + + public SessionContext setSpace_name(byte[] space_name) { + this.space_name = space_name; + return this; + } + + public void unsetSpace_name() { + this.space_name = null; + } + + // Returns true if field space_name is set (has been assigned a value) and false otherwise + public boolean isSetSpace_name() { + return this.space_name != null; + } + + public void setSpace_nameIsSet(boolean __value) { + if (!__value) { + this.space_name = null; + } + } + + public Map getParam_dict() { + return this.param_dict; + } + + public SessionContext setParam_dict(Map param_dict) { + this.param_dict = param_dict; + return this; + } + + public void unsetParam_dict() { + this.param_dict = null; + } + + // Returns true if field param_dict is set (has been assigned a value) and false otherwise + public boolean isSetParam_dict() { + return this.param_dict != null; + } + + public void setParam_dictIsSet(boolean __value) { + if (!__value) { + this.param_dict = null; + } + } + + public Map getParam_falgs() { + return this.param_falgs; + } + + public SessionContext setParam_falgs(Map param_falgs) { + this.param_falgs = param_falgs; + return this; + } + + public void unsetParam_falgs() { + this.param_falgs = null; + } + + // Returns true if field param_falgs is set (has been assigned a value) and false otherwise + public boolean isSetParam_falgs() { + return this.param_falgs != null; + } + + public void setParam_falgsIsSet(boolean __value) { + if (!__value) { + this.param_falgs = null; + } + } + + public boolean isIs_terminated() { + return this.is_terminated; + } + + public SessionContext setIs_terminated(boolean is_terminated) { + this.is_terminated = is_terminated; + setIs_terminatedIsSet(true); + return this; + } + + public void unsetIs_terminated() { + __isset_bit_vector.clear(__IS_TERMINATED_ISSET_ID); + } + + // Returns true if field is_terminated is set (has been assigned a value) and false otherwise + public boolean isSetIs_terminated() { + return __isset_bit_vector.get(__IS_TERMINATED_ISSET_ID); + } + + public void setIs_terminatedIsSet(boolean __value) { + __isset_bit_vector.set(__IS_TERMINATED_ISSET_ID, __value); + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SESSION_ID: + if (__value == null) { + unsetSession_id(); + } else { + setSession_id((Long)__value); + } + break; + + case USER_NAME: + if (__value == null) { + unsetUser_name(); + } else { + setUser_name((byte[])__value); + } + break; + + case TIMEZONE: + if (__value == null) { + unsetTimezone(); + } else { + setTimezone((Integer)__value); + } + break; + + case SCHEMA: + if (__value == null) { + unsetSchema(); + } else { + setSchema((SessionSchema)__value); + } + break; + + case SPACE_NAME: + if (__value == null) { + unsetSpace_name(); + } else { + setSpace_name((byte[])__value); + } + break; + + case PARAM_DICT: + if (__value == null) { + unsetParam_dict(); + } else { + setParam_dict((Map)__value); + } + break; + + case PARAM_FALGS: + if (__value == null) { + unsetParam_falgs(); + } else { + setParam_falgs((Map)__value); + } + break; + + case IS_TERMINATED: + if (__value == null) { + unsetIs_terminated(); + } else { + setIs_terminated((Boolean)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SESSION_ID: + return new Long(getSession_id()); + + case USER_NAME: + return getUser_name(); + + case TIMEZONE: + return new Integer(getTimezone()); + + case SCHEMA: + return getSchema(); + + case SPACE_NAME: + return getSpace_name(); + + case PARAM_DICT: + return getParam_dict(); + + case PARAM_FALGS: + return getParam_falgs(); + + case IS_TERMINATED: + return new Boolean(isIs_terminated()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof SessionContext)) + return false; + SessionContext that = (SessionContext)_that; + + if (!TBaseHelper.equalsNobinary(this.session_id, that.session_id)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetUser_name(), that.isSetUser_name(), this.user_name, that.user_name)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetSchema(), that.isSetSchema(), this.schema, that.schema)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetSpace_name(), that.isSetSpace_name(), this.space_name, that.space_name)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetParam_dict(), that.isSetParam_dict(), this.param_dict, that.param_dict)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetParam_falgs(), that.isSetParam_falgs(), this.param_falgs, that.param_falgs)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.is_terminated, that.is_terminated)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {session_id, user_name, timezone, schema, space_name, param_dict, param_falgs, is_terminated}); + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SESSION_ID: + if (__field.type == TType.I64) { + this.session_id = iprot.readI64(); + setSession_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case USER_NAME: + if (__field.type == TType.STRING) { + this.user_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TIMEZONE: + if (__field.type == TType.I32) { + this.timezone = iprot.readI32(); + setTimezoneIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SCHEMA: + if (__field.type == TType.STRUCT) { + this.schema = new SessionSchema(); + this.schema.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SPACE_NAME: + if (__field.type == TType.STRING) { + this.space_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARAM_DICT: + if (__field.type == TType.MAP) { + { + TMap _map304 = iprot.readMapBegin(); + this.param_dict = new HashMap(Math.max(0, 2*_map304.size)); + for (int _i305 = 0; + (_map304.size < 0) ? iprot.peekMap() : (_i305 < _map304.size); + ++_i305) + { + byte[] _key306; + com.vesoft.nebula.Value _val307; + _key306 = iprot.readBinary(); + _val307 = new com.vesoft.nebula.Value(); + _val307.read(iprot); + this.param_dict.put(_key306, _val307); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARAM_FALGS: + if (__field.type == TType.MAP) { + { + TMap _map308 = iprot.readMapBegin(); + this.param_falgs = new HashMap(Math.max(0, 2*_map308.size)); + for (int _i309 = 0; + (_map308.size < 0) ? iprot.peekMap() : (_i309 < _map308.size); + ++_i309) + { + byte[] _key310; + com.vesoft.nebula.Value _val311; + _key310 = iprot.readBinary(); + _val311 = new com.vesoft.nebula.Value(); + _val311.read(iprot); + this.param_falgs.put(_key310, _val311); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case IS_TERMINATED: + if (__field.type == TType.BOOL) { + this.is_terminated = iprot.readBool(); + setIs_terminatedIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); + oprot.writeI64(this.session_id); + oprot.writeFieldEnd(); + if (this.user_name != null) { + oprot.writeFieldBegin(USER_NAME_FIELD_DESC); + oprot.writeBinary(this.user_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); + oprot.writeI32(this.timezone); + oprot.writeFieldEnd(); + if (this.schema != null) { + oprot.writeFieldBegin(SCHEMA_FIELD_DESC); + this.schema.write(oprot); + oprot.writeFieldEnd(); + } + if (this.space_name != null) { + oprot.writeFieldBegin(SPACE_NAME_FIELD_DESC); + oprot.writeBinary(this.space_name); + oprot.writeFieldEnd(); + } + if (this.param_dict != null) { + oprot.writeFieldBegin(PARAM_DICT_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.param_dict.size())); + for (Map.Entry _iter312 : this.param_dict.entrySet()) { + oprot.writeBinary(_iter312.getKey()); + _iter312.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.param_falgs != null) { + oprot.writeFieldBegin(PARAM_FALGS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.param_falgs.size())); + for (Map.Entry _iter313 : this.param_falgs.entrySet()) { + oprot.writeBinary(_iter313.getKey()); + _iter313.getValue().write(oprot); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(IS_TERMINATED_FIELD_DESC); + oprot.writeBool(this.is_terminated); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("SessionContext"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("session_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSession_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("user_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getUser_name() == null) { + sb.append("null"); + } else { + int __user_name_size = Math.min(this.getUser_name().length, 128); + for (int i = 0; i < __user_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getUser_name()[i]).length() > 1 ? Integer.toHexString(this.getUser_name()[i]).substring(Integer.toHexString(this.getUser_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getUser_name()[i]).toUpperCase()); + } + if (this.getUser_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("timezone"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("schema"); + sb.append(space); + sb.append(":").append(space); + if (this.getSchema() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSchema(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("space_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getSpace_name() == null) { + sb.append("null"); + } else { + int __space_name_size = Math.min(this.getSpace_name().length, 128); + for (int i = 0; i < __space_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getSpace_name()[i]).length() > 1 ? Integer.toHexString(this.getSpace_name()[i]).substring(Integer.toHexString(this.getSpace_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getSpace_name()[i]).toUpperCase()); + } + if (this.getSpace_name().length > 128) sb.append(" ..."); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("param_dict"); + sb.append(space); + sb.append(":").append(space); + if (this.getParam_dict() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParam_dict(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("param_falgs"); + sb.append(space); + sb.append(":").append(space); + if (this.getParam_falgs() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getParam_falgs(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("is_terminated"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIs_terminated(), indent + 1, prettyPrint)); + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java b/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java new file mode 100644 index 000000000..2f4520787 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java @@ -0,0 +1,607 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class SessionSchema implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("SessionSchema"); + private static final TField CREATE_TIME_FIELD_DESC = new TField("create_time", TType.I64, (short)1); + private static final TField UPDATE_TIME_FIELD_DESC = new TField("update_time", TType.I64, (short)2); + private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)3); + private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)4); + private static final TField CLIENT_IP_FIELD_DESC = new TField("client_ip", TType.STRING, (short)5); + + public long create_time; + public long update_time; + public com.vesoft.nebula.HostAddr graph_addr; + public int timezone; + public byte[] client_ip; + public static final int CREATE_TIME = 1; + public static final int UPDATE_TIME = 2; + public static final int GRAPH_ADDR = 3; + public static final int TIMEZONE = 4; + public static final int CLIENT_IP = 5; + + // isset id assignments + private static final int __CREATE_TIME_ISSET_ID = 0; + private static final int __UPDATE_TIME_ISSET_ID = 1; + private static final int __TIMEZONE_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(CREATE_TIME, new FieldMetaData("create_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(UPDATE_TIME, new FieldMetaData("update_time", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(CLIENT_IP, new FieldMetaData("client_ip", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(SessionSchema.class, metaDataMap); + } + + public SessionSchema() { + } + + public SessionSchema( + long create_time, + long update_time, + com.vesoft.nebula.HostAddr graph_addr, + int timezone, + byte[] client_ip) { + this(); + this.create_time = create_time; + setCreate_timeIsSet(true); + this.update_time = update_time; + setUpdate_timeIsSet(true); + this.graph_addr = graph_addr; + this.timezone = timezone; + setTimezoneIsSet(true); + this.client_ip = client_ip; + } + + public static class Builder { + private long create_time; + private long update_time; + private com.vesoft.nebula.HostAddr graph_addr; + private int timezone; + private byte[] client_ip; + + BitSet __optional_isset = new BitSet(3); + + public Builder() { + } + + public Builder setCreate_time(final long create_time) { + this.create_time = create_time; + __optional_isset.set(__CREATE_TIME_ISSET_ID, true); + return this; + } + + public Builder setUpdate_time(final long update_time) { + this.update_time = update_time; + __optional_isset.set(__UPDATE_TIME_ISSET_ID, true); + return this; + } + + public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public Builder setTimezone(final int timezone) { + this.timezone = timezone; + __optional_isset.set(__TIMEZONE_ISSET_ID, true); + return this; + } + + public Builder setClient_ip(final byte[] client_ip) { + this.client_ip = client_ip; + return this; + } + + public SessionSchema build() { + SessionSchema result = new SessionSchema(); + if (__optional_isset.get(__CREATE_TIME_ISSET_ID)) { + result.setCreate_time(this.create_time); + } + if (__optional_isset.get(__UPDATE_TIME_ISSET_ID)) { + result.setUpdate_time(this.update_time); + } + result.setGraph_addr(this.graph_addr); + if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { + result.setTimezone(this.timezone); + } + result.setClient_ip(this.client_ip); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public SessionSchema(SessionSchema other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.create_time = TBaseHelper.deepCopy(other.create_time); + this.update_time = TBaseHelper.deepCopy(other.update_time); + if (other.isSetGraph_addr()) { + this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); + } + this.timezone = TBaseHelper.deepCopy(other.timezone); + if (other.isSetClient_ip()) { + this.client_ip = TBaseHelper.deepCopy(other.client_ip); + } + } + + public SessionSchema deepCopy() { + return new SessionSchema(this); + } + + public long getCreate_time() { + return this.create_time; + } + + public SessionSchema setCreate_time(long create_time) { + this.create_time = create_time; + setCreate_timeIsSet(true); + return this; + } + + public void unsetCreate_time() { + __isset_bit_vector.clear(__CREATE_TIME_ISSET_ID); + } + + // Returns true if field create_time is set (has been assigned a value) and false otherwise + public boolean isSetCreate_time() { + return __isset_bit_vector.get(__CREATE_TIME_ISSET_ID); + } + + public void setCreate_timeIsSet(boolean __value) { + __isset_bit_vector.set(__CREATE_TIME_ISSET_ID, __value); + } + + public long getUpdate_time() { + return this.update_time; + } + + public SessionSchema setUpdate_time(long update_time) { + this.update_time = update_time; + setUpdate_timeIsSet(true); + return this; + } + + public void unsetUpdate_time() { + __isset_bit_vector.clear(__UPDATE_TIME_ISSET_ID); + } + + // Returns true if field update_time is set (has been assigned a value) and false otherwise + public boolean isSetUpdate_time() { + return __isset_bit_vector.get(__UPDATE_TIME_ISSET_ID); + } + + public void setUpdate_timeIsSet(boolean __value) { + __isset_bit_vector.set(__UPDATE_TIME_ISSET_ID, __value); + } + + public com.vesoft.nebula.HostAddr getGraph_addr() { + return this.graph_addr; + } + + public SessionSchema setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { + this.graph_addr = graph_addr; + return this; + } + + public void unsetGraph_addr() { + this.graph_addr = null; + } + + // Returns true if field graph_addr is set (has been assigned a value) and false otherwise + public boolean isSetGraph_addr() { + return this.graph_addr != null; + } + + public void setGraph_addrIsSet(boolean __value) { + if (!__value) { + this.graph_addr = null; + } + } + + public int getTimezone() { + return this.timezone; + } + + public SessionSchema setTimezone(int timezone) { + this.timezone = timezone; + setTimezoneIsSet(true); + return this; + } + + public void unsetTimezone() { + __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); + } + + // Returns true if field timezone is set (has been assigned a value) and false otherwise + public boolean isSetTimezone() { + return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); + } + + public void setTimezoneIsSet(boolean __value) { + __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); + } + + public byte[] getClient_ip() { + return this.client_ip; + } + + public SessionSchema setClient_ip(byte[] client_ip) { + this.client_ip = client_ip; + return this; + } + + public void unsetClient_ip() { + this.client_ip = null; + } + + // Returns true if field client_ip is set (has been assigned a value) and false otherwise + public boolean isSetClient_ip() { + return this.client_ip != null; + } + + public void setClient_ipIsSet(boolean __value) { + if (!__value) { + this.client_ip = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case CREATE_TIME: + if (__value == null) { + unsetCreate_time(); + } else { + setCreate_time((Long)__value); + } + break; + + case UPDATE_TIME: + if (__value == null) { + unsetUpdate_time(); + } else { + setUpdate_time((Long)__value); + } + break; + + case GRAPH_ADDR: + if (__value == null) { + unsetGraph_addr(); + } else { + setGraph_addr((com.vesoft.nebula.HostAddr)__value); + } + break; + + case TIMEZONE: + if (__value == null) { + unsetTimezone(); + } else { + setTimezone((Integer)__value); + } + break; + + case CLIENT_IP: + if (__value == null) { + unsetClient_ip(); + } else { + setClient_ip((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case CREATE_TIME: + return new Long(getCreate_time()); + + case UPDATE_TIME: + return new Long(getUpdate_time()); + + case GRAPH_ADDR: + return getGraph_addr(); + + case TIMEZONE: + return new Integer(getTimezone()); + + case CLIENT_IP: + return getClient_ip(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof SessionSchema)) + return false; + SessionSchema that = (SessionSchema)_that; + + if (!TBaseHelper.equalsNobinary(this.create_time, that.create_time)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.update_time, that.update_time)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetClient_ip(), that.isSetClient_ip(), this.client_ip, that.client_ip)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {create_time, update_time, graph_addr, timezone, client_ip}); + } + + @Override + public int compareTo(SessionSchema other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetCreate_time()).compareTo(other.isSetCreate_time()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(create_time, other.create_time); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetUpdate_time()).compareTo(other.isSetUpdate_time()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(update_time, other.update_time); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetGraph_addr()).compareTo(other.isSetGraph_addr()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(graph_addr, other.graph_addr); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetTimezone()).compareTo(other.isSetTimezone()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(timezone, other.timezone); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetClient_ip()).compareTo(other.isSetClient_ip()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(client_ip, other.client_ip); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case CREATE_TIME: + if (__field.type == TType.I64) { + this.create_time = iprot.readI64(); + setCreate_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case UPDATE_TIME: + if (__field.type == TType.I64) { + this.update_time = iprot.readI64(); + setUpdate_timeIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case GRAPH_ADDR: + if (__field.type == TType.STRUCT) { + this.graph_addr = new com.vesoft.nebula.HostAddr(); + this.graph_addr.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case TIMEZONE: + if (__field.type == TType.I32) { + this.timezone = iprot.readI32(); + setTimezoneIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case CLIENT_IP: + if (__field.type == TType.STRING) { + this.client_ip = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); + oprot.writeI64(this.create_time); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(UPDATE_TIME_FIELD_DESC); + oprot.writeI64(this.update_time); + oprot.writeFieldEnd(); + if (this.graph_addr != null) { + oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); + this.graph_addr.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); + oprot.writeI32(this.timezone); + oprot.writeFieldEnd(); + if (this.client_ip != null) { + oprot.writeFieldBegin(CLIENT_IP_FIELD_DESC); + oprot.writeBinary(this.client_ip); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("SessionSchema"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("create_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getCreate_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("update_time"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getUpdate_time(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("graph_addr"); + sb.append(space); + sb.append(":").append(space); + if (this.getGraph_addr() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("timezone"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("client_ip"); + sb.append(space); + sb.append(":").append(space); + if (this.getClient_ip() == null) { + sb.append("null"); + } else { + int __client_ip_size = Math.min(this.getClient_ip().length, 128); + for (int i = 0; i < __client_ip_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getClient_ip()[i]).length() > 1 ? Integer.toHexString(this.getClient_ip()[i]).substring(Integer.toHexString(this.getClient_ip()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getClient_ip()[i]).toUpperCase()); + } + if (this.getClient_ip().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java index 23d2be1f7..d06d03b39 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java @@ -279,16 +279,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list261 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list261.size)); - for (int _i262 = 0; - (_list261.size < 0) ? iprot.peekList() : (_i262 < _list261.size); - ++_i262) + TList _list277 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list277.size)); + for (int _i278 = 0; + (_list277.size < 0) ? iprot.peekList() : (_i278 < _list277.size); + ++_i278) { - FTClient _elem263; - _elem263 = new FTClient(); - _elem263.read(iprot); - this.clients.add(_elem263); + FTClient _elem279; + _elem279 = new FTClient(); + _elem279.read(iprot); + this.clients.add(_elem279); } iprot.readListEnd(); } @@ -322,8 +322,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter264 : this.clients) { - _iter264.write(oprot); + for (FTClient _iter280 : this.clients) { + _iter280.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java index c266908c5..ce9e76060 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java @@ -268,16 +268,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list236 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list236.size)); - for (int _i237 = 0; - (_list236.size < 0) ? iprot.peekList() : (_i237 < _list236.size); - ++_i237) + TList _list252 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list252.size)); + for (int _i253 = 0; + (_list252.size < 0) ? iprot.peekList() : (_i253 < _list252.size); + ++_i253) { - BackupInfo _elem238; - _elem238 = new BackupInfo(); - _elem238.read(iprot); - this.info.add(_elem238); + BackupInfo _elem254; + _elem254 = new BackupInfo(); + _elem254.read(iprot); + this.info.add(_elem254); } iprot.readListEnd(); } @@ -311,8 +311,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (BackupInfo _iter239 : this.info) { - _iter239.write(oprot); + for (BackupInfo _iter255 : this.info) { + _iter255.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java b/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java index 3f786dacb..c1e4db53f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SpaceDesc.java @@ -32,7 +32,7 @@ public class SpaceDesc implements TBase, java.io.Serializable, Cloneable, Compar private static final TField CHARSET_NAME_FIELD_DESC = new TField("charset_name", TType.STRING, (short)4); private static final TField COLLATE_NAME_FIELD_DESC = new TField("collate_name", TType.STRING, (short)5); private static final TField VID_TYPE_FIELD_DESC = new TField("vid_type", TType.STRUCT, (short)6); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)7); + private static final TField ZONE_NAMES_FIELD_DESC = new TField("zone_names", TType.LIST, (short)7); private static final TField ISOLATION_LEVEL_FIELD_DESC = new TField("isolation_level", TType.I32, (short)8); private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)9); @@ -42,7 +42,7 @@ public class SpaceDesc implements TBase, java.io.Serializable, Cloneable, Compar public byte[] charset_name; public byte[] collate_name; public ColumnTypeDef vid_type; - public byte[] group_name; + public List zone_names; /** * * @see IsolationLevel @@ -55,7 +55,7 @@ public class SpaceDesc implements TBase, java.io.Serializable, Cloneable, Compar public static final int CHARSET_NAME = 4; public static final int COLLATE_NAME = 5; public static final int VID_TYPE = 6; - public static final int GROUP_NAME = 7; + public static final int ZONE_NAMES = 7; public static final int ISOLATION_LEVEL = 8; public static final int COMMENT = 9; @@ -80,8 +80,9 @@ public class SpaceDesc implements TBase, java.io.Serializable, Cloneable, Compar new FieldValueMetaData(TType.STRING))); tmpMetaDataMap.put(VID_TYPE, new FieldMetaData("vid_type", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, ColumnTypeDef.class))); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(ZONE_NAMES, new FieldMetaData("zone_names", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.STRING)))); tmpMetaDataMap.put(ISOLATION_LEVEL, new FieldMetaData("isolation_level", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.I32))); tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, @@ -110,7 +111,8 @@ public SpaceDesc( int replica_factor, byte[] charset_name, byte[] collate_name, - ColumnTypeDef vid_type) { + ColumnTypeDef vid_type, + List zone_names) { this(); this.space_name = space_name; this.partition_num = partition_num; @@ -120,6 +122,7 @@ public SpaceDesc( this.charset_name = charset_name; this.collate_name = collate_name; this.vid_type = vid_type; + this.zone_names = zone_names; } public SpaceDesc( @@ -129,7 +132,7 @@ public SpaceDesc( byte[] charset_name, byte[] collate_name, ColumnTypeDef vid_type, - byte[] group_name, + List zone_names, IsolationLevel isolation_level, byte[] comment) { this(); @@ -141,7 +144,7 @@ public SpaceDesc( this.charset_name = charset_name; this.collate_name = collate_name; this.vid_type = vid_type; - this.group_name = group_name; + this.zone_names = zone_names; this.isolation_level = isolation_level; this.comment = comment; } @@ -153,7 +156,7 @@ public static class Builder { private byte[] charset_name; private byte[] collate_name; private ColumnTypeDef vid_type; - private byte[] group_name; + private List zone_names; private IsolationLevel isolation_level; private byte[] comment; @@ -194,8 +197,8 @@ public Builder setVid_type(final ColumnTypeDef vid_type) { return this; } - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; + public Builder setZone_names(final List zone_names) { + this.zone_names = zone_names; return this; } @@ -221,7 +224,7 @@ public SpaceDesc build() { result.setCharset_name(this.charset_name); result.setCollate_name(this.collate_name); result.setVid_type(this.vid_type); - result.setGroup_name(this.group_name); + result.setZone_names(this.zone_names); result.setIsolation_level(this.isolation_level); result.setComment(this.comment); return result; @@ -252,8 +255,8 @@ public SpaceDesc(SpaceDesc other) { if (other.isSetVid_type()) { this.vid_type = TBaseHelper.deepCopy(other.vid_type); } - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); + if (other.isSetZone_names()) { + this.zone_names = TBaseHelper.deepCopy(other.zone_names); } if (other.isSetIsolation_level()) { this.isolation_level = TBaseHelper.deepCopy(other.isolation_level); @@ -409,27 +412,27 @@ public void setVid_typeIsSet(boolean __value) { } } - public byte[] getGroup_name() { - return this.group_name; + public List getZone_names() { + return this.zone_names; } - public SpaceDesc setGroup_name(byte[] group_name) { - this.group_name = group_name; + public SpaceDesc setZone_names(List zone_names) { + this.zone_names = zone_names; return this; } - public void unsetGroup_name() { - this.group_name = null; + public void unsetZone_names() { + this.zone_names = null; } - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; + // Returns true if field zone_names is set (has been assigned a value) and false otherwise + public boolean isSetZone_names() { + return this.zone_names != null; } - public void setGroup_nameIsSet(boolean __value) { + public void setZone_namesIsSet(boolean __value) { if (!__value) { - this.group_name = null; + this.zone_names = null; } } @@ -489,6 +492,7 @@ public void setCommentIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { case SPACE_NAME: @@ -539,11 +543,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case GROUP_NAME: + case ZONE_NAMES: if (__value == null) { - unsetGroup_name(); + unsetZone_names(); } else { - setGroup_name((byte[])__value); + setZone_names((List)__value); } break; @@ -588,8 +592,8 @@ public Object getFieldValue(int fieldID) { case VID_TYPE: return getVid_type(); - case GROUP_NAME: - return getGroup_name(); + case ZONE_NAMES: + return getZone_names(); case ISOLATION_LEVEL: return getIsolation_level(); @@ -624,7 +628,7 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetVid_type(), that.isSetVid_type(), this.vid_type, that.vid_type)) { return false; } - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetZone_names(), that.isSetZone_names(), this.zone_names, that.zone_names)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetIsolation_level(), that.isSetIsolation_level(), this.isolation_level, that.isolation_level)) { return false; } @@ -635,7 +639,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_name, partition_num, replica_factor, charset_name, collate_name, vid_type, group_name, isolation_level, comment}); + return Arrays.deepHashCode(new Object[] {space_name, partition_num, replica_factor, charset_name, collate_name, vid_type, zone_names, isolation_level, comment}); } @Override @@ -698,11 +702,11 @@ public int compareTo(SpaceDesc other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); + lastComparison = Boolean.valueOf(isSetZone_names()).compareTo(other.isSetZone_names()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); + lastComparison = TBaseHelper.compareTo(zone_names, other.zone_names); if (lastComparison != 0) { return lastComparison; } @@ -781,9 +785,21 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); + case ZONE_NAMES: + if (__field.type == TType.LIST) { + { + TList _list4 = iprot.readListBegin(); + this.zone_names = new ArrayList(Math.max(0, _list4.size)); + for (int _i5 = 0; + (_list4.size < 0) ? iprot.peekList() : (_i5 < _list4.size); + ++_i5) + { + byte[] _elem6; + _elem6 = iprot.readBinary(); + this.zone_names.add(_elem6); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -845,12 +861,16 @@ public void write(TProtocol oprot) throws TException { this.vid_type.write(oprot); oprot.writeFieldEnd(); } - if (this.group_name != null) { - if (isSetGroup_name()) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); + if (this.zone_names != null) { + oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); + for (byte[] _iter7 : this.zone_names) { + oprot.writeBinary(_iter7); + } + oprot.writeListEnd(); } + oprot.writeFieldEnd(); } if (this.isolation_level != null) { if (isSetIsolation_level()) { @@ -958,25 +978,17 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getVid_type(), indent + 1, prettyPrint)); } first = false; - if (isSetGroup_name()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("zone_names"); + sb.append(space); + sb.append(":").append(space); + if (this.getZone_names() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getZone_names(), indent + 1, prettyPrint)); } + first = false; if (isSetIsolation_level()) { if (!first) sb.append("," + newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SplitZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/SplitZoneReq.java new file mode 100644 index 000000000..383b9e8c2 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/SplitZoneReq.java @@ -0,0 +1,270 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class SplitZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("SplitZoneReq"); + private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)1); + + public byte[] zone_name; + public static final int ZONE_NAME = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(SplitZoneReq.class, metaDataMap); + } + + public SplitZoneReq() { + } + + public SplitZoneReq( + byte[] zone_name) { + this(); + this.zone_name = zone_name; + } + + public static class Builder { + private byte[] zone_name; + + public Builder() { + } + + public Builder setZone_name(final byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public SplitZoneReq build() { + SplitZoneReq result = new SplitZoneReq(); + result.setZone_name(this.zone_name); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public SplitZoneReq(SplitZoneReq other) { + if (other.isSetZone_name()) { + this.zone_name = TBaseHelper.deepCopy(other.zone_name); + } + } + + public SplitZoneReq deepCopy() { + return new SplitZoneReq(this); + } + + public byte[] getZone_name() { + return this.zone_name; + } + + public SplitZoneReq setZone_name(byte[] zone_name) { + this.zone_name = zone_name; + return this; + } + + public void unsetZone_name() { + this.zone_name = null; + } + + // Returns true if field zone_name is set (has been assigned a value) and false otherwise + public boolean isSetZone_name() { + return this.zone_name != null; + } + + public void setZone_nameIsSet(boolean __value) { + if (!__value) { + this.zone_name = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case ZONE_NAME: + if (__value == null) { + unsetZone_name(); + } else { + setZone_name((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case ZONE_NAME: + return getZone_name(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof SplitZoneReq)) + return false; + SplitZoneReq that = (SplitZoneReq)_that; + + if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {zone_name}); + } + + @Override + public int compareTo(SplitZoneReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case ZONE_NAME: + if (__field.type == TType.STRING) { + this.zone_name = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.zone_name != null) { + oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); + oprot.writeBinary(this.zone_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("SplitZoneReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("zone_name"); + sb.append(space); + sb.append(":").append(space); + if (this.getZone_name() == null) { + sb.append("null"); + } else { + int __zone_name_size = Math.min(this.getZone_name().length, 128); + for (int i = 0; i < __zone_name_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); + } + if (this.getZone_name().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java b/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java new file mode 100644 index 000000000..850f16215 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java @@ -0,0 +1,927 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class StatisItem implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("StatisItem"); + private static final TField TAG_VERTICES_FIELD_DESC = new TField("tag_vertices", TType.MAP, (short)1); + private static final TField EDGES_FIELD_DESC = new TField("edges", TType.MAP, (short)2); + private static final TField SPACE_VERTICES_FIELD_DESC = new TField("space_vertices", TType.I64, (short)3); + private static final TField SPACE_EDGES_FIELD_DESC = new TField("space_edges", TType.I64, (short)4); + private static final TField POSITIVE_PART_CORRELATIVITY_FIELD_DESC = new TField("positive_part_correlativity", TType.MAP, (short)5); + private static final TField NEGATIVE_PART_CORRELATIVITY_FIELD_DESC = new TField("negative_part_correlativity", TType.MAP, (short)6); + private static final TField STATUS_FIELD_DESC = new TField("status", TType.I32, (short)7); + + public Map tag_vertices; + public Map edges; + public long space_vertices; + public long space_edges; + public Map> positive_part_correlativity; + public Map> negative_part_correlativity; + /** + * + * @see JobStatus + */ + public JobStatus status; + public static final int TAG_VERTICES = 1; + public static final int EDGES = 2; + public static final int SPACE_VERTICES = 3; + public static final int SPACE_EDGES = 4; + public static final int POSITIVE_PART_CORRELATIVITY = 5; + public static final int NEGATIVE_PART_CORRELATIVITY = 6; + public static final int STATUS = 7; + + // isset id assignments + private static final int __SPACE_VERTICES_ISSET_ID = 0; + private static final int __SPACE_EDGES_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(TAG_VERTICES, new FieldMetaData("tag_vertices", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new FieldValueMetaData(TType.I64)))); + tmpMetaDataMap.put(EDGES, new FieldMetaData("edges", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new FieldValueMetaData(TType.I64)))); + tmpMetaDataMap.put(SPACE_VERTICES, new FieldMetaData("space_vertices", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(SPACE_EDGES, new FieldMetaData("space_edges", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I64))); + tmpMetaDataMap.put(POSITIVE_PART_CORRELATIVITY, new FieldMetaData("positive_part_correlativity", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Correlativity.class))))); + tmpMetaDataMap.put(NEGATIVE_PART_CORRELATIVITY, new FieldMetaData("negative_part_correlativity", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, Correlativity.class))))); + tmpMetaDataMap.put(STATUS, new FieldMetaData("status", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(StatisItem.class, metaDataMap); + } + + public StatisItem() { + } + + public StatisItem( + Map tag_vertices, + Map edges, + long space_vertices, + long space_edges, + Map> positive_part_correlativity, + Map> negative_part_correlativity, + JobStatus status) { + this(); + this.tag_vertices = tag_vertices; + this.edges = edges; + this.space_vertices = space_vertices; + setSpace_verticesIsSet(true); + this.space_edges = space_edges; + setSpace_edgesIsSet(true); + this.positive_part_correlativity = positive_part_correlativity; + this.negative_part_correlativity = negative_part_correlativity; + this.status = status; + } + + public static class Builder { + private Map tag_vertices; + private Map edges; + private long space_vertices; + private long space_edges; + private Map> positive_part_correlativity; + private Map> negative_part_correlativity; + private JobStatus status; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setTag_vertices(final Map tag_vertices) { + this.tag_vertices = tag_vertices; + return this; + } + + public Builder setEdges(final Map edges) { + this.edges = edges; + return this; + } + + public Builder setSpace_vertices(final long space_vertices) { + this.space_vertices = space_vertices; + __optional_isset.set(__SPACE_VERTICES_ISSET_ID, true); + return this; + } + + public Builder setSpace_edges(final long space_edges) { + this.space_edges = space_edges; + __optional_isset.set(__SPACE_EDGES_ISSET_ID, true); + return this; + } + + public Builder setPositive_part_correlativity(final Map> positive_part_correlativity) { + this.positive_part_correlativity = positive_part_correlativity; + return this; + } + + public Builder setNegative_part_correlativity(final Map> negative_part_correlativity) { + this.negative_part_correlativity = negative_part_correlativity; + return this; + } + + public Builder setStatus(final JobStatus status) { + this.status = status; + return this; + } + + public StatisItem build() { + StatisItem result = new StatisItem(); + result.setTag_vertices(this.tag_vertices); + result.setEdges(this.edges); + if (__optional_isset.get(__SPACE_VERTICES_ISSET_ID)) { + result.setSpace_vertices(this.space_vertices); + } + if (__optional_isset.get(__SPACE_EDGES_ISSET_ID)) { + result.setSpace_edges(this.space_edges); + } + result.setPositive_part_correlativity(this.positive_part_correlativity); + result.setNegative_part_correlativity(this.negative_part_correlativity); + result.setStatus(this.status); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public StatisItem(StatisItem other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + if (other.isSetTag_vertices()) { + this.tag_vertices = TBaseHelper.deepCopy(other.tag_vertices); + } + if (other.isSetEdges()) { + this.edges = TBaseHelper.deepCopy(other.edges); + } + this.space_vertices = TBaseHelper.deepCopy(other.space_vertices); + this.space_edges = TBaseHelper.deepCopy(other.space_edges); + if (other.isSetPositive_part_correlativity()) { + this.positive_part_correlativity = TBaseHelper.deepCopy(other.positive_part_correlativity); + } + if (other.isSetNegative_part_correlativity()) { + this.negative_part_correlativity = TBaseHelper.deepCopy(other.negative_part_correlativity); + } + if (other.isSetStatus()) { + this.status = TBaseHelper.deepCopy(other.status); + } + } + + public StatisItem deepCopy() { + return new StatisItem(this); + } + + public Map getTag_vertices() { + return this.tag_vertices; + } + + public StatisItem setTag_vertices(Map tag_vertices) { + this.tag_vertices = tag_vertices; + return this; + } + + public void unsetTag_vertices() { + this.tag_vertices = null; + } + + // Returns true if field tag_vertices is set (has been assigned a value) and false otherwise + public boolean isSetTag_vertices() { + return this.tag_vertices != null; + } + + public void setTag_verticesIsSet(boolean __value) { + if (!__value) { + this.tag_vertices = null; + } + } + + public Map getEdges() { + return this.edges; + } + + public StatisItem setEdges(Map edges) { + this.edges = edges; + return this; + } + + public void unsetEdges() { + this.edges = null; + } + + // Returns true if field edges is set (has been assigned a value) and false otherwise + public boolean isSetEdges() { + return this.edges != null; + } + + public void setEdgesIsSet(boolean __value) { + if (!__value) { + this.edges = null; + } + } + + public long getSpace_vertices() { + return this.space_vertices; + } + + public StatisItem setSpace_vertices(long space_vertices) { + this.space_vertices = space_vertices; + setSpace_verticesIsSet(true); + return this; + } + + public void unsetSpace_vertices() { + __isset_bit_vector.clear(__SPACE_VERTICES_ISSET_ID); + } + + // Returns true if field space_vertices is set (has been assigned a value) and false otherwise + public boolean isSetSpace_vertices() { + return __isset_bit_vector.get(__SPACE_VERTICES_ISSET_ID); + } + + public void setSpace_verticesIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_VERTICES_ISSET_ID, __value); + } + + public long getSpace_edges() { + return this.space_edges; + } + + public StatisItem setSpace_edges(long space_edges) { + this.space_edges = space_edges; + setSpace_edgesIsSet(true); + return this; + } + + public void unsetSpace_edges() { + __isset_bit_vector.clear(__SPACE_EDGES_ISSET_ID); + } + + // Returns true if field space_edges is set (has been assigned a value) and false otherwise + public boolean isSetSpace_edges() { + return __isset_bit_vector.get(__SPACE_EDGES_ISSET_ID); + } + + public void setSpace_edgesIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_EDGES_ISSET_ID, __value); + } + + public Map> getPositive_part_correlativity() { + return this.positive_part_correlativity; + } + + public StatisItem setPositive_part_correlativity(Map> positive_part_correlativity) { + this.positive_part_correlativity = positive_part_correlativity; + return this; + } + + public void unsetPositive_part_correlativity() { + this.positive_part_correlativity = null; + } + + // Returns true if field positive_part_correlativity is set (has been assigned a value) and false otherwise + public boolean isSetPositive_part_correlativity() { + return this.positive_part_correlativity != null; + } + + public void setPositive_part_correlativityIsSet(boolean __value) { + if (!__value) { + this.positive_part_correlativity = null; + } + } + + public Map> getNegative_part_correlativity() { + return this.negative_part_correlativity; + } + + public StatisItem setNegative_part_correlativity(Map> negative_part_correlativity) { + this.negative_part_correlativity = negative_part_correlativity; + return this; + } + + public void unsetNegative_part_correlativity() { + this.negative_part_correlativity = null; + } + + // Returns true if field negative_part_correlativity is set (has been assigned a value) and false otherwise + public boolean isSetNegative_part_correlativity() { + return this.negative_part_correlativity != null; + } + + public void setNegative_part_correlativityIsSet(boolean __value) { + if (!__value) { + this.negative_part_correlativity = null; + } + } + + /** + * + * @see JobStatus + */ + public JobStatus getStatus() { + return this.status; + } + + /** + * + * @see JobStatus + */ + public StatisItem setStatus(JobStatus status) { + this.status = status; + return this; + } + + public void unsetStatus() { + this.status = null; + } + + // Returns true if field status is set (has been assigned a value) and false otherwise + public boolean isSetStatus() { + return this.status != null; + } + + public void setStatusIsSet(boolean __value) { + if (!__value) { + this.status = null; + } + } + + @SuppressWarnings("unchecked") + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case TAG_VERTICES: + if (__value == null) { + unsetTag_vertices(); + } else { + setTag_vertices((Map)__value); + } + break; + + case EDGES: + if (__value == null) { + unsetEdges(); + } else { + setEdges((Map)__value); + } + break; + + case SPACE_VERTICES: + if (__value == null) { + unsetSpace_vertices(); + } else { + setSpace_vertices((Long)__value); + } + break; + + case SPACE_EDGES: + if (__value == null) { + unsetSpace_edges(); + } else { + setSpace_edges((Long)__value); + } + break; + + case POSITIVE_PART_CORRELATIVITY: + if (__value == null) { + unsetPositive_part_correlativity(); + } else { + setPositive_part_correlativity((Map>)__value); + } + break; + + case NEGATIVE_PART_CORRELATIVITY: + if (__value == null) { + unsetNegative_part_correlativity(); + } else { + setNegative_part_correlativity((Map>)__value); + } + break; + + case STATUS: + if (__value == null) { + unsetStatus(); + } else { + setStatus((JobStatus)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case TAG_VERTICES: + return getTag_vertices(); + + case EDGES: + return getEdges(); + + case SPACE_VERTICES: + return new Long(getSpace_vertices()); + + case SPACE_EDGES: + return new Long(getSpace_edges()); + + case POSITIVE_PART_CORRELATIVITY: + return getPositive_part_correlativity(); + + case NEGATIVE_PART_CORRELATIVITY: + return getNegative_part_correlativity(); + + case STATUS: + return getStatus(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof StatisItem)) + return false; + StatisItem that = (StatisItem)_that; + + if (!TBaseHelper.equalsSlow(this.isSetTag_vertices(), that.isSetTag_vertices(), this.tag_vertices, that.tag_vertices)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetEdges(), that.isSetEdges(), this.edges, that.edges)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.space_vertices, that.space_vertices)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.space_edges, that.space_edges)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetPositive_part_correlativity(), that.isSetPositive_part_correlativity(), this.positive_part_correlativity, that.positive_part_correlativity)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetNegative_part_correlativity(), that.isSetNegative_part_correlativity(), this.negative_part_correlativity, that.negative_part_correlativity)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetStatus(), that.isSetStatus(), this.status, that.status)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {tag_vertices, edges, space_vertices, space_edges, positive_part_correlativity, negative_part_correlativity, status}); + } + + @Override + public int compareTo(StatisItem other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetTag_vertices()).compareTo(other.isSetTag_vertices()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(tag_vertices, other.tag_vertices); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetEdges()).compareTo(other.isSetEdges()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(edges, other.edges); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetSpace_vertices()).compareTo(other.isSetSpace_vertices()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space_vertices, other.space_vertices); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetSpace_edges()).compareTo(other.isSetSpace_edges()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space_edges, other.space_edges); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetPositive_part_correlativity()).compareTo(other.isSetPositive_part_correlativity()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(positive_part_correlativity, other.positive_part_correlativity); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetNegative_part_correlativity()).compareTo(other.isSetNegative_part_correlativity()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(negative_part_correlativity, other.negative_part_correlativity); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(status, other.status); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case TAG_VERTICES: + if (__field.type == TType.MAP) { + { + TMap _map42 = iprot.readMapBegin(); + this.tag_vertices = new HashMap(Math.max(0, 2*_map42.size)); + for (int _i43 = 0; + (_map42.size < 0) ? iprot.peekMap() : (_i43 < _map42.size); + ++_i43) + { + byte[] _key44; + long _val45; + _key44 = iprot.readBinary(); + _val45 = iprot.readI64(); + this.tag_vertices.put(_key44, _val45); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case EDGES: + if (__field.type == TType.MAP) { + { + TMap _map46 = iprot.readMapBegin(); + this.edges = new HashMap(Math.max(0, 2*_map46.size)); + for (int _i47 = 0; + (_map46.size < 0) ? iprot.peekMap() : (_i47 < _map46.size); + ++_i47) + { + byte[] _key48; + long _val49; + _key48 = iprot.readBinary(); + _val49 = iprot.readI64(); + this.edges.put(_key48, _val49); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SPACE_VERTICES: + if (__field.type == TType.I64) { + this.space_vertices = iprot.readI64(); + setSpace_verticesIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case SPACE_EDGES: + if (__field.type == TType.I64) { + this.space_edges = iprot.readI64(); + setSpace_edgesIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case POSITIVE_PART_CORRELATIVITY: + if (__field.type == TType.MAP) { + { + TMap _map50 = iprot.readMapBegin(); + this.positive_part_correlativity = new HashMap>(Math.max(0, 2*_map50.size)); + for (int _i51 = 0; + (_map50.size < 0) ? iprot.peekMap() : (_i51 < _map50.size); + ++_i51) + { + int _key52; + List _val53; + _key52 = iprot.readI32(); + { + TList _list54 = iprot.readListBegin(); + _val53 = new ArrayList(Math.max(0, _list54.size)); + for (int _i55 = 0; + (_list54.size < 0) ? iprot.peekList() : (_i55 < _list54.size); + ++_i55) + { + Correlativity _elem56; + _elem56 = new Correlativity(); + _elem56.read(iprot); + _val53.add(_elem56); + } + iprot.readListEnd(); + } + this.positive_part_correlativity.put(_key52, _val53); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case NEGATIVE_PART_CORRELATIVITY: + if (__field.type == TType.MAP) { + { + TMap _map57 = iprot.readMapBegin(); + this.negative_part_correlativity = new HashMap>(Math.max(0, 2*_map57.size)); + for (int _i58 = 0; + (_map57.size < 0) ? iprot.peekMap() : (_i58 < _map57.size); + ++_i58) + { + int _key59; + List _val60; + _key59 = iprot.readI32(); + { + TList _list61 = iprot.readListBegin(); + _val60 = new ArrayList(Math.max(0, _list61.size)); + for (int _i62 = 0; + (_list61.size < 0) ? iprot.peekList() : (_i62 < _list61.size); + ++_i62) + { + Correlativity _elem63; + _elem63 = new Correlativity(); + _elem63.read(iprot); + _val60.add(_elem63); + } + iprot.readListEnd(); + } + this.negative_part_correlativity.put(_key59, _val60); + } + iprot.readMapEnd(); + } + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case STATUS: + if (__field.type == TType.I32) { + this.status = JobStatus.findByValue(iprot.readI32()); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.tag_vertices != null) { + oprot.writeFieldBegin(TAG_VERTICES_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.tag_vertices.size())); + for (Map.Entry _iter64 : this.tag_vertices.entrySet()) { + oprot.writeBinary(_iter64.getKey()); + oprot.writeI64(_iter64.getValue()); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.edges != null) { + oprot.writeFieldBegin(EDGES_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.edges.size())); + for (Map.Entry _iter65 : this.edges.entrySet()) { + oprot.writeBinary(_iter65.getKey()); + oprot.writeI64(_iter65.getValue()); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(SPACE_VERTICES_FIELD_DESC); + oprot.writeI64(this.space_vertices); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(SPACE_EDGES_FIELD_DESC); + oprot.writeI64(this.space_edges); + oprot.writeFieldEnd(); + if (this.positive_part_correlativity != null) { + oprot.writeFieldBegin(POSITIVE_PART_CORRELATIVITY_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.positive_part_correlativity.size())); + for (Map.Entry> _iter66 : this.positive_part_correlativity.entrySet()) { + oprot.writeI32(_iter66.getKey()); + { + oprot.writeListBegin(new TList(TType.STRUCT, _iter66.getValue().size())); + for (Correlativity _iter67 : _iter66.getValue()) { + _iter67.write(oprot); + } + oprot.writeListEnd(); + } + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.negative_part_correlativity != null) { + oprot.writeFieldBegin(NEGATIVE_PART_CORRELATIVITY_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.negative_part_correlativity.size())); + for (Map.Entry> _iter68 : this.negative_part_correlativity.entrySet()) { + oprot.writeI32(_iter68.getKey()); + { + oprot.writeListBegin(new TList(TType.STRUCT, _iter68.getValue().size())); + for (Correlativity _iter69 : _iter68.getValue()) { + _iter69.write(oprot); + } + oprot.writeListEnd(); + } + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (this.status != null) { + oprot.writeFieldBegin(STATUS_FIELD_DESC); + oprot.writeI32(this.status == null ? 0 : this.status.getValue()); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("StatisItem"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("tag_vertices"); + sb.append(space); + sb.append(":").append(space); + if (this.getTag_vertices() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getTag_vertices(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("edges"); + sb.append(space); + sb.append(":").append(space); + if (this.getEdges() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getEdges(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("space_vertices"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_vertices(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("space_edges"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_edges(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("positive_part_correlativity"); + sb.append(space); + sb.append(":").append(space); + if (this.getPositive_part_correlativity() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getPositive_part_correlativity(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("negative_part_correlativity"); + sb.append(space); + sb.append(":").append(space); + if (this.getNegative_part_correlativity() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getNegative_part_correlativity(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("status"); + sb.append(space); + sb.append(":").append(space); + if (this.getStatus() == null) { + sb.append("null"); + } else { + String status_name = this.getStatus() == null ? "null" : this.getStatus().name(); + if (status_name != null) { + sb.append(status_name); + sb.append(" ("); + } + sb.append(this.getStatus()); + if (status_name != null) { + sb.append(")"); + } + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/StatsItem.java b/client/src/main/generated/com/vesoft/nebula/meta/StatsItem.java index 7c1646564..62a0c0f47 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/StatsItem.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/StatsItem.java @@ -600,17 +600,17 @@ public void read(TProtocol iprot) throws TException { case TAG_VERTICES: if (__field.type == TType.MAP) { { - TMap _map42 = iprot.readMapBegin(); - this.tag_vertices = new HashMap(Math.max(0, 2*_map42.size)); - for (int _i43 = 0; - (_map42.size < 0) ? iprot.peekMap() : (_i43 < _map42.size); - ++_i43) + TMap _map46 = iprot.readMapBegin(); + this.tag_vertices = new HashMap(Math.max(0, 2*_map46.size)); + for (int _i47 = 0; + (_map46.size < 0) ? iprot.peekMap() : (_i47 < _map46.size); + ++_i47) { - byte[] _key44; - long _val45; - _key44 = iprot.readBinary(); - _val45 = iprot.readI64(); - this.tag_vertices.put(_key44, _val45); + byte[] _key48; + long _val49; + _key48 = iprot.readBinary(); + _val49 = iprot.readI64(); + this.tag_vertices.put(_key48, _val49); } iprot.readMapEnd(); } @@ -621,17 +621,17 @@ public void read(TProtocol iprot) throws TException { case EDGES: if (__field.type == TType.MAP) { { - TMap _map46 = iprot.readMapBegin(); - this.edges = new HashMap(Math.max(0, 2*_map46.size)); - for (int _i47 = 0; - (_map46.size < 0) ? iprot.peekMap() : (_i47 < _map46.size); - ++_i47) + TMap _map50 = iprot.readMapBegin(); + this.edges = new HashMap(Math.max(0, 2*_map50.size)); + for (int _i51 = 0; + (_map50.size < 0) ? iprot.peekMap() : (_i51 < _map50.size); + ++_i51) { - byte[] _key48; - long _val49; - _key48 = iprot.readBinary(); - _val49 = iprot.readI64(); - this.edges.put(_key48, _val49); + byte[] _key52; + long _val53; + _key52 = iprot.readBinary(); + _val53 = iprot.readI64(); + this.edges.put(_key52, _val53); } iprot.readMapEnd(); } @@ -658,30 +658,30 @@ public void read(TProtocol iprot) throws TException { case POSITIVE_PART_CORRELATIVITY: if (__field.type == TType.MAP) { { - TMap _map50 = iprot.readMapBegin(); - this.positive_part_correlativity = new HashMap>(Math.max(0, 2*_map50.size)); - for (int _i51 = 0; - (_map50.size < 0) ? iprot.peekMap() : (_i51 < _map50.size); - ++_i51) + TMap _map54 = iprot.readMapBegin(); + this.positive_part_correlativity = new HashMap>(Math.max(0, 2*_map54.size)); + for (int _i55 = 0; + (_map54.size < 0) ? iprot.peekMap() : (_i55 < _map54.size); + ++_i55) { - int _key52; - List _val53; - _key52 = iprot.readI32(); + int _key56; + List _val57; + _key56 = iprot.readI32(); { - TList _list54 = iprot.readListBegin(); - _val53 = new ArrayList(Math.max(0, _list54.size)); - for (int _i55 = 0; - (_list54.size < 0) ? iprot.peekList() : (_i55 < _list54.size); - ++_i55) + TList _list58 = iprot.readListBegin(); + _val57 = new ArrayList(Math.max(0, _list58.size)); + for (int _i59 = 0; + (_list58.size < 0) ? iprot.peekList() : (_i59 < _list58.size); + ++_i59) { - Correlativity _elem56; - _elem56 = new Correlativity(); - _elem56.read(iprot); - _val53.add(_elem56); + Correlativity _elem60; + _elem60 = new Correlativity(); + _elem60.read(iprot); + _val57.add(_elem60); } iprot.readListEnd(); } - this.positive_part_correlativity.put(_key52, _val53); + this.positive_part_correlativity.put(_key56, _val57); } iprot.readMapEnd(); } @@ -692,30 +692,30 @@ public void read(TProtocol iprot) throws TException { case NEGATIVE_PART_CORRELATIVITY: if (__field.type == TType.MAP) { { - TMap _map57 = iprot.readMapBegin(); - this.negative_part_correlativity = new HashMap>(Math.max(0, 2*_map57.size)); - for (int _i58 = 0; - (_map57.size < 0) ? iprot.peekMap() : (_i58 < _map57.size); - ++_i58) + TMap _map61 = iprot.readMapBegin(); + this.negative_part_correlativity = new HashMap>(Math.max(0, 2*_map61.size)); + for (int _i62 = 0; + (_map61.size < 0) ? iprot.peekMap() : (_i62 < _map61.size); + ++_i62) { - int _key59; - List _val60; - _key59 = iprot.readI32(); + int _key63; + List _val64; + _key63 = iprot.readI32(); { - TList _list61 = iprot.readListBegin(); - _val60 = new ArrayList(Math.max(0, _list61.size)); - for (int _i62 = 0; - (_list61.size < 0) ? iprot.peekList() : (_i62 < _list61.size); - ++_i62) + TList _list65 = iprot.readListBegin(); + _val64 = new ArrayList(Math.max(0, _list65.size)); + for (int _i66 = 0; + (_list65.size < 0) ? iprot.peekList() : (_i66 < _list65.size); + ++_i66) { - Correlativity _elem63; - _elem63 = new Correlativity(); - _elem63.read(iprot); - _val60.add(_elem63); + Correlativity _elem67; + _elem67 = new Correlativity(); + _elem67.read(iprot); + _val64.add(_elem67); } iprot.readListEnd(); } - this.negative_part_correlativity.put(_key59, _val60); + this.negative_part_correlativity.put(_key63, _val64); } iprot.readMapEnd(); } @@ -751,9 +751,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TAG_VERTICES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.tag_vertices.size())); - for (Map.Entry _iter64 : this.tag_vertices.entrySet()) { - oprot.writeBinary(_iter64.getKey()); - oprot.writeI64(_iter64.getValue()); + for (Map.Entry _iter68 : this.tag_vertices.entrySet()) { + oprot.writeBinary(_iter68.getKey()); + oprot.writeI64(_iter68.getValue()); } oprot.writeMapEnd(); } @@ -763,9 +763,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.edges.size())); - for (Map.Entry _iter65 : this.edges.entrySet()) { - oprot.writeBinary(_iter65.getKey()); - oprot.writeI64(_iter65.getValue()); + for (Map.Entry _iter69 : this.edges.entrySet()) { + oprot.writeBinary(_iter69.getKey()); + oprot.writeI64(_iter69.getValue()); } oprot.writeMapEnd(); } @@ -781,12 +781,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(POSITIVE_PART_CORRELATIVITY_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.positive_part_correlativity.size())); - for (Map.Entry> _iter66 : this.positive_part_correlativity.entrySet()) { - oprot.writeI32(_iter66.getKey()); + for (Map.Entry> _iter70 : this.positive_part_correlativity.entrySet()) { + oprot.writeI32(_iter70.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter66.getValue().size())); - for (Correlativity _iter67 : _iter66.getValue()) { - _iter67.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter70.getValue().size())); + for (Correlativity _iter71 : _iter70.getValue()) { + _iter71.write(oprot); } oprot.writeListEnd(); } @@ -799,12 +799,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(NEGATIVE_PART_CORRELATIVITY_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.negative_part_correlativity.size())); - for (Map.Entry> _iter68 : this.negative_part_correlativity.entrySet()) { - oprot.writeI32(_iter68.getKey()); + for (Map.Entry> _iter72 : this.negative_part_correlativity.entrySet()) { + oprot.writeI32(_iter72.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter68.getValue().size())); - for (Correlativity _iter69 : _iter68.getValue()) { - _iter69.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter72.getValue().size())); + for (Correlativity _iter73 : _iter72.getValue()) { + _iter73.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java index c49ea50de..53d108957 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list288 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list288.size)); - for (int _i289 = 0; - (_list288.size < 0) ? iprot.peekList() : (_i289 < _list288.size); - ++_i289) + TList _list304 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list304.size)); + for (int _i305 = 0; + (_list304.size < 0) ? iprot.peekList() : (_i305 < _list304.size); + ++_i305) { - Session _elem290; - _elem290 = new Session(); - _elem290.read(iprot); - this.sessions.add(_elem290); + Session _elem306; + _elem306 = new Session(); + _elem306.read(iprot); + this.sessions.add(_elem306); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter291 : this.sessions) { - _iter291.write(oprot); + for (Session _iter307 : this.sessions) { + _iter307.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java index b752bfc5a..f39ae4113 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java @@ -352,32 +352,32 @@ public void read(TProtocol iprot) throws TException { case KILLED_QUERIES: if (__field.type == TType.MAP) { { - TMap _map292 = iprot.readMapBegin(); - this.killed_queries = new HashMap>(Math.max(0, 2*_map292.size)); - for (int _i293 = 0; - (_map292.size < 0) ? iprot.peekMap() : (_i293 < _map292.size); - ++_i293) + TMap _map308 = iprot.readMapBegin(); + this.killed_queries = new HashMap>(Math.max(0, 2*_map308.size)); + for (int _i309 = 0; + (_map308.size < 0) ? iprot.peekMap() : (_i309 < _map308.size); + ++_i309) { - long _key294; - Map _val295; - _key294 = iprot.readI64(); + long _key310; + Map _val311; + _key310 = iprot.readI64(); { - TMap _map296 = iprot.readMapBegin(); - _val295 = new HashMap(Math.max(0, 2*_map296.size)); - for (int _i297 = 0; - (_map296.size < 0) ? iprot.peekMap() : (_i297 < _map296.size); - ++_i297) + TMap _map312 = iprot.readMapBegin(); + _val311 = new HashMap(Math.max(0, 2*_map312.size)); + for (int _i313 = 0; + (_map312.size < 0) ? iprot.peekMap() : (_i313 < _map312.size); + ++_i313) { - long _key298; - QueryDesc _val299; - _key298 = iprot.readI64(); - _val299 = new QueryDesc(); - _val299.read(iprot); - _val295.put(_key298, _val299); + long _key314; + QueryDesc _val315; + _key314 = iprot.readI64(); + _val315 = new QueryDesc(); + _val315.read(iprot); + _val311.put(_key314, _val315); } iprot.readMapEnd(); } - this.killed_queries.put(_key294, _val295); + this.killed_queries.put(_key310, _val311); } iprot.readMapEnd(); } @@ -416,13 +416,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILLED_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.MAP, this.killed_queries.size())); - for (Map.Entry> _iter300 : this.killed_queries.entrySet()) { - oprot.writeI64(_iter300.getKey()); + for (Map.Entry> _iter316 : this.killed_queries.entrySet()) { + oprot.writeI64(_iter316.getKey()); { - oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter300.getValue().size())); - for (Map.Entry _iter301 : _iter300.getValue().entrySet()) { - oprot.writeI64(_iter301.getKey()); - _iter301.getValue().write(oprot); + oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter316.getValue().size())); + for (Map.Entry _iter317 : _iter316.getValue().entrySet()) { + oprot.writeI64(_iter317.getKey()); + _iter317.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java index 1251c12d4..1fac99451 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/VerifyClientVersionReq.java @@ -26,13 +26,16 @@ @SuppressWarnings({ "unused", "serial" }) public class VerifyClientVersionReq implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("VerifyClientVersionReq"); - private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)1); + private static final TField CLIENT_VERSION_FIELD_DESC = new TField("client_version", TType.STRING, (short)1); private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)2); + private static final TField BUILD_VERSION_FIELD_DESC = new TField("build_version", TType.STRING, (short)3); - public byte[] version; + public byte[] client_version; public com.vesoft.nebula.HostAddr host; - public static final int VERSION = 1; + public byte[] build_version; + public static final int CLIENT_VERSION = 1; public static final int HOST = 2; + public static final int BUILD_VERSION = 3; // isset id assignments @@ -40,10 +43,12 @@ public class VerifyClientVersionReq implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.REQUIRED, + tmpMetaDataMap.put(CLIENT_VERSION, new FieldMetaData("client_version", TFieldRequirementType.REQUIRED, new FieldValueMetaData(TType.STRING))); tmpMetaDataMap.put(HOST, new FieldMetaData("host", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(BUILD_VERSION, new FieldMetaData("build_version", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -52,33 +57,36 @@ public class VerifyClientVersionReq implements TBase, java.io.Serializable, Clon } public VerifyClientVersionReq() { - this.version = "2.6.0".getBytes(); + this.client_version = "2.6.0".getBytes(); } public VerifyClientVersionReq( - byte[] version) { + byte[] client_version) { this(); - this.version = version; + this.client_version = client_version; } public VerifyClientVersionReq( - byte[] version, - com.vesoft.nebula.HostAddr host) { + byte[] client_version, + com.vesoft.nebula.HostAddr host, + byte[] build_version) { this(); - this.version = version; + this.client_version = client_version; this.host = host; + this.build_version = build_version; } public static class Builder { - private byte[] version; + private byte[] client_version; private com.vesoft.nebula.HostAddr host; + private byte[] build_version; public Builder() { } - public Builder setVersion(final byte[] version) { - this.version = version; + public Builder setClient_version(final byte[] client_version) { + this.client_version = client_version; return this; } @@ -87,10 +95,16 @@ public Builder setHost(final com.vesoft.nebula.HostAddr host) { return this; } + public Builder setBuild_version(final byte[] build_version) { + this.build_version = build_version; + return this; + } + public VerifyClientVersionReq build() { VerifyClientVersionReq result = new VerifyClientVersionReq(); - result.setVersion(this.version); + result.setClient_version(this.client_version); result.setHost(this.host); + result.setBuild_version(this.build_version); return result; } } @@ -103,39 +117,42 @@ public static Builder builder() { * Performs a deep copy on other. */ public VerifyClientVersionReq(VerifyClientVersionReq other) { - if (other.isSetVersion()) { - this.version = TBaseHelper.deepCopy(other.version); + if (other.isSetClient_version()) { + this.client_version = TBaseHelper.deepCopy(other.client_version); } if (other.isSetHost()) { this.host = TBaseHelper.deepCopy(other.host); } + if (other.isSetBuild_version()) { + this.build_version = TBaseHelper.deepCopy(other.build_version); + } } public VerifyClientVersionReq deepCopy() { return new VerifyClientVersionReq(this); } - public byte[] getVersion() { - return this.version; + public byte[] getClient_version() { + return this.client_version; } - public VerifyClientVersionReq setVersion(byte[] version) { - this.version = version; + public VerifyClientVersionReq setClient_version(byte[] client_version) { + this.client_version = client_version; return this; } - public void unsetVersion() { - this.version = null; + public void unsetClient_version() { + this.client_version = null; } - // Returns true if field version is set (has been assigned a value) and false otherwise - public boolean isSetVersion() { - return this.version != null; + // Returns true if field client_version is set (has been assigned a value) and false otherwise + public boolean isSetClient_version() { + return this.client_version != null; } - public void setVersionIsSet(boolean __value) { + public void setClient_versionIsSet(boolean __value) { if (!__value) { - this.version = null; + this.client_version = null; } } @@ -163,13 +180,37 @@ public void setHostIsSet(boolean __value) { } } + public byte[] getBuild_version() { + return this.build_version; + } + + public VerifyClientVersionReq setBuild_version(byte[] build_version) { + this.build_version = build_version; + return this; + } + + public void unsetBuild_version() { + this.build_version = null; + } + + // Returns true if field build_version is set (has been assigned a value) and false otherwise + public boolean isSetBuild_version() { + return this.build_version != null; + } + + public void setBuild_versionIsSet(boolean __value) { + if (!__value) { + this.build_version = null; + } + } + public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case VERSION: + case CLIENT_VERSION: if (__value == null) { - unsetVersion(); + unsetClient_version(); } else { - setVersion((byte[])__value); + setClient_version((byte[])__value); } break; @@ -181,6 +222,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case BUILD_VERSION: + if (__value == null) { + unsetBuild_version(); + } else { + setBuild_version((byte[])__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -188,12 +237,15 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case VERSION: - return getVersion(); + case CLIENT_VERSION: + return getClient_version(); case HOST: return getHost(); + case BUILD_VERSION: + return getBuild_version(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -209,16 +261,18 @@ public boolean equals(Object _that) { return false; VerifyClientVersionReq that = (VerifyClientVersionReq)_that; - if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetClient_version(), that.isSetClient_version(), this.client_version, that.client_version)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetHost(), that.isSetHost(), this.host, that.host)) { return false; } + if (!TBaseHelper.equalsSlow(this.isSetBuild_version(), that.isSetBuild_version(), this.build_version, that.build_version)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {version, host}); + return Arrays.deepHashCode(new Object[] {client_version, host, build_version}); } @Override @@ -233,11 +287,11 @@ public int compareTo(VerifyClientVersionReq other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + lastComparison = Boolean.valueOf(isSetClient_version()).compareTo(other.isSetClient_version()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(version, other.version); + lastComparison = TBaseHelper.compareTo(client_version, other.client_version); if (lastComparison != 0) { return lastComparison; } @@ -249,6 +303,14 @@ public int compareTo(VerifyClientVersionReq other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetBuild_version()).compareTo(other.isSetBuild_version()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(build_version, other.build_version); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -263,9 +325,9 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case VERSION: + case CLIENT_VERSION: if (__field.type == TType.STRING) { - this.version = iprot.readBinary(); + this.client_version = iprot.readBinary(); } else { TProtocolUtil.skip(iprot, __field.type); } @@ -278,6 +340,13 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case BUILD_VERSION: + if (__field.type == TType.STRING) { + this.build_version = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -295,9 +364,9 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - if (this.version != null) { - oprot.writeFieldBegin(VERSION_FIELD_DESC); - oprot.writeBinary(this.version); + if (this.client_version != null) { + oprot.writeFieldBegin(CLIENT_VERSION_FIELD_DESC); + oprot.writeBinary(this.client_version); oprot.writeFieldEnd(); } if (this.host != null) { @@ -305,6 +374,11 @@ public void write(TProtocol oprot) throws TException { this.host.write(oprot); oprot.writeFieldEnd(); } + if (this.build_version != null) { + oprot.writeFieldBegin(BUILD_VERSION_FIELD_DESC); + oprot.writeBinary(this.build_version); + oprot.writeFieldEnd(); + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -326,18 +400,18 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("version"); + sb.append("client_version"); sb.append(space); sb.append(":").append(space); - if (this.getVersion() == null) { + if (this.getClient_version() == null) { sb.append("null"); } else { - int __version_size = Math.min(this.getVersion().length, 128); - for (int i = 0; i < __version_size; i++) { + int __client_version_size = Math.min(this.getClient_version().length, 128); + for (int i = 0; i < __client_version_size; i++) { if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); + sb.append(Integer.toHexString(this.getClient_version()[i]).length() > 1 ? Integer.toHexString(this.getClient_version()[i]).substring(Integer.toHexString(this.getClient_version()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getClient_version()[i]).toUpperCase()); } - if (this.getVersion().length > 128) sb.append(" ..."); + if (this.getClient_version().length > 128) sb.append(" ..."); } first = false; if (!first) sb.append("," + newLine); @@ -351,6 +425,22 @@ public String toString(int indent, boolean prettyPrint) { sb.append(TBaseHelper.toString(this.getHost(), indent + 1, prettyPrint)); } first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("build_version"); + sb.append(space); + sb.append(":").append(space); + if (this.getBuild_version() == null) { + sb.append("null"); + } else { + int __build_version_size = Math.min(this.getBuild_version().length, 128); + for (int i = 0; i < __build_version_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getBuild_version()[i]).length() > 1 ? Integer.toHexString(this.getBuild_version()[i]).substring(Integer.toHexString(this.getBuild_version()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getBuild_version()[i]).toUpperCase()); + } + if (this.getBuild_version().length > 128) sb.append(" ..."); + } + first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); @@ -358,8 +448,8 @@ public String toString(int indent, boolean prettyPrint) { public void validate() throws TException { // check for required fields - if (version == null) { - throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'version' was not present! Struct: " + toString()); + if (client_version == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'client_version' was not present! Struct: " + toString()); } } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java index 1b25c1fb2..f221c07af 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java @@ -267,16 +267,16 @@ public void read(TProtocol iprot) throws TException { case NODES: if (__field.type == TType.LIST) { { - TList _list216 = iprot.readListBegin(); - this.nodes = new ArrayList(Math.max(0, _list216.size)); - for (int _i217 = 0; - (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); - ++_i217) + TList _list232 = iprot.readListBegin(); + this.nodes = new ArrayList(Math.max(0, _list232.size)); + for (int _i233 = 0; + (_list232.size < 0) ? iprot.peekList() : (_i233 < _list232.size); + ++_i233) { - com.vesoft.nebula.HostAddr _elem218; - _elem218 = new com.vesoft.nebula.HostAddr(); - _elem218.read(iprot); - this.nodes.add(_elem218); + com.vesoft.nebula.HostAddr _elem234; + _elem234 = new com.vesoft.nebula.HostAddr(); + _elem234.read(iprot); + this.nodes.add(_elem234); } iprot.readListEnd(); } @@ -310,8 +310,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(NODES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.nodes.size())); - for (com.vesoft.nebula.HostAddr _iter219 : this.nodes) { - _iter219.write(oprot); + for (com.vesoft.nebula.HostAddr _iter235 : this.nodes) { + _iter235.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/AddEdgesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/AddEdgesRequest.java index 1f961929d..62ef38b47 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/AddEdgesRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/AddEdgesRequest.java @@ -30,23 +30,27 @@ public class AddEdgesRequest implements TBase, java.io.Serializable, Cloneable { private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); private static final TField PROP_NAMES_FIELD_DESC = new TField("prop_names", TType.LIST, (short)3); private static final TField IF_NOT_EXISTS_FIELD_DESC = new TField("if_not_exists", TType.BOOL, (short)4); - private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)5); + private static final TField IGNORE_EXISTED_INDEX_FIELD_DESC = new TField("ignore_existed_index", TType.BOOL, (short)5); + private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)6); public int space_id; public Map> parts; public List prop_names; public boolean if_not_exists; + public boolean ignore_existed_index; public RequestCommon common; public static final int SPACE_ID = 1; public static final int PARTS = 2; public static final int PROP_NAMES = 3; public static final int IF_NOT_EXISTS = 4; - public static final int COMMON = 5; + public static final int IGNORE_EXISTED_INDEX = 5; + public static final int COMMON = 6; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; private static final int __IF_NOT_EXISTS_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); + private static final int __IGNORE_EXISTED_INDEX_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); public static final Map metaDataMap; @@ -64,6 +68,8 @@ public class AddEdgesRequest implements TBase, java.io.Serializable, Cloneable { new FieldValueMetaData(TType.STRING)))); tmpMetaDataMap.put(IF_NOT_EXISTS, new FieldMetaData("if_not_exists", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(IGNORE_EXISTED_INDEX, new FieldMetaData("ignore_existed_index", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(COMMON, new FieldMetaData("common", TFieldRequirementType.OPTIONAL, new StructMetaData(TType.STRUCT, RequestCommon.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -74,13 +80,16 @@ public class AddEdgesRequest implements TBase, java.io.Serializable, Cloneable { } public AddEdgesRequest() { + this.ignore_existed_index = false; + } public AddEdgesRequest( int space_id, Map> parts, List prop_names, - boolean if_not_exists) { + boolean if_not_exists, + boolean ignore_existed_index) { this(); this.space_id = space_id; setSpace_idIsSet(true); @@ -88,6 +97,8 @@ public AddEdgesRequest( this.prop_names = prop_names; this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); } public AddEdgesRequest( @@ -95,6 +106,7 @@ public AddEdgesRequest( Map> parts, List prop_names, boolean if_not_exists, + boolean ignore_existed_index, RequestCommon common) { this(); this.space_id = space_id; @@ -103,6 +115,8 @@ public AddEdgesRequest( this.prop_names = prop_names; this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); this.common = common; } @@ -111,9 +125,10 @@ public static class Builder { private Map> parts; private List prop_names; private boolean if_not_exists; + private boolean ignore_existed_index; private RequestCommon common; - BitSet __optional_isset = new BitSet(2); + BitSet __optional_isset = new BitSet(3); public Builder() { } @@ -140,6 +155,12 @@ public Builder setIf_not_exists(final boolean if_not_exists) { return this; } + public Builder setIgnore_existed_index(final boolean ignore_existed_index) { + this.ignore_existed_index = ignore_existed_index; + __optional_isset.set(__IGNORE_EXISTED_INDEX_ISSET_ID, true); + return this; + } + public Builder setCommon(final RequestCommon common) { this.common = common; return this; @@ -155,6 +176,9 @@ public AddEdgesRequest build() { if (__optional_isset.get(__IF_NOT_EXISTS_ISSET_ID)) { result.setIf_not_exists(this.if_not_exists); } + if (__optional_isset.get(__IGNORE_EXISTED_INDEX_ISSET_ID)) { + result.setIgnore_existed_index(this.ignore_existed_index); + } result.setCommon(this.common); return result; } @@ -178,6 +202,7 @@ public AddEdgesRequest(AddEdgesRequest other) { this.prop_names = TBaseHelper.deepCopy(other.prop_names); } this.if_not_exists = TBaseHelper.deepCopy(other.if_not_exists); + this.ignore_existed_index = TBaseHelper.deepCopy(other.ignore_existed_index); if (other.isSetCommon()) { this.common = TBaseHelper.deepCopy(other.common); } @@ -281,6 +306,29 @@ public void setIf_not_existsIsSet(boolean __value) { __isset_bit_vector.set(__IF_NOT_EXISTS_ISSET_ID, __value); } + public boolean isIgnore_existed_index() { + return this.ignore_existed_index; + } + + public AddEdgesRequest setIgnore_existed_index(boolean ignore_existed_index) { + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); + return this; + } + + public void unsetIgnore_existed_index() { + __isset_bit_vector.clear(__IGNORE_EXISTED_INDEX_ISSET_ID); + } + + // Returns true if field ignore_existed_index is set (has been assigned a value) and false otherwise + public boolean isSetIgnore_existed_index() { + return __isset_bit_vector.get(__IGNORE_EXISTED_INDEX_ISSET_ID); + } + + public void setIgnore_existed_indexIsSet(boolean __value) { + __isset_bit_vector.set(__IGNORE_EXISTED_INDEX_ISSET_ID, __value); + } + public RequestCommon getCommon() { return this.common; } @@ -340,6 +388,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case IGNORE_EXISTED_INDEX: + if (__value == null) { + unsetIgnore_existed_index(); + } else { + setIgnore_existed_index((Boolean)__value); + } + break; + case COMMON: if (__value == null) { unsetCommon(); @@ -367,6 +423,9 @@ public Object getFieldValue(int fieldID) { case IF_NOT_EXISTS: return new Boolean(isIf_not_exists()); + case IGNORE_EXISTED_INDEX: + return new Boolean(isIgnore_existed_index()); + case COMMON: return getCommon(); @@ -393,6 +452,8 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.if_not_exists, that.if_not_exists)) { return false; } + if (!TBaseHelper.equalsNobinary(this.ignore_existed_index, that.ignore_existed_index)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetCommon(), that.isSetCommon(), this.common, that.common)) { return false; } return true; @@ -400,7 +461,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, parts, prop_names, if_not_exists, common}); + return Arrays.deepHashCode(new Object[] {space_id, parts, prop_names, if_not_exists, ignore_existed_index, common}); } public void read(TProtocol iprot) throws TException { @@ -483,6 +544,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case IGNORE_EXISTED_INDEX: + if (__field.type == TType.BOOL) { + this.ignore_existed_index = iprot.readBool(); + setIgnore_existed_indexIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; case COMMON: if (__field.type == TType.STRUCT) { this.common = new RequestCommon(); @@ -543,6 +612,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(IF_NOT_EXISTS_FIELD_DESC); oprot.writeBool(this.if_not_exists); oprot.writeFieldEnd(); + oprot.writeFieldBegin(IGNORE_EXISTED_INDEX_FIELD_DESC); + oprot.writeBool(this.ignore_existed_index); + oprot.writeFieldEnd(); if (this.common != null) { if (isSetCommon()) { oprot.writeFieldBegin(COMMON_FIELD_DESC); @@ -605,6 +677,13 @@ public String toString(int indent, boolean prettyPrint) { sb.append(":").append(space); sb.append(TBaseHelper.toString(this.isIf_not_exists(), indent + 1, prettyPrint)); first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("ignore_existed_index"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIgnore_existed_index(), indent + 1, prettyPrint)); + first = false; if (isSetCommon()) { if (!first) sb.append("," + newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/AddVerticesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/AddVerticesRequest.java index 653892acd..e7af80f5b 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/AddVerticesRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/AddVerticesRequest.java @@ -30,23 +30,27 @@ public class AddVerticesRequest implements TBase, java.io.Serializable, Cloneabl private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); private static final TField PROP_NAMES_FIELD_DESC = new TField("prop_names", TType.MAP, (short)3); private static final TField IF_NOT_EXISTS_FIELD_DESC = new TField("if_not_exists", TType.BOOL, (short)4); - private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)5); + private static final TField IGNORE_EXISTED_INDEX_FIELD_DESC = new TField("ignore_existed_index", TType.BOOL, (short)5); + private static final TField COMMON_FIELD_DESC = new TField("common", TType.STRUCT, (short)6); public int space_id; public Map> parts; public Map> prop_names; public boolean if_not_exists; + public boolean ignore_existed_index; public RequestCommon common; public static final int SPACE_ID = 1; public static final int PARTS = 2; public static final int PROP_NAMES = 3; public static final int IF_NOT_EXISTS = 4; - public static final int COMMON = 5; + public static final int IGNORE_EXISTED_INDEX = 5; + public static final int COMMON = 6; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; private static final int __IF_NOT_EXISTS_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); + private static final int __IGNORE_EXISTED_INDEX_ISSET_ID = 2; + private BitSet __isset_bit_vector = new BitSet(3); public static final Map metaDataMap; @@ -66,6 +70,8 @@ public class AddVerticesRequest implements TBase, java.io.Serializable, Cloneabl new FieldValueMetaData(TType.STRING))))); tmpMetaDataMap.put(IF_NOT_EXISTS, new FieldMetaData("if_not_exists", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.BOOL))); + tmpMetaDataMap.put(IGNORE_EXISTED_INDEX, new FieldMetaData("ignore_existed_index", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(COMMON, new FieldMetaData("common", TFieldRequirementType.OPTIONAL, new StructMetaData(TType.STRUCT, RequestCommon.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -76,13 +82,16 @@ public class AddVerticesRequest implements TBase, java.io.Serializable, Cloneabl } public AddVerticesRequest() { + this.ignore_existed_index = false; + } public AddVerticesRequest( int space_id, Map> parts, Map> prop_names, - boolean if_not_exists) { + boolean if_not_exists, + boolean ignore_existed_index) { this(); this.space_id = space_id; setSpace_idIsSet(true); @@ -90,6 +99,8 @@ public AddVerticesRequest( this.prop_names = prop_names; this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); } public AddVerticesRequest( @@ -97,6 +108,7 @@ public AddVerticesRequest( Map> parts, Map> prop_names, boolean if_not_exists, + boolean ignore_existed_index, RequestCommon common) { this(); this.space_id = space_id; @@ -105,6 +117,8 @@ public AddVerticesRequest( this.prop_names = prop_names; this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); this.common = common; } @@ -113,9 +127,10 @@ public static class Builder { private Map> parts; private Map> prop_names; private boolean if_not_exists; + private boolean ignore_existed_index; private RequestCommon common; - BitSet __optional_isset = new BitSet(2); + BitSet __optional_isset = new BitSet(3); public Builder() { } @@ -142,6 +157,12 @@ public Builder setIf_not_exists(final boolean if_not_exists) { return this; } + public Builder setIgnore_existed_index(final boolean ignore_existed_index) { + this.ignore_existed_index = ignore_existed_index; + __optional_isset.set(__IGNORE_EXISTED_INDEX_ISSET_ID, true); + return this; + } + public Builder setCommon(final RequestCommon common) { this.common = common; return this; @@ -157,6 +178,9 @@ public AddVerticesRequest build() { if (__optional_isset.get(__IF_NOT_EXISTS_ISSET_ID)) { result.setIf_not_exists(this.if_not_exists); } + if (__optional_isset.get(__IGNORE_EXISTED_INDEX_ISSET_ID)) { + result.setIgnore_existed_index(this.ignore_existed_index); + } result.setCommon(this.common); return result; } @@ -180,6 +204,7 @@ public AddVerticesRequest(AddVerticesRequest other) { this.prop_names = TBaseHelper.deepCopy(other.prop_names); } this.if_not_exists = TBaseHelper.deepCopy(other.if_not_exists); + this.ignore_existed_index = TBaseHelper.deepCopy(other.ignore_existed_index); if (other.isSetCommon()) { this.common = TBaseHelper.deepCopy(other.common); } @@ -283,6 +308,29 @@ public void setIf_not_existsIsSet(boolean __value) { __isset_bit_vector.set(__IF_NOT_EXISTS_ISSET_ID, __value); } + public boolean isIgnore_existed_index() { + return this.ignore_existed_index; + } + + public AddVerticesRequest setIgnore_existed_index(boolean ignore_existed_index) { + this.ignore_existed_index = ignore_existed_index; + setIgnore_existed_indexIsSet(true); + return this; + } + + public void unsetIgnore_existed_index() { + __isset_bit_vector.clear(__IGNORE_EXISTED_INDEX_ISSET_ID); + } + + // Returns true if field ignore_existed_index is set (has been assigned a value) and false otherwise + public boolean isSetIgnore_existed_index() { + return __isset_bit_vector.get(__IGNORE_EXISTED_INDEX_ISSET_ID); + } + + public void setIgnore_existed_indexIsSet(boolean __value) { + __isset_bit_vector.set(__IGNORE_EXISTED_INDEX_ISSET_ID, __value); + } + public RequestCommon getCommon() { return this.common; } @@ -342,6 +390,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case IGNORE_EXISTED_INDEX: + if (__value == null) { + unsetIgnore_existed_index(); + } else { + setIgnore_existed_index((Boolean)__value); + } + break; + case COMMON: if (__value == null) { unsetCommon(); @@ -369,6 +425,9 @@ public Object getFieldValue(int fieldID) { case IF_NOT_EXISTS: return new Boolean(isIf_not_exists()); + case IGNORE_EXISTED_INDEX: + return new Boolean(isIgnore_existed_index()); + case COMMON: return getCommon(); @@ -395,6 +454,8 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.if_not_exists, that.if_not_exists)) { return false; } + if (!TBaseHelper.equalsNobinary(this.ignore_existed_index, that.ignore_existed_index)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetCommon(), that.isSetCommon(), this.common, that.common)) { return false; } return true; @@ -402,7 +463,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, parts, prop_names, if_not_exists, common}); + return Arrays.deepHashCode(new Object[] {space_id, parts, prop_names, if_not_exists, ignore_existed_index, common}); } public void read(TProtocol iprot) throws TException { @@ -499,6 +560,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case IGNORE_EXISTED_INDEX: + if (__field.type == TType.BOOL) { + this.ignore_existed_index = iprot.readBool(); + setIgnore_existed_indexIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; case COMMON: if (__field.type == TType.STRUCT) { this.common = new RequestCommon(); @@ -566,6 +635,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(IF_NOT_EXISTS_FIELD_DESC); oprot.writeBool(this.if_not_exists); oprot.writeFieldEnd(); + oprot.writeFieldBegin(IGNORE_EXISTED_INDEX_FIELD_DESC); + oprot.writeBool(this.ignore_existed_index); + oprot.writeFieldEnd(); if (this.common != null) { if (isSetCommon()) { oprot.writeFieldBegin(COMMON_FIELD_DESC); @@ -628,6 +700,13 @@ public String toString(int indent, boolean prettyPrint) { sb.append(":").append(space); sb.append(TBaseHelper.toString(this.isIf_not_exists(), indent + 1, prettyPrint)); first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("ignore_existed_index"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.isIgnore_existed_index(), indent + 1, prettyPrint)); + first = false; if (isSetCommon()) { if (!first) sb.append("," + newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java new file mode 100644 index 000000000..4712c0e7f --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java @@ -0,0 +1,439 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetValueRequest implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetValueRequest"); + private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)2); + private static final TField KEY_FIELD_DESC = new TField("key", TType.STRING, (short)3); + + public int space_id; + public int part_id; + public byte[] key; + public static final int SPACE_ID = 1; + public static final int PART_ID = 2; + public static final int KEY = 3; + + // isset id assignments + private static final int __SPACE_ID_ISSET_ID = 0; + private static final int __PART_ID_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(KEY, new FieldMetaData("key", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetValueRequest.class, metaDataMap); + } + + public GetValueRequest() { + } + + public GetValueRequest( + int space_id, + int part_id, + byte[] key) { + this(); + this.space_id = space_id; + setSpace_idIsSet(true); + this.part_id = part_id; + setPart_idIsSet(true); + this.key = key; + } + + public static class Builder { + private int space_id; + private int part_id; + private byte[] key; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setSpace_id(final int space_id) { + this.space_id = space_id; + __optional_isset.set(__SPACE_ID_ISSET_ID, true); + return this; + } + + public Builder setPart_id(final int part_id) { + this.part_id = part_id; + __optional_isset.set(__PART_ID_ISSET_ID, true); + return this; + } + + public Builder setKey(final byte[] key) { + this.key = key; + return this; + } + + public GetValueRequest build() { + GetValueRequest result = new GetValueRequest(); + if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { + result.setSpace_id(this.space_id); + } + if (__optional_isset.get(__PART_ID_ISSET_ID)) { + result.setPart_id(this.part_id); + } + result.setKey(this.key); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetValueRequest(GetValueRequest other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.space_id = TBaseHelper.deepCopy(other.space_id); + this.part_id = TBaseHelper.deepCopy(other.part_id); + if (other.isSetKey()) { + this.key = TBaseHelper.deepCopy(other.key); + } + } + + public GetValueRequest deepCopy() { + return new GetValueRequest(this); + } + + public int getSpace_id() { + return this.space_id; + } + + public GetValueRequest setSpace_id(int space_id) { + this.space_id = space_id; + setSpace_idIsSet(true); + return this; + } + + public void unsetSpace_id() { + __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + } + + // Returns true if field space_id is set (has been assigned a value) and false otherwise + public boolean isSetSpace_id() { + return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + } + + public void setSpace_idIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + } + + public int getPart_id() { + return this.part_id; + } + + public GetValueRequest setPart_id(int part_id) { + this.part_id = part_id; + setPart_idIsSet(true); + return this; + } + + public void unsetPart_id() { + __isset_bit_vector.clear(__PART_ID_ISSET_ID); + } + + // Returns true if field part_id is set (has been assigned a value) and false otherwise + public boolean isSetPart_id() { + return __isset_bit_vector.get(__PART_ID_ISSET_ID); + } + + public void setPart_idIsSet(boolean __value) { + __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); + } + + public byte[] getKey() { + return this.key; + } + + public GetValueRequest setKey(byte[] key) { + this.key = key; + return this; + } + + public void unsetKey() { + this.key = null; + } + + // Returns true if field key is set (has been assigned a value) and false otherwise + public boolean isSetKey() { + return this.key != null; + } + + public void setKeyIsSet(boolean __value) { + if (!__value) { + this.key = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SPACE_ID: + if (__value == null) { + unsetSpace_id(); + } else { + setSpace_id((Integer)__value); + } + break; + + case PART_ID: + if (__value == null) { + unsetPart_id(); + } else { + setPart_id((Integer)__value); + } + break; + + case KEY: + if (__value == null) { + unsetKey(); + } else { + setKey((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SPACE_ID: + return new Integer(getSpace_id()); + + case PART_ID: + return new Integer(getPart_id()); + + case KEY: + return getKey(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetValueRequest)) + return false; + GetValueRequest that = (GetValueRequest)_that; + + if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetKey(), that.isSetKey(), this.key, that.key)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {space_id, part_id, key}); + } + + @Override + public int compareTo(GetValueRequest other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(part_id, other.part_id); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetKey()).compareTo(other.isSetKey()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(key, other.key); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SPACE_ID: + if (__field.type == TType.I32) { + this.space_id = iprot.readI32(); + setSpace_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PART_ID: + if (__field.type == TType.I32) { + this.part_id = iprot.readI32(); + setPart_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case KEY: + if (__field.type == TType.STRING) { + this.key = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); + oprot.writeI32(this.space_id); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(PART_ID_FIELD_DESC); + oprot.writeI32(this.part_id); + oprot.writeFieldEnd(); + if (this.key != null) { + oprot.writeFieldBegin(KEY_FIELD_DESC); + oprot.writeBinary(this.key); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetValueRequest"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("space_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("part_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("key"); + sb.append(space); + sb.append(":").append(space); + if (this.getKey() == null) { + sb.append("null"); + } else { + int __key_size = Math.min(this.getKey().length, 128); + for (int i = 0; i < __key_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getKey()[i]).length() > 1 ? Integer.toHexString(this.getKey()[i]).substring(Integer.toHexString(this.getKey()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getKey()[i]).toUpperCase()); + } + if (this.getKey().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java new file mode 100644 index 000000000..8a0b704b8 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java @@ -0,0 +1,365 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.storage; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class GetValueResponse implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("GetValueResponse"); + private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); + private static final TField VALUE_FIELD_DESC = new TField("value", TType.STRING, (short)2); + + public ResponseCommon result; + public byte[] value; + public static final int RESULT = 1; + public static final int VALUE = 2; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, + new StructMetaData(TType.STRUCT, ResponseCommon.class))); + tmpMetaDataMap.put(VALUE, new FieldMetaData("value", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(GetValueResponse.class, metaDataMap); + } + + public GetValueResponse() { + } + + public GetValueResponse( + ResponseCommon result) { + this(); + this.result = result; + } + + public GetValueResponse( + ResponseCommon result, + byte[] value) { + this(); + this.result = result; + this.value = value; + } + + public static class Builder { + private ResponseCommon result; + private byte[] value; + + public Builder() { + } + + public Builder setResult(final ResponseCommon result) { + this.result = result; + return this; + } + + public Builder setValue(final byte[] value) { + this.value = value; + return this; + } + + public GetValueResponse build() { + GetValueResponse result = new GetValueResponse(); + result.setResult(this.result); + result.setValue(this.value); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public GetValueResponse(GetValueResponse other) { + if (other.isSetResult()) { + this.result = TBaseHelper.deepCopy(other.result); + } + if (other.isSetValue()) { + this.value = TBaseHelper.deepCopy(other.value); + } + } + + public GetValueResponse deepCopy() { + return new GetValueResponse(this); + } + + public ResponseCommon getResult() { + return this.result; + } + + public GetValueResponse setResult(ResponseCommon result) { + this.result = result; + return this; + } + + public void unsetResult() { + this.result = null; + } + + // Returns true if field result is set (has been assigned a value) and false otherwise + public boolean isSetResult() { + return this.result != null; + } + + public void setResultIsSet(boolean __value) { + if (!__value) { + this.result = null; + } + } + + public byte[] getValue() { + return this.value; + } + + public GetValueResponse setValue(byte[] value) { + this.value = value; + return this; + } + + public void unsetValue() { + this.value = null; + } + + // Returns true if field value is set (has been assigned a value) and false otherwise + public boolean isSetValue() { + return this.value != null; + } + + public void setValueIsSet(boolean __value) { + if (!__value) { + this.value = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case RESULT: + if (__value == null) { + unsetResult(); + } else { + setResult((ResponseCommon)__value); + } + break; + + case VALUE: + if (__value == null) { + unsetValue(); + } else { + setValue((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case RESULT: + return getResult(); + + case VALUE: + return getValue(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof GetValueResponse)) + return false; + GetValueResponse that = (GetValueResponse)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetValue(), that.isSetValue(), this.value, that.value)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {result, value}); + } + + @Override + public int compareTo(GetValueResponse other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(result, other.result); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(value, other.value); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case RESULT: + if (__field.type == TType.STRUCT) { + this.result = new ResponseCommon(); + this.result.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case VALUE: + if (__field.type == TType.STRING) { + this.value = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.result != null) { + oprot.writeFieldBegin(RESULT_FIELD_DESC); + this.result.write(oprot); + oprot.writeFieldEnd(); + } + if (this.value != null) { + oprot.writeFieldBegin(VALUE_FIELD_DESC); + oprot.writeBinary(this.value); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("GetValueResponse"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("result"); + sb.append(space); + sb.append(":").append(space); + if (this.getResult() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("value"); + sb.append(space); + sb.append(":").append(space); + if (this.getValue() == null) { + sb.append("null"); + } else { + int __value_size = Math.min(this.getValue().length, 128); + for (int i = 0; i < __value_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getValue()[i]).length() > 1 ? Integer.toHexString(this.getValue()[i]).substring(Integer.toHexString(this.getValue()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getValue()[i]).toUpperCase()); + } + if (this.getValue().length > 128) sb.append(" ..."); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + if (result == null) { + throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); + } + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java index abb83cebe..232c2aebd 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ScanCursor.java @@ -26,24 +26,17 @@ @SuppressWarnings({ "unused", "serial" }) public class ScanCursor implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("ScanCursor"); - private static final TField HAS_NEXT_FIELD_DESC = new TField("has_next", TType.BOOL, (short)3); - private static final TField NEXT_CURSOR_FIELD_DESC = new TField("next_cursor", TType.STRING, (short)4); + private static final TField NEXT_CURSOR_FIELD_DESC = new TField("next_cursor", TType.STRING, (short)1); - public boolean has_next; public byte[] next_cursor; - public static final int HAS_NEXT = 3; - public static final int NEXT_CURSOR = 4; + public static final int NEXT_CURSOR = 1; // isset id assignments - private static final int __HAS_NEXT_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(HAS_NEXT, new FieldMetaData("has_next", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(NEXT_CURSOR, new FieldMetaData("next_cursor", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -57,36 +50,17 @@ public ScanCursor() { } public ScanCursor( - boolean has_next) { - this(); - this.has_next = has_next; - setHas_nextIsSet(true); - } - - public ScanCursor( - boolean has_next, byte[] next_cursor) { this(); - this.has_next = has_next; - setHas_nextIsSet(true); this.next_cursor = next_cursor; } public static class Builder { - private boolean has_next; private byte[] next_cursor; - BitSet __optional_isset = new BitSet(1); - public Builder() { } - public Builder setHas_next(final boolean has_next) { - this.has_next = has_next; - __optional_isset.set(__HAS_NEXT_ISSET_ID, true); - return this; - } - public Builder setNext_cursor(final byte[] next_cursor) { this.next_cursor = next_cursor; return this; @@ -94,9 +68,6 @@ public Builder setNext_cursor(final byte[] next_cursor) { public ScanCursor build() { ScanCursor result = new ScanCursor(); - if (__optional_isset.get(__HAS_NEXT_ISSET_ID)) { - result.setHas_next(this.has_next); - } result.setNext_cursor(this.next_cursor); return result; } @@ -110,9 +81,6 @@ public static Builder builder() { * Performs a deep copy on other. */ public ScanCursor(ScanCursor other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.has_next = TBaseHelper.deepCopy(other.has_next); if (other.isSetNext_cursor()) { this.next_cursor = TBaseHelper.deepCopy(other.next_cursor); } @@ -122,29 +90,6 @@ public ScanCursor deepCopy() { return new ScanCursor(this); } - public boolean isHas_next() { - return this.has_next; - } - - public ScanCursor setHas_next(boolean has_next) { - this.has_next = has_next; - setHas_nextIsSet(true); - return this; - } - - public void unsetHas_next() { - __isset_bit_vector.clear(__HAS_NEXT_ISSET_ID); - } - - // Returns true if field has_next is set (has been assigned a value) and false otherwise - public boolean isSetHas_next() { - return __isset_bit_vector.get(__HAS_NEXT_ISSET_ID); - } - - public void setHas_nextIsSet(boolean __value) { - __isset_bit_vector.set(__HAS_NEXT_ISSET_ID, __value); - } - public byte[] getNext_cursor() { return this.next_cursor; } @@ -171,14 +116,6 @@ public void setNext_cursorIsSet(boolean __value) { public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case HAS_NEXT: - if (__value == null) { - unsetHas_next(); - } else { - setHas_next((Boolean)__value); - } - break; - case NEXT_CURSOR: if (__value == null) { unsetNext_cursor(); @@ -194,9 +131,6 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case HAS_NEXT: - return new Boolean(isHas_next()); - case NEXT_CURSOR: return getNext_cursor(); @@ -215,8 +149,6 @@ public boolean equals(Object _that) { return false; ScanCursor that = (ScanCursor)_that; - if (!TBaseHelper.equalsNobinary(this.has_next, that.has_next)) { return false; } - if (!TBaseHelper.equalsSlow(this.isSetNext_cursor(), that.isSetNext_cursor(), this.next_cursor, that.next_cursor)) { return false; } return true; @@ -224,7 +156,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {has_next, next_cursor}); + return Arrays.deepHashCode(new Object[] {next_cursor}); } @Override @@ -239,14 +171,6 @@ public int compareTo(ScanCursor other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetHas_next()).compareTo(other.isSetHas_next()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(has_next, other.has_next); - if (lastComparison != 0) { - return lastComparison; - } lastComparison = Boolean.valueOf(isSetNext_cursor()).compareTo(other.isSetNext_cursor()); if (lastComparison != 0) { return lastComparison; @@ -269,14 +193,6 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case HAS_NEXT: - if (__field.type == TType.BOOL) { - this.has_next = iprot.readBool(); - setHas_nextIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; case NEXT_CURSOR: if (__field.type == TType.STRING) { this.next_cursor = iprot.readBinary(); @@ -301,9 +217,6 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(HAS_NEXT_FIELD_DESC); - oprot.writeBool(this.has_next); - oprot.writeFieldEnd(); if (this.next_cursor != null) { if (isSetNext_cursor()) { oprot.writeFieldBegin(NEXT_CURSOR_FIELD_DESC); @@ -331,15 +244,8 @@ public String toString(int indent, boolean prettyPrint) { sb.append(newLine); boolean first = true; - sb.append(indentStr); - sb.append("has_next"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isHas_next(), indent + 1, prettyPrint)); - first = false; if (isSetNext_cursor()) { - if (!first) sb.append("," + newLine); sb.append(indentStr); sb.append("next_cursor"); sb.append(space); diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java index 6387d5455..edc7a965f 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/PartScanInfo.java @@ -20,7 +20,7 @@ public class PartScanInfo implements Serializable { public PartScanInfo(int part, HostAddress leader) { this.part = part; this.leader = leader; - cursor = new ScanCursor(true, "".getBytes()); + cursor = new ScanCursor("".getBytes()); } public int getPart() { diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java index efd8e9612..28dda0019 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanResultIterator.java @@ -104,9 +104,9 @@ protected boolean isSuccessful(ScanResponse response) { } protected void handleSucceedResult(AtomicInteger existSuccess, ScanResponse response, - PartScanInfo partInfo) { + PartScanInfo partInfo) { existSuccess.addAndGet(1); - if (!response.getCursors().get(partInfo.getPart()).has_next) { + if (response.getCursors().get(partInfo.getPart()).next_cursor == null) { partScanQueue.dropPart(partInfo); } else { partInfo.setCursor(response.getCursors().get(partInfo.getPart())); @@ -114,7 +114,7 @@ protected void handleSucceedResult(AtomicInteger existSuccess, ScanResponse resp } protected void handleFailedResult(ScanResponse response, PartScanInfo partInfo, - List exceptions) { + List exceptions) { for (PartitionResult partResult : response.getResult().getFailed_parts()) { if (partResult.code == ErrorCode.E_LEADER_CHANGED) { freshLeader(spaceName, partInfo.getPart(), partResult.getLeader()); diff --git a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java index ce5ee366a..6327423f9 100644 --- a/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java +++ b/client/src/test/java/com/vesoft/nebula/client/storage/scan/PartScanQueueTest.java @@ -61,7 +61,7 @@ private Set mockPartScanInfo() { partScanInfoSet.add(new PartScanInfo(4, new HostAddress("127.0.0.1", 2))); PartScanInfo partScanInfo = new PartScanInfo(5, new HostAddress("127.0.0.1", 3)); - partScanInfo.setCursor(new ScanCursor(true, "cursor".getBytes())); + partScanInfo.setCursor(new ScanCursor("cursor".getBytes())); partScanInfoSet.add(partScanInfo); return partScanInfoSet; } diff --git a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java index f5be0c716..2a7fe9179 100644 --- a/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java +++ b/client/src/test/java/com/vesoft/nebula/encoder/MetaCacheImplTest.java @@ -30,69 +30,69 @@ public class MetaCacheImplTest implements MetaCache { private Schema genNoDefaultVal() { List columns = new ArrayList<>(); ColumnDef columnDef = new ColumnDef(("Col01").getBytes(), - new ColumnTypeDef(PropertyType.BOOL)); + new ColumnTypeDef(PropertyType.BOOL)); columns.add(columnDef); columnDef = new ColumnDef(("Col02").getBytes(), - new ColumnTypeDef(PropertyType.INT8)); + new ColumnTypeDef(PropertyType.INT8)); columns.add(columnDef); columnDef = new ColumnDef(("Col03").getBytes(), - new ColumnTypeDef(PropertyType.INT16)); + new ColumnTypeDef(PropertyType.INT16)); columns.add(columnDef); columnDef = new ColumnDef(("Col04").getBytes(), - new ColumnTypeDef(PropertyType.INT32)); + new ColumnTypeDef(PropertyType.INT32)); columns.add(columnDef); columnDef = new ColumnDef(("Col05").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columns.add(columnDef); columnDef = new ColumnDef(("Col06").getBytes(), - new ColumnTypeDef(PropertyType.FLOAT)); + new ColumnTypeDef(PropertyType.FLOAT)); columns.add(columnDef); columnDef = new ColumnDef(("Col07").getBytes(), - new ColumnTypeDef(PropertyType.DOUBLE)); + new ColumnTypeDef(PropertyType.DOUBLE)); columns.add(columnDef); columnDef = new ColumnDef(("Col08").getBytes(), - new ColumnTypeDef(PropertyType.STRING)); + new ColumnTypeDef(PropertyType.STRING)); columns.add(columnDef); columnDef = new ColumnDef(("Col09").getBytes(), - new ColumnTypeDef(PropertyType.FIXED_STRING, (short)12, null)); + new ColumnTypeDef(PropertyType.FIXED_STRING, (short) 12, null)); columns.add(columnDef); columnDef = new ColumnDef(("Col10").getBytes(), - new ColumnTypeDef(PropertyType.TIMESTAMP)); + new ColumnTypeDef(PropertyType.TIMESTAMP)); columns.add(columnDef); columnDef = new ColumnDef(("Col11").getBytes(), - new ColumnTypeDef(PropertyType.DATE)); + new ColumnTypeDef(PropertyType.DATE)); columns.add(columnDef); columnDef = new ColumnDef(("Col12").getBytes(), - new ColumnTypeDef(PropertyType.TIME)); + new ColumnTypeDef(PropertyType.TIME)); columns.add(columnDef); columnDef = new ColumnDef(("Col13").getBytes(), - new ColumnTypeDef(PropertyType.DATETIME)); + new ColumnTypeDef(PropertyType.DATETIME)); columns.add(columnDef); columnDef = new ColumnDef(("Col14").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columnDef.setNullable(true); columns.add(columnDef); columnDef = new ColumnDef(("Col15").getBytes(), - new ColumnTypeDef(PropertyType.INT32)); + new ColumnTypeDef(PropertyType.INT32)); columnDef.setNullable(true); columns.add(columnDef); columnDef = new ColumnDef(("Col16").getBytes(), - new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.POINT)); + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short) 0, GeoShape.POINT)); columns.add(columnDef); columnDef = new ColumnDef(("Col17").getBytes(), - new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.LINESTRING)); + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short) 0, GeoShape.LINESTRING)); columns.add(columnDef); columnDef = new ColumnDef(("Col18").getBytes(), - new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.POLYGON)); + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short) 0, GeoShape.POLYGON)); columns.add(columnDef); columnDef = new ColumnDef(("Col19").getBytes(), - new ColumnTypeDef(PropertyType.GEOGRAPHY, (short)0, GeoShape.ANY)); + new ColumnTypeDef(PropertyType.GEOGRAPHY, (short) 0, GeoShape.ANY)); columnDef.setNullable(true); columns.add(columnDef); return new Schema(columns, null); @@ -101,22 +101,22 @@ private Schema genNoDefaultVal() { private Schema genWithDefaultVal() { List columns = new ArrayList<>(); ColumnDef columnDef1 = new ColumnDef(("Col01").getBytes(), - new ColumnTypeDef(PropertyType.BOOL)); + new ColumnTypeDef(PropertyType.BOOL)); columnDef1.setDefault_value("".getBytes()); columns.add(columnDef1); ColumnDef columnDef2 = new ColumnDef(("Col02").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columnDef2.setDefault_value("".getBytes()); columns.add(columnDef2); ColumnDef columnDef3 = new ColumnDef(("Col03").getBytes(), - new ColumnTypeDef(PropertyType.STRING)); + new ColumnTypeDef(PropertyType.STRING)); columnDef3.setDefault_value("".getBytes()); columns.add(columnDef3); ColumnDef columnDef4 = new ColumnDef(("Col04").getBytes(), - new ColumnTypeDef(PropertyType.FIXED_STRING)); + new ColumnTypeDef(PropertyType.FIXED_STRING)); columnDef4.setDefault_value("".getBytes()); columns.add(columnDef4); return new Schema(columns, null); @@ -131,11 +131,11 @@ private TagItem createPersonTag() { List columns = new ArrayList<>(); ColumnDef columnDef1 = new ColumnDef(("name").getBytes(), - new ColumnTypeDef(PropertyType.STRING)); + new ColumnTypeDef(PropertyType.STRING)); columns.add(columnDef1); ColumnDef columnDef2 = new ColumnDef(("age").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columns.add(columnDef2); tagItem.schema = new Schema(columns, null); @@ -151,11 +151,11 @@ private EdgeItem createFriendEdge() { List columns = new ArrayList<>(); ColumnDef columnDef1 = new ColumnDef(("start").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columns.add(columnDef1); ColumnDef columnDef2 = new ColumnDef(("end").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columns.add(columnDef2); edgeItem.schema = new Schema(columns, null); @@ -165,7 +165,7 @@ private EdgeItem createFriendEdge() { public Schema genEmptyString() { List columns = new ArrayList<>(); ColumnDef columnDef = new ColumnDef(("Col01").getBytes(), - new ColumnTypeDef(PropertyType.STRING)); + new ColumnTypeDef(PropertyType.STRING)); columns.add(columnDef); return new Schema(columns, null); } @@ -173,7 +173,7 @@ public Schema genEmptyString() { public Schema genWithoutString() { List columns = new ArrayList<>(); ColumnDef columnDef = new ColumnDef(("Col01").getBytes(), - new ColumnTypeDef(PropertyType.INT64)); + new ColumnTypeDef(PropertyType.INT64)); columns.add(columnDef); return new Schema(columns, null); } @@ -185,12 +185,13 @@ public Schema genWithoutProp() { public MetaCacheImplTest() { spaceItem.space_id = 1; SpaceDesc spaceDesc = new SpaceDesc("test_space".getBytes(), - 3, - 1, - "utf-8".getBytes(), - "utf-8".getBytes(), - new ColumnTypeDef( - PropertyType.FIXED_STRING, (short)20, null)); + 3, + 1, + "utf-8".getBytes(), + "utf-8".getBytes(), + new ColumnTypeDef( + PropertyType.FIXED_STRING, (short) 20, null), + Arrays.asList()); this.spaceItem = spaceItem; this.spaceItem.properties = spaceDesc; From 41f6366ce8f3ad2181ad780d78605f46f4ee8510 Mon Sep 17 00:00:00 2001 From: Anqi Date: Mon, 27 Dec 2021 18:37:32 +0800 Subject: [PATCH 19/25] update thrift (#411) --- client/src/main/generated/LogEntry.java | 355 - .../com/vesoft/nebula/CheckpointInfo.java | 201 +- .../com/vesoft/nebula/ErrorCode.java | 1 + .../vesoft/nebula/PartitionBackupInfo.java | 290 - .../generated/com/vesoft/nebula/Value.java | 42 + .../nebula/graph/GraphAdminService.java | 644 -- .../nebula/graph/ListAllSessionsReq.java | 174 - .../nebula/graph/ListAllSessionsResp.java | 360 - .../vesoft/nebula/graph/ListSessionsReq.java | 174 - .../vesoft/nebula/graph/ListSessionsResp.java | 438 -- .../com/vesoft/nebula/graph/QueryDesc.java | 630 -- .../com/vesoft/nebula/graph/QueryStatus.java | 46 - .../com/vesoft/nebula/graph/Session.java | 993 --- .../com/vesoft/nebula/meta/AddGroupReq.java | 375 - .../nebula/meta/AddHostIntoZoneReq.java | 356 - .../nebula/meta/AddHostsIntoZoneReq.java | 22 +- .../vesoft/nebula/meta/AddListenerReq.java | 22 +- .../nebula/meta/AddZoneIntoGroupReq.java | 360 - .../com/vesoft/nebula/meta/AddZoneReq.java | 376 - .../com/vesoft/nebula/meta/AgentHBReq.java | 459 ++ .../{ListGroupsResp.java => AgentHBResp.java} | 134 +- .../com/vesoft/nebula/meta/BackupMeta.java | 210 +- .../com/vesoft/nebula/meta/BalanceReq.java | 644 -- .../com/vesoft/nebula/meta/BalanceResp.java | 564 -- .../vesoft/nebula/meta/CreateBackupReq.java | 20 +- .../nebula/meta/CreateEdgeIndexReq.java | 117 +- .../vesoft/nebula/meta/CreateTagIndexReq.java | 117 +- .../com/vesoft/nebula/meta/DropGroupReq.java | 270 - .../nebula/meta/DropHostFromZoneReq.java | 356 - .../nebula/meta/DropZoneFromGroupReq.java | 360 - .../com/vesoft/nebula/meta/FTIndex.java | 20 +- .../com/vesoft/nebula/meta/GetConfigResp.java | 22 +- .../com/vesoft/nebula/meta/GetGroupReq.java | 270 - .../com/vesoft/nebula/meta/GetGroupResp.java | 476 -- .../com/vesoft/nebula/meta/GetStatisReq.java | 267 - .../com/vesoft/nebula/meta/GetStatisResp.java | 457 -- .../com/vesoft/nebula/meta/GetZoneResp.java | 22 +- .../com/vesoft/nebula/meta/Group.java | 375 - .../com/vesoft/nebula/meta/HBReq.java | 190 +- .../{BackupInfo.java => HostBackupInfo.java} | 130 +- .../com/vesoft/nebula/meta/HostRole.java | 5 +- .../com/vesoft/nebula/meta/IndexItem.java | 95 +- .../com/vesoft/nebula/meta/IndexParams.java | 359 + .../com/vesoft/nebula/meta/KillQueryReq.java | 44 +- .../vesoft/nebula/meta/LeaderBalanceReq.java | 174 - .../nebula/meta/ListAllSessionsReq.java | 174 - .../nebula/meta/ListAllSessionsResp.java | 438 -- .../nebula/meta/ListClusterInfoResp.java | 238 +- .../vesoft/nebula/meta/ListConfigsResp.java | 22 +- .../nebula/meta/ListEdgeIndexesResp.java | 22 +- .../vesoft/nebula/meta/ListFTClientsResp.java | 22 +- .../vesoft/nebula/meta/ListFTIndexesResp.java | 28 +- .../com/vesoft/nebula/meta/ListGroupsReq.java | 174 - .../nebula/meta/ListIndexStatusResp.java | 22 +- .../vesoft/nebula/meta/ListListenerResp.java | 22 +- .../com/vesoft/nebula/meta/ListRolesResp.java | 22 +- .../vesoft/nebula/meta/ListSessionsResp.java | 22 +- .../vesoft/nebula/meta/ListSnapshotsResp.java | 22 +- .../nebula/meta/ListTagIndexesResp.java | 22 +- .../com/vesoft/nebula/meta/ListUsersResp.java | 26 +- .../com/vesoft/nebula/meta/ListZonesResp.java | 22 +- .../com/vesoft/nebula/meta/MergeZoneReq.java | 20 +- .../com/vesoft/nebula/meta/MetaService.java | 6632 +++++++++-------- .../com/vesoft/nebula/meta/PropertyType.java | 88 - .../com/vesoft/nebula/meta/RegConfigReq.java | 22 +- .../vesoft/nebula/meta/RestoreMetaReq.java | 42 +- .../com/vesoft/nebula/meta/SchemaID.java | 239 - .../{NodeInfo.java => meta/ServiceInfo.java} | 291 +- .../com/vesoft/nebula/meta/Session.java | 56 +- .../vesoft/nebula/meta/SessionContext.java | 839 --- .../com/vesoft/nebula/meta/SessionSchema.java | 607 -- .../nebula/meta/SignInFTServiceReq.java | 22 +- .../vesoft/nebula/meta/SpaceBackupInfo.java | 102 +- .../com/vesoft/nebula/meta/StatisItem.java | 927 --- .../vesoft/nebula/meta/UpdateSessionsReq.java | 22 +- .../nebula/meta/UpdateSessionsResp.java | 52 +- .../com/vesoft/nebula/meta/Zone.java | 22 +- .../nebula/storage/BlockingSignRequest.java | 122 +- .../nebula/storage/ChainAddEdgesRequest.java | 66 +- .../storage/ChainUpdateEdgeRequest.java | 20 +- .../vesoft/nebula/storage/CheckPeersReq.java | 22 +- .../nebula/storage/CreateCPRequest.java | 122 +- .../vesoft/nebula/storage/CreateCPResp.java | 22 +- .../vesoft/nebula/storage/DropCPRequest.java | 122 +- .../nebula/storage/GeneralStorageService.java | 1743 ----- .../nebula/storage/GetLeaderPartsResp.java | 44 +- .../nebula/storage/GetValueRequest.java | 439 -- .../nebula/storage/GetValueResponse.java | 365 - .../nebula/storage/GraphStorageService.java | 152 +- .../storage/InternalStorageService.java | 16 +- .../nebula/storage/InternalTxnRequest.java | 70 +- .../nebula/storage/RebuildIndexRequest.java | 20 +- .../nebula/storage/ScanEdgeResponse.java | 432 -- .../nebula/storage/ScanVertexResponse.java | 432 -- .../nebula/storage/StorageAdminService.java | 658 +- .../storage/GraphStorageConnection.java | 3 - .../storage/scan/ScanEdgeResultIterator.java | 3 - .../scan/ScanVertexResultIterator.java | 2 - 98 files changed, 6497 insertions(+), 21675 deletions(-) delete mode 100644 client/src/main/generated/LogEntry.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/graph/Session.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddHostIntoZoneReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddZoneIntoGroupReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/AgentHBReq.java rename client/src/main/generated/com/vesoft/nebula/meta/{ListGroupsResp.java => AgentHBResp.java} (72%) delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/BalanceReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/BalanceResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/DropGroupReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/DropHostFromZoneReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/DropZoneFromGroupReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetGroupReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/Group.java rename client/src/main/generated/com/vesoft/nebula/meta/{BackupInfo.java => HostBackupInfo.java} (64%) create mode 100644 client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/LeaderBalanceReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/ListGroupsReq.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java rename client/src/main/generated/com/vesoft/nebula/{NodeInfo.java => meta/ServiceInfo.java} (50%) delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java delete mode 100644 client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java diff --git a/client/src/main/generated/LogEntry.java b/client/src/main/generated/LogEntry.java deleted file mode 100644 index 0262d916b..000000000 --- a/client/src/main/generated/LogEntry.java +++ /dev/null @@ -1,355 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class LogEntry implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("LogEntry"); - private static final TField CLUSTER_FIELD_DESC = new TField("cluster", TType.I64, (short)1); - private static final TField LOG_STR_FIELD_DESC = new TField("log_str", TType.STRING, (short)2); - - public long cluster; - public byte[] log_str; - public static final int CLUSTER = 1; - public static final int LOG_STR = 2; - - // isset id assignments - private static final int __CLUSTER_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CLUSTER, new FieldMetaData("cluster", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(LOG_STR, new FieldMetaData("log_str", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(LogEntry.class, metaDataMap); - } - - public LogEntry() { - } - - public LogEntry( - long cluster, - byte[] log_str) { - this(); - this.cluster = cluster; - setClusterIsSet(true); - this.log_str = log_str; - } - - public static class Builder { - private long cluster; - private byte[] log_str; - - BitSet __optional_isset = new BitSet(1); - - public Builder() { - } - - public Builder setCluster(final long cluster) { - this.cluster = cluster; - __optional_isset.set(__CLUSTER_ISSET_ID, true); - return this; - } - - public Builder setLog_str(final byte[] log_str) { - this.log_str = log_str; - return this; - } - - public LogEntry build() { - LogEntry result = new LogEntry(); - if (__optional_isset.get(__CLUSTER_ISSET_ID)) { - result.setCluster(this.cluster); - } - result.setLog_str(this.log_str); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public LogEntry(LogEntry other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.cluster = TBaseHelper.deepCopy(other.cluster); - if (other.isSetLog_str()) { - this.log_str = TBaseHelper.deepCopy(other.log_str); - } - } - - public LogEntry deepCopy() { - return new LogEntry(this); - } - - public long getCluster() { - return this.cluster; - } - - public LogEntry setCluster(long cluster) { - this.cluster = cluster; - setClusterIsSet(true); - return this; - } - - public void unsetCluster() { - __isset_bit_vector.clear(__CLUSTER_ISSET_ID); - } - - // Returns true if field cluster is set (has been assigned a value) and false otherwise - public boolean isSetCluster() { - return __isset_bit_vector.get(__CLUSTER_ISSET_ID); - } - - public void setClusterIsSet(boolean __value) { - __isset_bit_vector.set(__CLUSTER_ISSET_ID, __value); - } - - public byte[] getLog_str() { - return this.log_str; - } - - public LogEntry setLog_str(byte[] log_str) { - this.log_str = log_str; - return this; - } - - public void unsetLog_str() { - this.log_str = null; - } - - // Returns true if field log_str is set (has been assigned a value) and false otherwise - public boolean isSetLog_str() { - return this.log_str != null; - } - - public void setLog_strIsSet(boolean __value) { - if (!__value) { - this.log_str = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CLUSTER: - if (__value == null) { - unsetCluster(); - } else { - setCluster((Long)__value); - } - break; - - case LOG_STR: - if (__value == null) { - unsetLog_str(); - } else { - setLog_str((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CLUSTER: - return new Long(getCluster()); - - case LOG_STR: - return getLog_str(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof LogEntry)) - return false; - LogEntry that = (LogEntry)_that; - - if (!TBaseHelper.equalsNobinary(this.cluster, that.cluster)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetLog_str(), that.isSetLog_str(), this.log_str, that.log_str)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {cluster, log_str}); - } - - @Override - public int compareTo(LogEntry other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetCluster()).compareTo(other.isSetCluster()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(cluster, other.cluster); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetLog_str()).compareTo(other.isSetLog_str()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(log_str, other.log_str); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CLUSTER: - if (__field.type == TType.I64) { - this.cluster = iprot.readI64(); - setClusterIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LOG_STR: - if (__field.type == TType.STRING) { - this.log_str = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(CLUSTER_FIELD_DESC); - oprot.writeI64(this.cluster); - oprot.writeFieldEnd(); - if (this.log_str != null) { - oprot.writeFieldBegin(LOG_STR_FIELD_DESC); - oprot.writeBinary(this.log_str); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("LogEntry"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("cluster"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getCluster(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("log_str"); - sb.append(space); - sb.append(":").append(space); - if (this.getLog_str() == null) { - sb.append("null"); - } else { - int __log_str_size = Math.min(this.getLog_str().length, 128); - for (int i = 0; i < __log_str_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getLog_str()[i]).length() > 1 ? Integer.toHexString(this.getLog_str()[i]).substring(Integer.toHexString(this.getLog_str()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getLog_str()[i]).toUpperCase()); - } - if (this.getLog_str().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/CheckpointInfo.java b/client/src/main/generated/com/vesoft/nebula/CheckpointInfo.java index 18bc5ee03..ace305e36 100644 --- a/client/src/main/generated/com/vesoft/nebula/CheckpointInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/CheckpointInfo.java @@ -26,22 +26,31 @@ @SuppressWarnings({ "unused", "serial" }) public class CheckpointInfo implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("CheckpointInfo"); - private static final TField PARTITION_INFO_FIELD_DESC = new TField("partition_info", TType.STRUCT, (short)1); - private static final TField PATH_FIELD_DESC = new TField("path", TType.STRING, (short)2); + private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField PARTS_FIELD_DESC = new TField("parts", TType.MAP, (short)2); + private static final TField PATH_FIELD_DESC = new TField("path", TType.STRING, (short)3); - public PartitionBackupInfo partition_info; + public int space_id; + public Map parts; public byte[] path; - public static final int PARTITION_INFO = 1; - public static final int PATH = 2; + public static final int SPACE_ID = 1; + public static final int PARTS = 2; + public static final int PATH = 3; // isset id assignments + private static final int __SPACE_ID_ISSET_ID = 0; + private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(PARTITION_INFO, new FieldMetaData("partition_info", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, PartitionBackupInfo.class))); + tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(PARTS, new FieldMetaData("parts", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.I32), + new StructMetaData(TType.STRUCT, LogInfo.class)))); tmpMetaDataMap.put(PATH, new FieldMetaData("path", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -55,22 +64,34 @@ public CheckpointInfo() { } public CheckpointInfo( - PartitionBackupInfo partition_info, + int space_id, + Map parts, byte[] path) { this(); - this.partition_info = partition_info; + this.space_id = space_id; + setSpace_idIsSet(true); + this.parts = parts; this.path = path; } public static class Builder { - private PartitionBackupInfo partition_info; + private int space_id; + private Map parts; private byte[] path; + BitSet __optional_isset = new BitSet(1); + public Builder() { } - public Builder setPartition_info(final PartitionBackupInfo partition_info) { - this.partition_info = partition_info; + public Builder setSpace_id(final int space_id) { + this.space_id = space_id; + __optional_isset.set(__SPACE_ID_ISSET_ID, true); + return this; + } + + public Builder setParts(final Map parts) { + this.parts = parts; return this; } @@ -81,7 +102,10 @@ public Builder setPath(final byte[] path) { public CheckpointInfo build() { CheckpointInfo result = new CheckpointInfo(); - result.setPartition_info(this.partition_info); + if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { + result.setSpace_id(this.space_id); + } + result.setParts(this.parts); result.setPath(this.path); return result; } @@ -95,8 +119,11 @@ public static Builder builder() { * Performs a deep copy on other. */ public CheckpointInfo(CheckpointInfo other) { - if (other.isSetPartition_info()) { - this.partition_info = TBaseHelper.deepCopy(other.partition_info); + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetParts()) { + this.parts = TBaseHelper.deepCopy(other.parts); } if (other.isSetPath()) { this.path = TBaseHelper.deepCopy(other.path); @@ -107,27 +134,50 @@ public CheckpointInfo deepCopy() { return new CheckpointInfo(this); } - public PartitionBackupInfo getPartition_info() { - return this.partition_info; + public int getSpace_id() { + return this.space_id; } - public CheckpointInfo setPartition_info(PartitionBackupInfo partition_info) { - this.partition_info = partition_info; + public CheckpointInfo setSpace_id(int space_id) { + this.space_id = space_id; + setSpace_idIsSet(true); return this; } - public void unsetPartition_info() { - this.partition_info = null; + public void unsetSpace_id() { + __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); } - // Returns true if field partition_info is set (has been assigned a value) and false otherwise - public boolean isSetPartition_info() { - return this.partition_info != null; + // Returns true if field space_id is set (has been assigned a value) and false otherwise + public boolean isSetSpace_id() { + return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); } - public void setPartition_infoIsSet(boolean __value) { + public void setSpace_idIsSet(boolean __value) { + __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + } + + public Map getParts() { + return this.parts; + } + + public CheckpointInfo setParts(Map parts) { + this.parts = parts; + return this; + } + + public void unsetParts() { + this.parts = null; + } + + // Returns true if field parts is set (has been assigned a value) and false otherwise + public boolean isSetParts() { + return this.parts != null; + } + + public void setPartsIsSet(boolean __value) { if (!__value) { - this.partition_info = null; + this.parts = null; } } @@ -155,13 +205,22 @@ public void setPathIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case PARTITION_INFO: + case SPACE_ID: + if (__value == null) { + unsetSpace_id(); + } else { + setSpace_id((Integer)__value); + } + break; + + case PARTS: if (__value == null) { - unsetPartition_info(); + unsetParts(); } else { - setPartition_info((PartitionBackupInfo)__value); + setParts((Map)__value); } break; @@ -180,8 +239,11 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case PARTITION_INFO: - return getPartition_info(); + case SPACE_ID: + return new Integer(getSpace_id()); + + case PARTS: + return getParts(); case PATH: return getPath(); @@ -201,7 +263,9 @@ public boolean equals(Object _that) { return false; CheckpointInfo that = (CheckpointInfo)_that; - if (!TBaseHelper.equalsNobinary(this.isSetPartition_info(), that.isSetPartition_info(), this.partition_info, that.partition_info)) { return false; } + if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetParts(), that.isSetParts(), this.parts, that.parts)) { return false; } if (!TBaseHelper.equalsSlow(this.isSetPath(), that.isSetPath(), this.path, that.path)) { return false; } @@ -210,7 +274,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {partition_info, path}); + return Arrays.deepHashCode(new Object[] {space_id, parts, path}); } @Override @@ -225,11 +289,19 @@ public int compareTo(CheckpointInfo other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetPartition_info()).compareTo(other.isSetPartition_info()); + lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetParts()).compareTo(other.isSetParts()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(partition_info, other.partition_info); + lastComparison = TBaseHelper.compareTo(parts, other.parts); if (lastComparison != 0) { return lastComparison; } @@ -255,10 +327,32 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case PARTITION_INFO: - if (__field.type == TType.STRUCT) { - this.partition_info = new PartitionBackupInfo(); - this.partition_info.read(iprot); + case SPACE_ID: + if (__field.type == TType.I32) { + this.space_id = iprot.readI32(); + setSpace_idIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case PARTS: + if (__field.type == TType.MAP) { + { + TMap _map64 = iprot.readMapBegin(); + this.parts = new HashMap(Math.max(0, 2*_map64.size)); + for (int _i65 = 0; + (_map64.size < 0) ? iprot.peekMap() : (_i65 < _map64.size); + ++_i65) + { + int _key66; + LogInfo _val67; + _key66 = iprot.readI32(); + _val67 = new LogInfo(); + _val67.read(iprot); + this.parts.put(_key66, _val67); + } + iprot.readMapEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -287,9 +381,19 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - if (this.partition_info != null) { - oprot.writeFieldBegin(PARTITION_INFO_FIELD_DESC); - this.partition_info.write(oprot); + oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); + oprot.writeI32(this.space_id); + oprot.writeFieldEnd(); + if (this.parts != null) { + oprot.writeFieldBegin(PARTS_FIELD_DESC); + { + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.parts.size())); + for (Map.Entry _iter68 : this.parts.entrySet()) { + oprot.writeI32(_iter68.getKey()); + _iter68.getValue().write(oprot); + } + oprot.writeMapEnd(); + } oprot.writeFieldEnd(); } if (this.path != null) { @@ -318,13 +422,20 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("partition_info"); + sb.append("space_id"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("parts"); sb.append(space); sb.append(":").append(space); - if (this.getPartition_info() == null) { + if (this.getParts() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getPartition_info(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getParts(), indent + 1, prettyPrint)); } first = false; if (!first) sb.append("," + newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java index aeb236d81..8a5d54653 100644 --- a/client/src/main/generated/com/vesoft/nebula/ErrorCode.java +++ b/client/src/main/generated/com/vesoft/nebula/ErrorCode.java @@ -94,6 +94,7 @@ public enum ErrorCode implements com.facebook.thrift.TEnum { E_LIST_CLUSTER_GET_ABS_PATH_FAILURE(-2071), E_GET_META_DIR_FAILURE(-2072), E_QUERY_NOT_FOUND(-2073), + E_AGENT_HB_FAILUE(-2074), E_CONSENSUS_ERROR(-3001), E_KEY_HAS_EXISTS(-3002), E_DATA_TYPE_MISMATCH(-3003), diff --git a/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java b/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java deleted file mode 100644 index 917e3d168..000000000 --- a/client/src/main/generated/com/vesoft/nebula/PartitionBackupInfo.java +++ /dev/null @@ -1,290 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class PartitionBackupInfo implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("PartitionBackupInfo"); - private static final TField INFO_FIELD_DESC = new TField("info", TType.MAP, (short)1); - - public Map info; - public static final int INFO = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(INFO, new FieldMetaData("info", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I32), - new StructMetaData(TType.STRUCT, LogInfo.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(PartitionBackupInfo.class, metaDataMap); - } - - public PartitionBackupInfo() { - } - - public PartitionBackupInfo( - Map info) { - this(); - this.info = info; - } - - public static class Builder { - private Map info; - - public Builder() { - } - - public Builder setInfo(final Map info) { - this.info = info; - return this; - } - - public PartitionBackupInfo build() { - PartitionBackupInfo result = new PartitionBackupInfo(); - result.setInfo(this.info); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public PartitionBackupInfo(PartitionBackupInfo other) { - if (other.isSetInfo()) { - this.info = TBaseHelper.deepCopy(other.info); - } - } - - public PartitionBackupInfo deepCopy() { - return new PartitionBackupInfo(this); - } - - public Map getInfo() { - return this.info; - } - - public PartitionBackupInfo setInfo(Map info) { - this.info = info; - return this; - } - - public void unsetInfo() { - this.info = null; - } - - // Returns true if field info is set (has been assigned a value) and false otherwise - public boolean isSetInfo() { - return this.info != null; - } - - public void setInfoIsSet(boolean __value) { - if (!__value) { - this.info = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case INFO: - if (__value == null) { - unsetInfo(); - } else { - setInfo((Map)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case INFO: - return getInfo(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof PartitionBackupInfo)) - return false; - PartitionBackupInfo that = (PartitionBackupInfo)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetInfo(), that.isSetInfo(), this.info, that.info)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {info}); - } - - @Override - public int compareTo(PartitionBackupInfo other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetInfo()).compareTo(other.isSetInfo()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(info, other.info); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case INFO: - if (__field.type == TType.MAP) { - { - TMap _map64 = iprot.readMapBegin(); - this.info = new HashMap(Math.max(0, 2*_map64.size)); - for (int _i65 = 0; - (_map64.size < 0) ? iprot.peekMap() : (_i65 < _map64.size); - ++_i65) - { - int _key66; - LogInfo _val67; - _key66 = iprot.readI32(); - _val67 = new LogInfo(); - _val67.read(iprot); - this.info.put(_key66, _val67); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.info != null) { - oprot.writeFieldBegin(INFO_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.info.size())); - for (Map.Entry _iter68 : this.info.entrySet()) { - oprot.writeI32(_iter68.getKey()); - _iter68.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("PartitionBackupInfo"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("info"); - sb.append(space); - sb.append(":").append(space); - if (this.getInfo() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getInfo(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/Value.java b/client/src/main/generated/com/vesoft/nebula/Value.java index 628946385..6d442e31f 100644 --- a/client/src/main/generated/com/vesoft/nebula/Value.java +++ b/client/src/main/generated/com/vesoft/nebula/Value.java @@ -42,6 +42,7 @@ public class Value extends TUnion { private static final TField U_VAL_FIELD_DESC = new TField("uVal", TType.STRUCT, (short)14); private static final TField G_VAL_FIELD_DESC = new TField("gVal", TType.STRUCT, (short)15); private static final TField GG_VAL_FIELD_DESC = new TField("ggVal", TType.STRUCT, (short)16); + private static final TField DU_VAL_FIELD_DESC = new TField("duVal", TType.STRUCT, (short)17); public static final int NVAL = 1; public static final int BVAL = 2; @@ -59,6 +60,7 @@ public class Value extends TUnion { public static final int UVAL = 14; public static final int GVAL = 15; public static final int GGVAL = 16; + public static final int DUVAL = 17; public static final Map metaDataMap; @@ -96,6 +98,8 @@ public class Value extends TUnion { new StructMetaData(TType.STRUCT, DataSet.class))); tmpMetaDataMap.put(GGVAL, new FieldMetaData("ggVal", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, Geography.class))); + tmpMetaDataMap.put(DUVAL, new FieldMetaData("duVal", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, Duration.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -211,6 +215,12 @@ public static Value ggVal(Geography __value) { return x; } + public static Value duVal(Duration __value) { + Value x = new Value(); + x.setDuVal(__value); + return x; + } + @Override protected void checkType(short setField, Object __value) throws ClassCastException { @@ -295,6 +305,11 @@ protected void checkType(short setField, Object __value) throws ClassCastExcepti break; } throw new ClassCastException("Was expecting value of type Geography for field 'ggVal', but got " + __value.getClass().getSimpleName()); + case DUVAL: + if (__value instanceof Duration) { + break; + } + throw new ClassCastException("Was expecting value of type Duration for field 'duVal', but got " + __value.getClass().getSimpleName()); default: throw new IllegalArgumentException("Unknown field id " + setField); } @@ -392,6 +407,11 @@ public void read(TProtocol iprot) throws TException { setField_ = __field.id; } break; + case DUVAL: + if (__field.type == DU_VAL_FIELD_DESC.type) { + setField_ = __field.id; + } + break; } } iprot.readFieldEnd(); @@ -529,6 +549,14 @@ protected Object readValue(TProtocol iprot, TField __field) throws TException { return ggVal; } break; + case DUVAL: + if (__field.type == DU_VAL_FIELD_DESC.type) { + Duration duVal; + duVal = new Duration(); + duVal.read(iprot); + return duVal; + } + break; } TProtocolUtil.skip(iprot, __field.type); return null; @@ -601,6 +629,10 @@ protected void writeValue(TProtocol oprot, short setField, Object __value) throw Geography ggVal = (Geography)getFieldValue(); ggVal.write(oprot); return; + case DUVAL: + Duration duVal = (Duration)getFieldValue(); + duVal.write(oprot); + return; default: throw new IllegalStateException("Cannot write union with unknown field " + setField); } @@ -641,6 +673,8 @@ protected TField getFieldDesc(int setField) { return G_VAL_FIELD_DESC; case GGVAL: return GG_VAL_FIELD_DESC; + case DUVAL: + return DU_VAL_FIELD_DESC; default: throw new IllegalArgumentException("Unknown field id " + setField); } @@ -807,6 +841,14 @@ public void setGgVal(Geography __value) { __setValue(GGVAL, __value); } + public Duration getDuVal() { + return (Duration) __getValue(DUVAL); + } + + public void setDuVal(Duration __value) { + __setValue(DUVAL, __value); + } + public boolean equals(Object other) { if (other instanceof Value) { return equals((Value)other); diff --git a/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java b/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java deleted file mode 100644 index b39ac4039..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/GraphAdminService.java +++ /dev/null @@ -1,644 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GraphAdminService { - - public interface Iface { - - public ListAllSessionsResp listAllSessions(ListAllSessionsReq req) throws TException; - - } - - public interface AsyncIface { - - public void listAllSessions(ListAllSessionsReq req, AsyncMethodCallback resultHandler) throws TException; - - } - - public static class Client extends EventHandlerBase implements Iface, TClientIf { - public Client(TProtocol prot) - { - this(prot, prot); - } - - public Client(TProtocol iprot, TProtocol oprot) - { - iprot_ = iprot; - oprot_ = oprot; - } - - protected TProtocol iprot_; - protected TProtocol oprot_; - - protected int seqid_; - - @Override - public TProtocol getInputProtocol() - { - return this.iprot_; - } - - @Override - public TProtocol getOutputProtocol() - { - return this.oprot_; - } - - public ListAllSessionsResp listAllSessions(ListAllSessionsReq req) throws TException - { - ContextStack ctx = getContextStack("GraphAdminService.listAllSessions", null); - this.setContextStack(ctx); - send_listAllSessions(req); - return recv_listAllSessions(); - } - - public void send_listAllSessions(ListAllSessionsReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "GraphAdminService.listAllSessions", null); - oprot_.writeMessageBegin(new TMessage("listAllSessions", TMessageType.CALL, seqid_)); - listAllSessions_args args = new listAllSessions_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "GraphAdminService.listAllSessions", args); - return; - } - - public ListAllSessionsResp recv_listAllSessions() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "GraphAdminService.listAllSessions"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - listAllSessions_result result = new listAllSessions_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "GraphAdminService.listAllSessions", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "listAllSessions failed: unknown result"); - } - - } - public static class AsyncClient extends TAsyncClient implements AsyncIface { - public static class Factory implements TAsyncClientFactory { - private TAsyncClientManager clientManager; - private TProtocolFactory protocolFactory; - public Factory(TAsyncClientManager clientManager, TProtocolFactory protocolFactory) { - this.clientManager = clientManager; - this.protocolFactory = protocolFactory; - } - public AsyncClient getAsyncClient(TNonblockingTransport transport) { - return new AsyncClient(protocolFactory, clientManager, transport); - } - } - - public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientManager, TNonblockingTransport transport) { - super(protocolFactory, clientManager, transport); - } - - public void listAllSessions(ListAllSessionsReq req, AsyncMethodCallback resultHandler74) throws TException { - checkReady(); - listAllSessions_call method_call = new listAllSessions_call(req, resultHandler74, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class listAllSessions_call extends TAsyncMethodCall { - private ListAllSessionsReq req; - public listAllSessions_call(ListAllSessionsReq req, AsyncMethodCallback resultHandler75, TAsyncClient client71, TProtocolFactory protocolFactory72, TNonblockingTransport transport73) throws TException { - super(client71, protocolFactory72, transport73, resultHandler75, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("listAllSessions", TMessageType.CALL, 0)); - listAllSessions_args args = new listAllSessions_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ListAllSessionsResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_listAllSessions(); - } - } - - } - - public static class Processor implements TProcessor { - private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName()); - public Processor(Iface iface) - { - iface_ = iface; - event_handler_ = new TProcessorEventHandler(); // Empty handler - processMap_.put("listAllSessions", new listAllSessions()); - } - - protected static interface ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException; - } - - public void setEventHandler(TProcessorEventHandler handler) { - this.event_handler_ = handler; - } - - private Iface iface_; - protected TProcessorEventHandler event_handler_; - protected final HashMap processMap_ = new HashMap(); - - public boolean process(TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - TMessage msg = iprot.readMessageBegin(); - ProcessFunction fn = processMap_.get(msg.name); - if (fn == null) { - TProtocolUtil.skip(iprot, TType.STRUCT); - iprot.readMessageEnd(); - TApplicationException x = new TApplicationException(TApplicationException.UNKNOWN_METHOD, "Invalid method name: '"+msg.name+"'"); - oprot.writeMessageBegin(new TMessage(msg.name, TMessageType.EXCEPTION, msg.seqid)); - x.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - return true; - } - fn.process(msg.seqid, iprot, oprot, server_ctx); - return true; - } - - private class listAllSessions implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("GraphAdminService.listAllSessions", server_ctx); - listAllSessions_args args = new listAllSessions_args(); - event_handler_.preRead(handler_ctx, "GraphAdminService.listAllSessions"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "GraphAdminService.listAllSessions", args); - listAllSessions_result result = new listAllSessions_result(); - result.success = iface_.listAllSessions(args.req); - event_handler_.preWrite(handler_ctx, "GraphAdminService.listAllSessions", result); - oprot.writeMessageBegin(new TMessage("listAllSessions", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "GraphAdminService.listAllSessions", result); - } - - } - - } - - public static class listAllSessions_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listAllSessions_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public ListAllSessionsReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListAllSessionsReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listAllSessions_args.class, metaDataMap); - } - - public listAllSessions_args() { - } - - public listAllSessions_args( - ListAllSessionsReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public listAllSessions_args(listAllSessions_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public listAllSessions_args deepCopy() { - return new listAllSessions_args(this); - } - - public ListAllSessionsReq getReq() { - return this.req; - } - - public listAllSessions_args setReq(ListAllSessionsReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((ListAllSessionsReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listAllSessions_args)) - return false; - listAllSessions_args that = (listAllSessions_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(listAllSessions_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new ListAllSessionsReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listAllSessions_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listAllSessions_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("listAllSessions_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ListAllSessionsResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListAllSessionsResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listAllSessions_result.class, metaDataMap); - } - - public listAllSessions_result() { - } - - public listAllSessions_result( - ListAllSessionsResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public listAllSessions_result(listAllSessions_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public listAllSessions_result deepCopy() { - return new listAllSessions_result(this); - } - - public ListAllSessionsResp getSuccess() { - return this.success; - } - - public listAllSessions_result setSuccess(ListAllSessionsResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ListAllSessionsResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listAllSessions_result)) - return false; - listAllSessions_result that = (listAllSessions_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ListAllSessionsResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listAllSessions_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - -} diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java deleted file mode 100644 index d442be0d0..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsReq.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListAllSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsReq"); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListAllSessionsReq.class, metaDataMap); - } - - public ListAllSessionsReq() { - } - - public static class Builder { - - public Builder() { - } - - public ListAllSessionsReq build() { - ListAllSessionsReq result = new ListAllSessionsReq(); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListAllSessionsReq(ListAllSessionsReq other) { - } - - public ListAllSessionsReq deepCopy() { - return new ListAllSessionsReq(this); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListAllSessionsReq)) - return false; - ListAllSessionsReq that = (ListAllSessionsReq)_that; - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {}); - } - - @Override - public int compareTo(ListAllSessionsReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListAllSessionsReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java deleted file mode 100644 index 70e5d311d..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/ListAllSessionsResp.java +++ /dev/null @@ -1,360 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListAllSessionsResp implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)2); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public List sessions; - public static final int CODE = 1; - public static final int SESSIONS = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Session.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListAllSessionsResp.class, metaDataMap); - } - - public ListAllSessionsResp() { - } - - public ListAllSessionsResp( - com.vesoft.nebula.ErrorCode code, - List sessions) { - this(); - this.code = code; - this.sessions = sessions; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private List sessions; - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setSessions(final List sessions) { - this.sessions = sessions; - return this; - } - - public ListAllSessionsResp build() { - ListAllSessionsResp result = new ListAllSessionsResp(); - result.setCode(this.code); - result.setSessions(this.sessions); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListAllSessionsResp(ListAllSessionsResp other) { - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - if (other.isSetSessions()) { - this.sessions = TBaseHelper.deepCopy(other.sessions); - } - } - - public ListAllSessionsResp deepCopy() { - return new ListAllSessionsResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public ListAllSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public List getSessions() { - return this.sessions; - } - - public ListAllSessionsResp setSessions(List sessions) { - this.sessions = sessions; - return this; - } - - public void unsetSessions() { - this.sessions = null; - } - - // Returns true if field sessions is set (has been assigned a value) and false otherwise - public boolean isSetSessions() { - return this.sessions != null; - } - - public void setSessionsIsSet(boolean __value) { - if (!__value) { - this.sessions = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case SESSIONS: - if (__value == null) { - unsetSessions(); - } else { - setSessions((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case SESSIONS: - return getSessions(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListAllSessionsResp)) - return false; - ListAllSessionsResp that = (ListAllSessionsResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, sessions}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SESSIONS: - if (__field.type == TType.LIST) { - { - TList _list36 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list36.size)); - for (int _i37 = 0; - (_list36.size < 0) ? iprot.peekList() : (_i37 < _list36.size); - ++_i37) - { - Session _elem38; - _elem38 = new Session(); - _elem38.read(iprot); - this.sessions.add(_elem38); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - if (this.sessions != null) { - oprot.writeFieldBegin(SESSIONS_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter39 : this.sessions) { - _iter39.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListAllSessionsResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("sessions"); - sb.append(space); - sb.append(":").append(space); - if (this.getSessions() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java deleted file mode 100644 index 14c048679..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsReq.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("ListSessionsReq"); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListSessionsReq.class, metaDataMap); - } - - public ListSessionsReq() { - } - - public static class Builder { - - public Builder() { - } - - public ListSessionsReq build() { - ListSessionsReq result = new ListSessionsReq(); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListSessionsReq(ListSessionsReq other) { - } - - public ListSessionsReq deepCopy() { - return new ListSessionsReq(this); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListSessionsReq)) - return false; - ListSessionsReq that = (ListSessionsReq)_that; - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {}); - } - - @Override - public int compareTo(ListSessionsReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListSessionsReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java deleted file mode 100644 index f85103789..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/ListSessionsResp.java +++ /dev/null @@ -1,438 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListSessionsResp implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("ListSessionsResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)3); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public com.vesoft.nebula.HostAddr leader; - public List sessions; - public static final int CODE = 1; - public static final int LEADER = 2; - public static final int SESSIONS = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Session.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListSessionsResp.class, metaDataMap); - } - - public ListSessionsResp() { - } - - public ListSessionsResp( - com.vesoft.nebula.ErrorCode code, - com.vesoft.nebula.HostAddr leader, - List sessions) { - this(); - this.code = code; - this.leader = leader; - this.sessions = sessions; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private com.vesoft.nebula.HostAddr leader; - private List sessions; - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public Builder setSessions(final List sessions) { - this.sessions = sessions; - return this; - } - - public ListSessionsResp build() { - ListSessionsResp result = new ListSessionsResp(); - result.setCode(this.code); - result.setLeader(this.leader); - result.setSessions(this.sessions); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListSessionsResp(ListSessionsResp other) { - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - if (other.isSetLeader()) { - this.leader = TBaseHelper.deepCopy(other.leader); - } - if (other.isSetSessions()) { - this.sessions = TBaseHelper.deepCopy(other.sessions); - } - } - - public ListSessionsResp deepCopy() { - return new ListSessionsResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public ListSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public com.vesoft.nebula.HostAddr getLeader() { - return this.leader; - } - - public ListSessionsResp setLeader(com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public void unsetLeader() { - this.leader = null; - } - - // Returns true if field leader is set (has been assigned a value) and false otherwise - public boolean isSetLeader() { - return this.leader != null; - } - - public void setLeaderIsSet(boolean __value) { - if (!__value) { - this.leader = null; - } - } - - public List getSessions() { - return this.sessions; - } - - public ListSessionsResp setSessions(List sessions) { - this.sessions = sessions; - return this; - } - - public void unsetSessions() { - this.sessions = null; - } - - // Returns true if field sessions is set (has been assigned a value) and false otherwise - public boolean isSetSessions() { - return this.sessions != null; - } - - public void setSessionsIsSet(boolean __value) { - if (!__value) { - this.sessions = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case LEADER: - if (__value == null) { - unsetLeader(); - } else { - setLeader((com.vesoft.nebula.HostAddr)__value); - } - break; - - case SESSIONS: - if (__value == null) { - unsetSessions(); - } else { - setSessions((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case LEADER: - return getLeader(); - - case SESSIONS: - return getSessions(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListSessionsResp)) - return false; - ListSessionsResp that = (ListSessionsResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, sessions}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LEADER: - if (__field.type == TType.STRUCT) { - this.leader = new com.vesoft.nebula.HostAddr(); - this.leader.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SESSIONS: - if (__field.type == TType.LIST) { - { - TList _list36 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list36.size)); - for (int _i37 = 0; - (_list36.size < 0) ? iprot.peekList() : (_i37 < _list36.size); - ++_i37) - { - Session _elem38; - _elem38 = new Session(); - _elem38.read(iprot); - this.sessions.add(_elem38); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - if (this.leader != null) { - oprot.writeFieldBegin(LEADER_FIELD_DESC); - this.leader.write(oprot); - oprot.writeFieldEnd(); - } - if (this.sessions != null) { - oprot.writeFieldBegin(SESSIONS_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter39 : this.sessions) { - _iter39.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListSessionsResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("leader"); - sb.append(space); - sb.append(":").append(space); - if (this.getLeader() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("sessions"); - sb.append(space); - sb.append(":").append(space); - if (this.getSessions() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java b/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java deleted file mode 100644 index 25f9ea56a..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/QueryDesc.java +++ /dev/null @@ -1,630 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class QueryDesc implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("QueryDesc"); - private static final TField START_TIME_FIELD_DESC = new TField("start_time", TType.I64, (short)1); - private static final TField STATUS_FIELD_DESC = new TField("status", TType.I32, (short)2); - private static final TField DURATION_FIELD_DESC = new TField("duration", TType.I64, (short)3); - private static final TField QUERY_FIELD_DESC = new TField("query", TType.STRING, (short)4); - private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)5); - - public long start_time; - /** - * - * @see QueryStatus - */ - public QueryStatus status; - public long duration; - public byte[] query; - public com.vesoft.nebula.HostAddr graph_addr; - public static final int START_TIME = 1; - public static final int STATUS = 2; - public static final int DURATION = 3; - public static final int QUERY = 4; - public static final int GRAPH_ADDR = 5; - - // isset id assignments - private static final int __START_TIME_ISSET_ID = 0; - private static final int __DURATION_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(START_TIME, new FieldMetaData("start_time", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(STATUS, new FieldMetaData("status", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(DURATION, new FieldMetaData("duration", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(QUERY, new FieldMetaData("query", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(QueryDesc.class, metaDataMap); - } - - public QueryDesc() { - } - - public QueryDesc( - long start_time, - QueryStatus status, - long duration, - byte[] query, - com.vesoft.nebula.HostAddr graph_addr) { - this(); - this.start_time = start_time; - setStart_timeIsSet(true); - this.status = status; - this.duration = duration; - setDurationIsSet(true); - this.query = query; - this.graph_addr = graph_addr; - } - - public static class Builder { - private long start_time; - private QueryStatus status; - private long duration; - private byte[] query; - private com.vesoft.nebula.HostAddr graph_addr; - - BitSet __optional_isset = new BitSet(2); - - public Builder() { - } - - public Builder setStart_time(final long start_time) { - this.start_time = start_time; - __optional_isset.set(__START_TIME_ISSET_ID, true); - return this; - } - - public Builder setStatus(final QueryStatus status) { - this.status = status; - return this; - } - - public Builder setDuration(final long duration) { - this.duration = duration; - __optional_isset.set(__DURATION_ISSET_ID, true); - return this; - } - - public Builder setQuery(final byte[] query) { - this.query = query; - return this; - } - - public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public QueryDesc build() { - QueryDesc result = new QueryDesc(); - if (__optional_isset.get(__START_TIME_ISSET_ID)) { - result.setStart_time(this.start_time); - } - result.setStatus(this.status); - if (__optional_isset.get(__DURATION_ISSET_ID)) { - result.setDuration(this.duration); - } - result.setQuery(this.query); - result.setGraph_addr(this.graph_addr); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public QueryDesc(QueryDesc other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.start_time = TBaseHelper.deepCopy(other.start_time); - if (other.isSetStatus()) { - this.status = TBaseHelper.deepCopy(other.status); - } - this.duration = TBaseHelper.deepCopy(other.duration); - if (other.isSetQuery()) { - this.query = TBaseHelper.deepCopy(other.query); - } - if (other.isSetGraph_addr()) { - this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); - } - } - - public QueryDesc deepCopy() { - return new QueryDesc(this); - } - - public long getStart_time() { - return this.start_time; - } - - public QueryDesc setStart_time(long start_time) { - this.start_time = start_time; - setStart_timeIsSet(true); - return this; - } - - public void unsetStart_time() { - __isset_bit_vector.clear(__START_TIME_ISSET_ID); - } - - // Returns true if field start_time is set (has been assigned a value) and false otherwise - public boolean isSetStart_time() { - return __isset_bit_vector.get(__START_TIME_ISSET_ID); - } - - public void setStart_timeIsSet(boolean __value) { - __isset_bit_vector.set(__START_TIME_ISSET_ID, __value); - } - - /** - * - * @see QueryStatus - */ - public QueryStatus getStatus() { - return this.status; - } - - /** - * - * @see QueryStatus - */ - public QueryDesc setStatus(QueryStatus status) { - this.status = status; - return this; - } - - public void unsetStatus() { - this.status = null; - } - - // Returns true if field status is set (has been assigned a value) and false otherwise - public boolean isSetStatus() { - return this.status != null; - } - - public void setStatusIsSet(boolean __value) { - if (!__value) { - this.status = null; - } - } - - public long getDuration() { - return this.duration; - } - - public QueryDesc setDuration(long duration) { - this.duration = duration; - setDurationIsSet(true); - return this; - } - - public void unsetDuration() { - __isset_bit_vector.clear(__DURATION_ISSET_ID); - } - - // Returns true if field duration is set (has been assigned a value) and false otherwise - public boolean isSetDuration() { - return __isset_bit_vector.get(__DURATION_ISSET_ID); - } - - public void setDurationIsSet(boolean __value) { - __isset_bit_vector.set(__DURATION_ISSET_ID, __value); - } - - public byte[] getQuery() { - return this.query; - } - - public QueryDesc setQuery(byte[] query) { - this.query = query; - return this; - } - - public void unsetQuery() { - this.query = null; - } - - // Returns true if field query is set (has been assigned a value) and false otherwise - public boolean isSetQuery() { - return this.query != null; - } - - public void setQueryIsSet(boolean __value) { - if (!__value) { - this.query = null; - } - } - - public com.vesoft.nebula.HostAddr getGraph_addr() { - return this.graph_addr; - } - - public QueryDesc setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public void unsetGraph_addr() { - this.graph_addr = null; - } - - // Returns true if field graph_addr is set (has been assigned a value) and false otherwise - public boolean isSetGraph_addr() { - return this.graph_addr != null; - } - - public void setGraph_addrIsSet(boolean __value) { - if (!__value) { - this.graph_addr = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case START_TIME: - if (__value == null) { - unsetStart_time(); - } else { - setStart_time((Long)__value); - } - break; - - case STATUS: - if (__value == null) { - unsetStatus(); - } else { - setStatus((QueryStatus)__value); - } - break; - - case DURATION: - if (__value == null) { - unsetDuration(); - } else { - setDuration((Long)__value); - } - break; - - case QUERY: - if (__value == null) { - unsetQuery(); - } else { - setQuery((byte[])__value); - } - break; - - case GRAPH_ADDR: - if (__value == null) { - unsetGraph_addr(); - } else { - setGraph_addr((com.vesoft.nebula.HostAddr)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case START_TIME: - return new Long(getStart_time()); - - case STATUS: - return getStatus(); - - case DURATION: - return new Long(getDuration()); - - case QUERY: - return getQuery(); - - case GRAPH_ADDR: - return getGraph_addr(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof QueryDesc)) - return false; - QueryDesc that = (QueryDesc)_that; - - if (!TBaseHelper.equalsNobinary(this.start_time, that.start_time)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetStatus(), that.isSetStatus(), this.status, that.status)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.duration, that.duration)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetQuery(), that.isSetQuery(), this.query, that.query)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {start_time, status, duration, query, graph_addr}); - } - - @Override - public int compareTo(QueryDesc other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetStart_time()).compareTo(other.isSetStart_time()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(start_time, other.start_time); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(status, other.status); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetDuration()).compareTo(other.isSetDuration()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(duration, other.duration); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetQuery()).compareTo(other.isSetQuery()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(query, other.query); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetGraph_addr()).compareTo(other.isSetGraph_addr()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(graph_addr, other.graph_addr); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case START_TIME: - if (__field.type == TType.I64) { - this.start_time = iprot.readI64(); - setStart_timeIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case STATUS: - if (__field.type == TType.I32) { - this.status = QueryStatus.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case DURATION: - if (__field.type == TType.I64) { - this.duration = iprot.readI64(); - setDurationIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case QUERY: - if (__field.type == TType.STRING) { - this.query = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case GRAPH_ADDR: - if (__field.type == TType.STRUCT) { - this.graph_addr = new com.vesoft.nebula.HostAddr(); - this.graph_addr.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(START_TIME_FIELD_DESC); - oprot.writeI64(this.start_time); - oprot.writeFieldEnd(); - if (this.status != null) { - oprot.writeFieldBegin(STATUS_FIELD_DESC); - oprot.writeI32(this.status == null ? 0 : this.status.getValue()); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(DURATION_FIELD_DESC); - oprot.writeI64(this.duration); - oprot.writeFieldEnd(); - if (this.query != null) { - oprot.writeFieldBegin(QUERY_FIELD_DESC); - oprot.writeBinary(this.query); - oprot.writeFieldEnd(); - } - if (this.graph_addr != null) { - oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); - this.graph_addr.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("QueryDesc"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("start_time"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getStart_time(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("status"); - sb.append(space); - sb.append(":").append(space); - if (this.getStatus() == null) { - sb.append("null"); - } else { - String status_name = this.getStatus() == null ? "null" : this.getStatus().name(); - if (status_name != null) { - sb.append(status_name); - sb.append(" ("); - } - sb.append(this.getStatus()); - if (status_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("duration"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getDuration(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("query"); - sb.append(space); - sb.append(":").append(space); - if (this.getQuery() == null) { - sb.append("null"); - } else { - int __query_size = Math.min(this.getQuery().length, 128); - for (int i = 0; i < __query_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getQuery()[i]).length() > 1 ? Integer.toHexString(this.getQuery()[i]).substring(Integer.toHexString(this.getQuery()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getQuery()[i]).toUpperCase()); - } - if (this.getQuery().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("graph_addr"); - sb.append(space); - sb.append(":").append(space); - if (this.getGraph_addr() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java b/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java deleted file mode 100644 index 62ee710a7..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/QueryStatus.java +++ /dev/null @@ -1,46 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - - -import com.facebook.thrift.IntRangeSet; -import java.util.Map; -import java.util.HashMap; - -@SuppressWarnings({ "unused" }) -public enum QueryStatus implements com.facebook.thrift.TEnum { - RUNNING(1), - KILLING(2); - - private final int value; - - private QueryStatus(int value) { - this.value = value; - } - - /** - * Get the integer value of this enum value, as defined in the Thrift IDL. - */ - public int getValue() { - return value; - } - - /** - * Find a the enum type by its integer value, as defined in the Thrift IDL. - * @return null if the value is not found. - */ - public static QueryStatus findByValue(int value) { - switch (value) { - case 1: - return RUNNING; - case 2: - return KILLING; - default: - return null; - } - } -} diff --git a/client/src/main/generated/com/vesoft/nebula/graph/Session.java b/client/src/main/generated/com/vesoft/nebula/graph/Session.java deleted file mode 100644 index d8afef2ed..000000000 --- a/client/src/main/generated/com/vesoft/nebula/graph/Session.java +++ /dev/null @@ -1,993 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.graph; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class Session implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("Session"); - private static final TField SESSION_ID_FIELD_DESC = new TField("session_id", TType.I64, (short)1); - private static final TField CREATE_TIME_FIELD_DESC = new TField("create_time", TType.I64, (short)2); - private static final TField UPDATE_TIME_FIELD_DESC = new TField("update_time", TType.I64, (short)3); - private static final TField USER_NAME_FIELD_DESC = new TField("user_name", TType.STRING, (short)4); - private static final TField SPACE_NAME_FIELD_DESC = new TField("space_name", TType.STRING, (short)5); - private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)6); - private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)7); - private static final TField CLIENT_IP_FIELD_DESC = new TField("client_ip", TType.STRING, (short)8); - private static final TField CONFIGS_FIELD_DESC = new TField("configs", TType.MAP, (short)9); - private static final TField QUERIES_FIELD_DESC = new TField("queries", TType.MAP, (short)10); - - public long session_id; - public long create_time; - public long update_time; - public byte[] user_name; - public byte[] space_name; - public com.vesoft.nebula.HostAddr graph_addr; - public int timezone; - public byte[] client_ip; - public Map configs; - public Map queries; - public static final int SESSION_ID = 1; - public static final int CREATE_TIME = 2; - public static final int UPDATE_TIME = 3; - public static final int USER_NAME = 4; - public static final int SPACE_NAME = 5; - public static final int GRAPH_ADDR = 6; - public static final int TIMEZONE = 7; - public static final int CLIENT_IP = 8; - public static final int CONFIGS = 9; - public static final int QUERIES = 10; - - // isset id assignments - private static final int __SESSION_ID_ISSET_ID = 0; - private static final int __CREATE_TIME_ISSET_ID = 1; - private static final int __UPDATE_TIME_ISSET_ID = 2; - private static final int __TIMEZONE_ISSET_ID = 3; - private BitSet __isset_bit_vector = new BitSet(4); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SESSION_ID, new FieldMetaData("session_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(CREATE_TIME, new FieldMetaData("create_time", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(UPDATE_TIME, new FieldMetaData("update_time", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(USER_NAME, new FieldMetaData("user_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(SPACE_NAME, new FieldMetaData("space_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(CLIENT_IP, new FieldMetaData("client_ip", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(CONFIGS, new FieldMetaData("configs", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.STRING), - new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); - tmpMetaDataMap.put(QUERIES, new FieldMetaData("queries", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I64), - new StructMetaData(TType.STRUCT, QueryDesc.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(Session.class, metaDataMap); - } - - public Session() { - } - - public Session( - long session_id, - long create_time, - long update_time, - byte[] user_name, - byte[] space_name, - com.vesoft.nebula.HostAddr graph_addr, - int timezone, - byte[] client_ip, - Map configs, - Map queries) { - this(); - this.session_id = session_id; - setSession_idIsSet(true); - this.create_time = create_time; - setCreate_timeIsSet(true); - this.update_time = update_time; - setUpdate_timeIsSet(true); - this.user_name = user_name; - this.space_name = space_name; - this.graph_addr = graph_addr; - this.timezone = timezone; - setTimezoneIsSet(true); - this.client_ip = client_ip; - this.configs = configs; - this.queries = queries; - } - - public static class Builder { - private long session_id; - private long create_time; - private long update_time; - private byte[] user_name; - private byte[] space_name; - private com.vesoft.nebula.HostAddr graph_addr; - private int timezone; - private byte[] client_ip; - private Map configs; - private Map queries; - - BitSet __optional_isset = new BitSet(4); - - public Builder() { - } - - public Builder setSession_id(final long session_id) { - this.session_id = session_id; - __optional_isset.set(__SESSION_ID_ISSET_ID, true); - return this; - } - - public Builder setCreate_time(final long create_time) { - this.create_time = create_time; - __optional_isset.set(__CREATE_TIME_ISSET_ID, true); - return this; - } - - public Builder setUpdate_time(final long update_time) { - this.update_time = update_time; - __optional_isset.set(__UPDATE_TIME_ISSET_ID, true); - return this; - } - - public Builder setUser_name(final byte[] user_name) { - this.user_name = user_name; - return this; - } - - public Builder setSpace_name(final byte[] space_name) { - this.space_name = space_name; - return this; - } - - public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public Builder setTimezone(final int timezone) { - this.timezone = timezone; - __optional_isset.set(__TIMEZONE_ISSET_ID, true); - return this; - } - - public Builder setClient_ip(final byte[] client_ip) { - this.client_ip = client_ip; - return this; - } - - public Builder setConfigs(final Map configs) { - this.configs = configs; - return this; - } - - public Builder setQueries(final Map queries) { - this.queries = queries; - return this; - } - - public Session build() { - Session result = new Session(); - if (__optional_isset.get(__SESSION_ID_ISSET_ID)) { - result.setSession_id(this.session_id); - } - if (__optional_isset.get(__CREATE_TIME_ISSET_ID)) { - result.setCreate_time(this.create_time); - } - if (__optional_isset.get(__UPDATE_TIME_ISSET_ID)) { - result.setUpdate_time(this.update_time); - } - result.setUser_name(this.user_name); - result.setSpace_name(this.space_name); - result.setGraph_addr(this.graph_addr); - if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { - result.setTimezone(this.timezone); - } - result.setClient_ip(this.client_ip); - result.setConfigs(this.configs); - result.setQueries(this.queries); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public Session(Session other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.session_id = TBaseHelper.deepCopy(other.session_id); - this.create_time = TBaseHelper.deepCopy(other.create_time); - this.update_time = TBaseHelper.deepCopy(other.update_time); - if (other.isSetUser_name()) { - this.user_name = TBaseHelper.deepCopy(other.user_name); - } - if (other.isSetSpace_name()) { - this.space_name = TBaseHelper.deepCopy(other.space_name); - } - if (other.isSetGraph_addr()) { - this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); - } - this.timezone = TBaseHelper.deepCopy(other.timezone); - if (other.isSetClient_ip()) { - this.client_ip = TBaseHelper.deepCopy(other.client_ip); - } - if (other.isSetConfigs()) { - this.configs = TBaseHelper.deepCopy(other.configs); - } - if (other.isSetQueries()) { - this.queries = TBaseHelper.deepCopy(other.queries); - } - } - - public Session deepCopy() { - return new Session(this); - } - - public long getSession_id() { - return this.session_id; - } - - public Session setSession_id(long session_id) { - this.session_id = session_id; - setSession_idIsSet(true); - return this; - } - - public void unsetSession_id() { - __isset_bit_vector.clear(__SESSION_ID_ISSET_ID); - } - - // Returns true if field session_id is set (has been assigned a value) and false otherwise - public boolean isSetSession_id() { - return __isset_bit_vector.get(__SESSION_ID_ISSET_ID); - } - - public void setSession_idIsSet(boolean __value) { - __isset_bit_vector.set(__SESSION_ID_ISSET_ID, __value); - } - - public long getCreate_time() { - return this.create_time; - } - - public Session setCreate_time(long create_time) { - this.create_time = create_time; - setCreate_timeIsSet(true); - return this; - } - - public void unsetCreate_time() { - __isset_bit_vector.clear(__CREATE_TIME_ISSET_ID); - } - - // Returns true if field create_time is set (has been assigned a value) and false otherwise - public boolean isSetCreate_time() { - return __isset_bit_vector.get(__CREATE_TIME_ISSET_ID); - } - - public void setCreate_timeIsSet(boolean __value) { - __isset_bit_vector.set(__CREATE_TIME_ISSET_ID, __value); - } - - public long getUpdate_time() { - return this.update_time; - } - - public Session setUpdate_time(long update_time) { - this.update_time = update_time; - setUpdate_timeIsSet(true); - return this; - } - - public void unsetUpdate_time() { - __isset_bit_vector.clear(__UPDATE_TIME_ISSET_ID); - } - - // Returns true if field update_time is set (has been assigned a value) and false otherwise - public boolean isSetUpdate_time() { - return __isset_bit_vector.get(__UPDATE_TIME_ISSET_ID); - } - - public void setUpdate_timeIsSet(boolean __value) { - __isset_bit_vector.set(__UPDATE_TIME_ISSET_ID, __value); - } - - public byte[] getUser_name() { - return this.user_name; - } - - public Session setUser_name(byte[] user_name) { - this.user_name = user_name; - return this; - } - - public void unsetUser_name() { - this.user_name = null; - } - - // Returns true if field user_name is set (has been assigned a value) and false otherwise - public boolean isSetUser_name() { - return this.user_name != null; - } - - public void setUser_nameIsSet(boolean __value) { - if (!__value) { - this.user_name = null; - } - } - - public byte[] getSpace_name() { - return this.space_name; - } - - public Session setSpace_name(byte[] space_name) { - this.space_name = space_name; - return this; - } - - public void unsetSpace_name() { - this.space_name = null; - } - - // Returns true if field space_name is set (has been assigned a value) and false otherwise - public boolean isSetSpace_name() { - return this.space_name != null; - } - - public void setSpace_nameIsSet(boolean __value) { - if (!__value) { - this.space_name = null; - } - } - - public com.vesoft.nebula.HostAddr getGraph_addr() { - return this.graph_addr; - } - - public Session setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public void unsetGraph_addr() { - this.graph_addr = null; - } - - // Returns true if field graph_addr is set (has been assigned a value) and false otherwise - public boolean isSetGraph_addr() { - return this.graph_addr != null; - } - - public void setGraph_addrIsSet(boolean __value) { - if (!__value) { - this.graph_addr = null; - } - } - - public int getTimezone() { - return this.timezone; - } - - public Session setTimezone(int timezone) { - this.timezone = timezone; - setTimezoneIsSet(true); - return this; - } - - public void unsetTimezone() { - __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); - } - - // Returns true if field timezone is set (has been assigned a value) and false otherwise - public boolean isSetTimezone() { - return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); - } - - public void setTimezoneIsSet(boolean __value) { - __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); - } - - public byte[] getClient_ip() { - return this.client_ip; - } - - public Session setClient_ip(byte[] client_ip) { - this.client_ip = client_ip; - return this; - } - - public void unsetClient_ip() { - this.client_ip = null; - } - - // Returns true if field client_ip is set (has been assigned a value) and false otherwise - public boolean isSetClient_ip() { - return this.client_ip != null; - } - - public void setClient_ipIsSet(boolean __value) { - if (!__value) { - this.client_ip = null; - } - } - - public Map getConfigs() { - return this.configs; - } - - public Session setConfigs(Map configs) { - this.configs = configs; - return this; - } - - public void unsetConfigs() { - this.configs = null; - } - - // Returns true if field configs is set (has been assigned a value) and false otherwise - public boolean isSetConfigs() { - return this.configs != null; - } - - public void setConfigsIsSet(boolean __value) { - if (!__value) { - this.configs = null; - } - } - - public Map getQueries() { - return this.queries; - } - - public Session setQueries(Map queries) { - this.queries = queries; - return this; - } - - public void unsetQueries() { - this.queries = null; - } - - // Returns true if field queries is set (has been assigned a value) and false otherwise - public boolean isSetQueries() { - return this.queries != null; - } - - public void setQueriesIsSet(boolean __value) { - if (!__value) { - this.queries = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SESSION_ID: - if (__value == null) { - unsetSession_id(); - } else { - setSession_id((Long)__value); - } - break; - - case CREATE_TIME: - if (__value == null) { - unsetCreate_time(); - } else { - setCreate_time((Long)__value); - } - break; - - case UPDATE_TIME: - if (__value == null) { - unsetUpdate_time(); - } else { - setUpdate_time((Long)__value); - } - break; - - case USER_NAME: - if (__value == null) { - unsetUser_name(); - } else { - setUser_name((byte[])__value); - } - break; - - case SPACE_NAME: - if (__value == null) { - unsetSpace_name(); - } else { - setSpace_name((byte[])__value); - } - break; - - case GRAPH_ADDR: - if (__value == null) { - unsetGraph_addr(); - } else { - setGraph_addr((com.vesoft.nebula.HostAddr)__value); - } - break; - - case TIMEZONE: - if (__value == null) { - unsetTimezone(); - } else { - setTimezone((Integer)__value); - } - break; - - case CLIENT_IP: - if (__value == null) { - unsetClient_ip(); - } else { - setClient_ip((byte[])__value); - } - break; - - case CONFIGS: - if (__value == null) { - unsetConfigs(); - } else { - setConfigs((Map)__value); - } - break; - - case QUERIES: - if (__value == null) { - unsetQueries(); - } else { - setQueries((Map)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SESSION_ID: - return new Long(getSession_id()); - - case CREATE_TIME: - return new Long(getCreate_time()); - - case UPDATE_TIME: - return new Long(getUpdate_time()); - - case USER_NAME: - return getUser_name(); - - case SPACE_NAME: - return getSpace_name(); - - case GRAPH_ADDR: - return getGraph_addr(); - - case TIMEZONE: - return new Integer(getTimezone()); - - case CLIENT_IP: - return getClient_ip(); - - case CONFIGS: - return getConfigs(); - - case QUERIES: - return getQueries(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof Session)) - return false; - Session that = (Session)_that; - - if (!TBaseHelper.equalsNobinary(this.session_id, that.session_id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.create_time, that.create_time)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.update_time, that.update_time)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetUser_name(), that.isSetUser_name(), this.user_name, that.user_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetSpace_name(), that.isSetSpace_name(), this.space_name, that.space_name)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetClient_ip(), that.isSetClient_ip(), this.client_ip, that.client_ip)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetConfigs(), that.isSetConfigs(), this.configs, that.configs)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetQueries(), that.isSetQueries(), this.queries, that.queries)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {session_id, create_time, update_time, user_name, space_name, graph_addr, timezone, client_ip, configs, queries}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SESSION_ID: - if (__field.type == TType.I64) { - this.session_id = iprot.readI64(); - setSession_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CREATE_TIME: - if (__field.type == TType.I64) { - this.create_time = iprot.readI64(); - setCreate_timeIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case UPDATE_TIME: - if (__field.type == TType.I64) { - this.update_time = iprot.readI64(); - setUpdate_timeIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case USER_NAME: - if (__field.type == TType.STRING) { - this.user_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SPACE_NAME: - if (__field.type == TType.STRING) { - this.space_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case GRAPH_ADDR: - if (__field.type == TType.STRUCT) { - this.graph_addr = new com.vesoft.nebula.HostAddr(); - this.graph_addr.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case TIMEZONE: - if (__field.type == TType.I32) { - this.timezone = iprot.readI32(); - setTimezoneIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CLIENT_IP: - if (__field.type == TType.STRING) { - this.client_ip = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CONFIGS: - if (__field.type == TType.MAP) { - { - TMap _map26 = iprot.readMapBegin(); - this.configs = new HashMap(Math.max(0, 2*_map26.size)); - for (int _i27 = 0; - (_map26.size < 0) ? iprot.peekMap() : (_i27 < _map26.size); - ++_i27) - { - byte[] _key28; - com.vesoft.nebula.Value _val29; - _key28 = iprot.readBinary(); - _val29 = new com.vesoft.nebula.Value(); - _val29.read(iprot); - this.configs.put(_key28, _val29); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case QUERIES: - if (__field.type == TType.MAP) { - { - TMap _map30 = iprot.readMapBegin(); - this.queries = new HashMap(Math.max(0, 2*_map30.size)); - for (int _i31 = 0; - (_map30.size < 0) ? iprot.peekMap() : (_i31 < _map30.size); - ++_i31) - { - long _key32; - QueryDesc _val33; - _key32 = iprot.readI64(); - _val33 = new QueryDesc(); - _val33.read(iprot); - this.queries.put(_key32, _val33); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); - oprot.writeI64(this.session_id); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); - oprot.writeI64(this.create_time); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(UPDATE_TIME_FIELD_DESC); - oprot.writeI64(this.update_time); - oprot.writeFieldEnd(); - if (this.user_name != null) { - oprot.writeFieldBegin(USER_NAME_FIELD_DESC); - oprot.writeBinary(this.user_name); - oprot.writeFieldEnd(); - } - if (this.space_name != null) { - oprot.writeFieldBegin(SPACE_NAME_FIELD_DESC); - oprot.writeBinary(this.space_name); - oprot.writeFieldEnd(); - } - if (this.graph_addr != null) { - oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); - this.graph_addr.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); - oprot.writeI32(this.timezone); - oprot.writeFieldEnd(); - if (this.client_ip != null) { - oprot.writeFieldBegin(CLIENT_IP_FIELD_DESC); - oprot.writeBinary(this.client_ip); - oprot.writeFieldEnd(); - } - if (this.configs != null) { - oprot.writeFieldBegin(CONFIGS_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.configs.size())); - for (Map.Entry _iter34 : this.configs.entrySet()) { - oprot.writeBinary(_iter34.getKey()); - _iter34.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - if (this.queries != null) { - oprot.writeFieldBegin(QUERIES_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, this.queries.size())); - for (Map.Entry _iter35 : this.queries.entrySet()) { - oprot.writeI64(_iter35.getKey()); - _iter35.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("Session"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("session_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSession_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("create_time"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getCreate_time(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("update_time"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getUpdate_time(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("user_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getUser_name() == null) { - sb.append("null"); - } else { - int __user_name_size = Math.min(this.getUser_name().length, 128); - for (int i = 0; i < __user_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getUser_name()[i]).length() > 1 ? Integer.toHexString(this.getUser_name()[i]).substring(Integer.toHexString(this.getUser_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getUser_name()[i]).toUpperCase()); - } - if (this.getUser_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("space_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getSpace_name() == null) { - sb.append("null"); - } else { - int __space_name_size = Math.min(this.getSpace_name().length, 128); - for (int i = 0; i < __space_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getSpace_name()[i]).length() > 1 ? Integer.toHexString(this.getSpace_name()[i]).substring(Integer.toHexString(this.getSpace_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getSpace_name()[i]).toUpperCase()); - } - if (this.getSpace_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("graph_addr"); - sb.append(space); - sb.append(":").append(space); - if (this.getGraph_addr() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("timezone"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("client_ip"); - sb.append(space); - sb.append(":").append(space); - if (this.getClient_ip() == null) { - sb.append("null"); - } else { - int __client_ip_size = Math.min(this.getClient_ip().length, 128); - for (int i = 0; i < __client_ip_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getClient_ip()[i]).length() > 1 ? Integer.toHexString(this.getClient_ip()[i]).substring(Integer.toHexString(this.getClient_ip()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getClient_ip()[i]).toUpperCase()); - } - if (this.getClient_ip().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("configs"); - sb.append(space); - sb.append(":").append(space); - if (this.getConfigs() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getConfigs(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("queries"); - sb.append(space); - sb.append(":").append(space); - if (this.getQueries() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getQueries(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java deleted file mode 100644 index 8f33f1678..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddGroupReq.java +++ /dev/null @@ -1,375 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class AddGroupReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("AddGroupReq"); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)1); - private static final TField ZONE_NAMES_FIELD_DESC = new TField("zone_names", TType.LIST, (short)2); - - public byte[] group_name; - public List zone_names; - public static final int GROUP_NAME = 1; - public static final int ZONE_NAMES = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(ZONE_NAMES, new FieldMetaData("zone_names", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new FieldValueMetaData(TType.STRING)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(AddGroupReq.class, metaDataMap); - } - - public AddGroupReq() { - } - - public AddGroupReq( - byte[] group_name, - List zone_names) { - this(); - this.group_name = group_name; - this.zone_names = zone_names; - } - - public static class Builder { - private byte[] group_name; - private List zone_names; - - public Builder() { - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public Builder setZone_names(final List zone_names) { - this.zone_names = zone_names; - return this; - } - - public AddGroupReq build() { - AddGroupReq result = new AddGroupReq(); - result.setGroup_name(this.group_name); - result.setZone_names(this.zone_names); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public AddGroupReq(AddGroupReq other) { - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - if (other.isSetZone_names()) { - this.zone_names = TBaseHelper.deepCopy(other.zone_names); - } - } - - public AddGroupReq deepCopy() { - return new AddGroupReq(this); - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public AddGroupReq setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public List getZone_names() { - return this.zone_names; - } - - public AddGroupReq setZone_names(List zone_names) { - this.zone_names = zone_names; - return this; - } - - public void unsetZone_names() { - this.zone_names = null; - } - - // Returns true if field zone_names is set (has been assigned a value) and false otherwise - public boolean isSetZone_names() { - return this.zone_names != null; - } - - public void setZone_namesIsSet(boolean __value) { - if (!__value) { - this.zone_names = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - case ZONE_NAMES: - if (__value == null) { - unsetZone_names(); - } else { - setZone_names((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case GROUP_NAME: - return getGroup_name(); - - case ZONE_NAMES: - return getZone_names(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof AddGroupReq)) - return false; - AddGroupReq that = (AddGroupReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetZone_names(), that.isSetZone_names(), this.zone_names, that.zone_names)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {group_name, zone_names}); - } - - @Override - public int compareTo(AddGroupReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetZone_names()).compareTo(other.isSetZone_names()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_names, other.zone_names); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ZONE_NAMES: - if (__field.type == TType.LIST) { - { - TList _list210 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list210.size)); - for (int _i211 = 0; - (_list210.size < 0) ? iprot.peekList() : (_i211 < _list210.size); - ++_i211) - { - byte[] _elem212; - _elem212 = iprot.readBinary(); - this.zone_names.add(_elem212); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - if (this.zone_names != null) { - oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter213 : this.zone_names) { - oprot.writeBinary(_iter213); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("AddGroupReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("zone_names"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_names() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getZone_names(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddHostIntoZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddHostIntoZoneReq.java deleted file mode 100644 index 85783430d..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddHostIntoZoneReq.java +++ /dev/null @@ -1,356 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class AddHostIntoZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("AddHostIntoZoneReq"); - private static final TField NODE_FIELD_DESC = new TField("node", TType.STRUCT, (short)1); - private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)2); - - public com.vesoft.nebula.HostAddr node; - public byte[] zone_name; - public static final int NODE = 1; - public static final int ZONE_NAME = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(NODE, new FieldMetaData("node", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(AddHostIntoZoneReq.class, metaDataMap); - } - - public AddHostIntoZoneReq() { - } - - public AddHostIntoZoneReq( - com.vesoft.nebula.HostAddr node, - byte[] zone_name) { - this(); - this.node = node; - this.zone_name = zone_name; - } - - public static class Builder { - private com.vesoft.nebula.HostAddr node; - private byte[] zone_name; - - public Builder() { - } - - public Builder setNode(final com.vesoft.nebula.HostAddr node) { - this.node = node; - return this; - } - - public Builder setZone_name(final byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public AddHostIntoZoneReq build() { - AddHostIntoZoneReq result = new AddHostIntoZoneReq(); - result.setNode(this.node); - result.setZone_name(this.zone_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public AddHostIntoZoneReq(AddHostIntoZoneReq other) { - if (other.isSetNode()) { - this.node = TBaseHelper.deepCopy(other.node); - } - if (other.isSetZone_name()) { - this.zone_name = TBaseHelper.deepCopy(other.zone_name); - } - } - - public AddHostIntoZoneReq deepCopy() { - return new AddHostIntoZoneReq(this); - } - - public com.vesoft.nebula.HostAddr getNode() { - return this.node; - } - - public AddHostIntoZoneReq setNode(com.vesoft.nebula.HostAddr node) { - this.node = node; - return this; - } - - public void unsetNode() { - this.node = null; - } - - // Returns true if field node is set (has been assigned a value) and false otherwise - public boolean isSetNode() { - return this.node != null; - } - - public void setNodeIsSet(boolean __value) { - if (!__value) { - this.node = null; - } - } - - public byte[] getZone_name() { - return this.zone_name; - } - - public AddHostIntoZoneReq setZone_name(byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public void unsetZone_name() { - this.zone_name = null; - } - - // Returns true if field zone_name is set (has been assigned a value) and false otherwise - public boolean isSetZone_name() { - return this.zone_name != null; - } - - public void setZone_nameIsSet(boolean __value) { - if (!__value) { - this.zone_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case NODE: - if (__value == null) { - unsetNode(); - } else { - setNode((com.vesoft.nebula.HostAddr)__value); - } - break; - - case ZONE_NAME: - if (__value == null) { - unsetZone_name(); - } else { - setZone_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case NODE: - return getNode(); - - case ZONE_NAME: - return getZone_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof AddHostIntoZoneReq)) - return false; - AddHostIntoZoneReq that = (AddHostIntoZoneReq)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetNode(), that.isSetNode(), this.node, that.node)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {node, zone_name}); - } - - @Override - public int compareTo(AddHostIntoZoneReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetNode()).compareTo(other.isSetNode()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(node, other.node); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case NODE: - if (__field.type == TType.STRUCT) { - this.node = new com.vesoft.nebula.HostAddr(); - this.node.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ZONE_NAME: - if (__field.type == TType.STRING) { - this.zone_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.node != null) { - oprot.writeFieldBegin(NODE_FIELD_DESC); - this.node.write(oprot); - oprot.writeFieldEnd(); - } - if (this.zone_name != null) { - oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); - oprot.writeBinary(this.zone_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("AddHostIntoZoneReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("node"); - sb.append(space); - sb.append(":").append(space); - if (this.getNode() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getNode(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("zone_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_name() == null) { - sb.append("null"); - } else { - int __zone_name_size = Math.min(this.getZone_name().length, 128); - for (int i = 0; i < __zone_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); - } - if (this.getZone_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java index ac8fdfb53..8b648b877 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddHostsIntoZoneReq.java @@ -329,16 +329,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list224 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list224.size)); - for (int _i225 = 0; - (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); - ++_i225) + TList _list228 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list228.size)); + for (int _i229 = 0; + (_list228.size < 0) ? iprot.peekList() : (_i229 < _list228.size); + ++_i229) { - com.vesoft.nebula.HostAddr _elem226; - _elem226 = new com.vesoft.nebula.HostAddr(); - _elem226.read(iprot); - this.hosts.add(_elem226); + com.vesoft.nebula.HostAddr _elem230; + _elem230 = new com.vesoft.nebula.HostAddr(); + _elem230.read(iprot); + this.hosts.add(_elem230); } iprot.readListEnd(); } @@ -382,8 +382,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter227 : this.hosts) { - _iter227.write(oprot); + for (com.vesoft.nebula.HostAddr _iter231 : this.hosts) { + _iter231.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java index 4ed5f7422..387723ac1 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AddListenerReq.java @@ -356,16 +356,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list240 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list240.size)); - for (int _i241 = 0; - (_list240.size < 0) ? iprot.peekList() : (_i241 < _list240.size); - ++_i241) + TList _list244 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list244.size)); + for (int _i245 = 0; + (_list244.size < 0) ? iprot.peekList() : (_i245 < _list244.size); + ++_i245) { - com.vesoft.nebula.HostAddr _elem242; - _elem242 = new com.vesoft.nebula.HostAddr(); - _elem242.read(iprot); - this.hosts.add(_elem242); + com.vesoft.nebula.HostAddr _elem246; + _elem246 = new com.vesoft.nebula.HostAddr(); + _elem246.read(iprot); + this.hosts.add(_elem246); } iprot.readListEnd(); } @@ -402,8 +402,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter243 : this.hosts) { - _iter243.write(oprot); + for (com.vesoft.nebula.HostAddr _iter247 : this.hosts) { + _iter247.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneIntoGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddZoneIntoGroupReq.java deleted file mode 100644 index b3eec6577..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneIntoGroupReq.java +++ /dev/null @@ -1,360 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class AddZoneIntoGroupReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("AddZoneIntoGroupReq"); - private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)1); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)2); - - public byte[] zone_name; - public byte[] group_name; - public static final int ZONE_NAME = 1; - public static final int GROUP_NAME = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(AddZoneIntoGroupReq.class, metaDataMap); - } - - public AddZoneIntoGroupReq() { - } - - public AddZoneIntoGroupReq( - byte[] zone_name, - byte[] group_name) { - this(); - this.zone_name = zone_name; - this.group_name = group_name; - } - - public static class Builder { - private byte[] zone_name; - private byte[] group_name; - - public Builder() { - } - - public Builder setZone_name(final byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public AddZoneIntoGroupReq build() { - AddZoneIntoGroupReq result = new AddZoneIntoGroupReq(); - result.setZone_name(this.zone_name); - result.setGroup_name(this.group_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public AddZoneIntoGroupReq(AddZoneIntoGroupReq other) { - if (other.isSetZone_name()) { - this.zone_name = TBaseHelper.deepCopy(other.zone_name); - } - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - } - - public AddZoneIntoGroupReq deepCopy() { - return new AddZoneIntoGroupReq(this); - } - - public byte[] getZone_name() { - return this.zone_name; - } - - public AddZoneIntoGroupReq setZone_name(byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public void unsetZone_name() { - this.zone_name = null; - } - - // Returns true if field zone_name is set (has been assigned a value) and false otherwise - public boolean isSetZone_name() { - return this.zone_name != null; - } - - public void setZone_nameIsSet(boolean __value) { - if (!__value) { - this.zone_name = null; - } - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public AddZoneIntoGroupReq setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case ZONE_NAME: - if (__value == null) { - unsetZone_name(); - } else { - setZone_name((byte[])__value); - } - break; - - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case ZONE_NAME: - return getZone_name(); - - case GROUP_NAME: - return getGroup_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof AddZoneIntoGroupReq)) - return false; - AddZoneIntoGroupReq that = (AddZoneIntoGroupReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {zone_name, group_name}); - } - - @Override - public int compareTo(AddZoneIntoGroupReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case ZONE_NAME: - if (__field.type == TType.STRING) { - this.zone_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.zone_name != null) { - oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); - oprot.writeBinary(this.zone_name); - oprot.writeFieldEnd(); - } - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("AddZoneIntoGroupReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("zone_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_name() == null) { - sb.append("null"); - } else { - int __zone_name_size = Math.min(this.getZone_name().length, 128); - for (int i = 0; i < __zone_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); - } - if (this.getZone_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java deleted file mode 100644 index ad8c74265..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/AddZoneReq.java +++ /dev/null @@ -1,376 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class AddZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("AddZoneReq"); - private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)1); - private static final TField NODES_FIELD_DESC = new TField("nodes", TType.LIST, (short)2); - - public byte[] zone_name; - public List nodes; - public static final int ZONE_NAME = 1; - public static final int NODES = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(NODES, new FieldMetaData("nodes", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(AddZoneReq.class, metaDataMap); - } - - public AddZoneReq() { - } - - public AddZoneReq( - byte[] zone_name, - List nodes) { - this(); - this.zone_name = zone_name; - this.nodes = nodes; - } - - public static class Builder { - private byte[] zone_name; - private List nodes; - - public Builder() { - } - - public Builder setZone_name(final byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public Builder setNodes(final List nodes) { - this.nodes = nodes; - return this; - } - - public AddZoneReq build() { - AddZoneReq result = new AddZoneReq(); - result.setZone_name(this.zone_name); - result.setNodes(this.nodes); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public AddZoneReq(AddZoneReq other) { - if (other.isSetZone_name()) { - this.zone_name = TBaseHelper.deepCopy(other.zone_name); - } - if (other.isSetNodes()) { - this.nodes = TBaseHelper.deepCopy(other.nodes); - } - } - - public AddZoneReq deepCopy() { - return new AddZoneReq(this); - } - - public byte[] getZone_name() { - return this.zone_name; - } - - public AddZoneReq setZone_name(byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public void unsetZone_name() { - this.zone_name = null; - } - - // Returns true if field zone_name is set (has been assigned a value) and false otherwise - public boolean isSetZone_name() { - return this.zone_name != null; - } - - public void setZone_nameIsSet(boolean __value) { - if (!__value) { - this.zone_name = null; - } - } - - public List getNodes() { - return this.nodes; - } - - public AddZoneReq setNodes(List nodes) { - this.nodes = nodes; - return this; - } - - public void unsetNodes() { - this.nodes = null; - } - - // Returns true if field nodes is set (has been assigned a value) and false otherwise - public boolean isSetNodes() { - return this.nodes != null; - } - - public void setNodesIsSet(boolean __value) { - if (!__value) { - this.nodes = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case ZONE_NAME: - if (__value == null) { - unsetZone_name(); - } else { - setZone_name((byte[])__value); - } - break; - - case NODES: - if (__value == null) { - unsetNodes(); - } else { - setNodes((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case ZONE_NAME: - return getZone_name(); - - case NODES: - return getNodes(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof AddZoneReq)) - return false; - AddZoneReq that = (AddZoneReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetNodes(), that.isSetNodes(), this.nodes, that.nodes)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {zone_name, nodes}); - } - - @Override - public int compareTo(AddZoneReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetNodes()).compareTo(other.isSetNodes()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(nodes, other.nodes); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case ZONE_NAME: - if (__field.type == TType.STRING) { - this.zone_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case NODES: - if (__field.type == TType.LIST) { - { - TList _list208 = iprot.readListBegin(); - this.nodes = new ArrayList(Math.max(0, _list208.size)); - for (int _i209 = 0; - (_list208.size < 0) ? iprot.peekList() : (_i209 < _list208.size); - ++_i209) - { - com.vesoft.nebula.HostAddr _elem210; - _elem210 = new com.vesoft.nebula.HostAddr(); - _elem210.read(iprot); - this.nodes.add(_elem210); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.zone_name != null) { - oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); - oprot.writeBinary(this.zone_name); - oprot.writeFieldEnd(); - } - if (this.nodes != null) { - oprot.writeFieldBegin(NODES_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.nodes.size())); - for (com.vesoft.nebula.HostAddr _iter211 : this.nodes) { - _iter211.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("AddZoneReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("zone_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_name() == null) { - sb.append("null"); - } else { - int __zone_name_size = Math.min(this.getZone_name().length, 128); - for (int i = 0; i < __zone_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); - } - if (this.getZone_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("nodes"); - sb.append(space); - sb.append(":").append(space); - if (this.getNodes() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getNodes(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/AgentHBReq.java b/client/src/main/generated/com/vesoft/nebula/meta/AgentHBReq.java new file mode 100644 index 000000000..2fb303732 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/AgentHBReq.java @@ -0,0 +1,459 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class AgentHBReq implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("AgentHBReq"); + private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)1); + private static final TField GIT_INFO_SHA_FIELD_DESC = new TField("git_info_sha", TType.STRING, (short)2); + private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)3); + + public com.vesoft.nebula.HostAddr host; + public byte[] git_info_sha; + public byte[] version; + public static final int HOST = 1; + public static final int GIT_INFO_SHA = 2; + public static final int VERSION = 3; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(HOST, new FieldMetaData("host", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(GIT_INFO_SHA, new FieldMetaData("git_info_sha", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(AgentHBReq.class, metaDataMap); + } + + public AgentHBReq() { + } + + public AgentHBReq( + com.vesoft.nebula.HostAddr host, + byte[] git_info_sha) { + this(); + this.host = host; + this.git_info_sha = git_info_sha; + } + + public AgentHBReq( + com.vesoft.nebula.HostAddr host, + byte[] git_info_sha, + byte[] version) { + this(); + this.host = host; + this.git_info_sha = git_info_sha; + this.version = version; + } + + public static class Builder { + private com.vesoft.nebula.HostAddr host; + private byte[] git_info_sha; + private byte[] version; + + public Builder() { + } + + public Builder setHost(final com.vesoft.nebula.HostAddr host) { + this.host = host; + return this; + } + + public Builder setGit_info_sha(final byte[] git_info_sha) { + this.git_info_sha = git_info_sha; + return this; + } + + public Builder setVersion(final byte[] version) { + this.version = version; + return this; + } + + public AgentHBReq build() { + AgentHBReq result = new AgentHBReq(); + result.setHost(this.host); + result.setGit_info_sha(this.git_info_sha); + result.setVersion(this.version); + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public AgentHBReq(AgentHBReq other) { + if (other.isSetHost()) { + this.host = TBaseHelper.deepCopy(other.host); + } + if (other.isSetGit_info_sha()) { + this.git_info_sha = TBaseHelper.deepCopy(other.git_info_sha); + } + if (other.isSetVersion()) { + this.version = TBaseHelper.deepCopy(other.version); + } + } + + public AgentHBReq deepCopy() { + return new AgentHBReq(this); + } + + public com.vesoft.nebula.HostAddr getHost() { + return this.host; + } + + public AgentHBReq setHost(com.vesoft.nebula.HostAddr host) { + this.host = host; + return this; + } + + public void unsetHost() { + this.host = null; + } + + // Returns true if field host is set (has been assigned a value) and false otherwise + public boolean isSetHost() { + return this.host != null; + } + + public void setHostIsSet(boolean __value) { + if (!__value) { + this.host = null; + } + } + + public byte[] getGit_info_sha() { + return this.git_info_sha; + } + + public AgentHBReq setGit_info_sha(byte[] git_info_sha) { + this.git_info_sha = git_info_sha; + return this; + } + + public void unsetGit_info_sha() { + this.git_info_sha = null; + } + + // Returns true if field git_info_sha is set (has been assigned a value) and false otherwise + public boolean isSetGit_info_sha() { + return this.git_info_sha != null; + } + + public void setGit_info_shaIsSet(boolean __value) { + if (!__value) { + this.git_info_sha = null; + } + } + + public byte[] getVersion() { + return this.version; + } + + public AgentHBReq setVersion(byte[] version) { + this.version = version; + return this; + } + + public void unsetVersion() { + this.version = null; + } + + // Returns true if field version is set (has been assigned a value) and false otherwise + public boolean isSetVersion() { + return this.version != null; + } + + public void setVersionIsSet(boolean __value) { + if (!__value) { + this.version = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case HOST: + if (__value == null) { + unsetHost(); + } else { + setHost((com.vesoft.nebula.HostAddr)__value); + } + break; + + case GIT_INFO_SHA: + if (__value == null) { + unsetGit_info_sha(); + } else { + setGit_info_sha((byte[])__value); + } + break; + + case VERSION: + if (__value == null) { + unsetVersion(); + } else { + setVersion((byte[])__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case HOST: + return getHost(); + + case GIT_INFO_SHA: + return getGit_info_sha(); + + case VERSION: + return getVersion(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof AgentHBReq)) + return false; + AgentHBReq that = (AgentHBReq)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetHost(), that.isSetHost(), this.host, that.host)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetGit_info_sha(), that.isSetGit_info_sha(), this.git_info_sha, that.git_info_sha)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {host, git_info_sha, version}); + } + + @Override + public int compareTo(AgentHBReq other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetHost()).compareTo(other.isSetHost()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(host, other.host); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetGit_info_sha()).compareTo(other.isSetGit_info_sha()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(git_info_sha, other.git_info_sha); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(version, other.version); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case HOST: + if (__field.type == TType.STRUCT) { + this.host = new com.vesoft.nebula.HostAddr(); + this.host.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case GIT_INFO_SHA: + if (__field.type == TType.STRING) { + this.git_info_sha = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case VERSION: + if (__field.type == TType.STRING) { + this.version = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.host != null) { + oprot.writeFieldBegin(HOST_FIELD_DESC); + this.host.write(oprot); + oprot.writeFieldEnd(); + } + if (this.git_info_sha != null) { + oprot.writeFieldBegin(GIT_INFO_SHA_FIELD_DESC); + oprot.writeBinary(this.git_info_sha); + oprot.writeFieldEnd(); + } + if (this.version != null) { + if (isSetVersion()) { + oprot.writeFieldBegin(VERSION_FIELD_DESC); + oprot.writeBinary(this.version); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("AgentHBReq"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("host"); + sb.append(space); + sb.append(":").append(space); + if (this.getHost() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getHost(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("git_info_sha"); + sb.append(space); + sb.append(":").append(space); + if (this.getGit_info_sha() == null) { + sb.append("null"); + } else { + int __git_info_sha_size = Math.min(this.getGit_info_sha().length, 128); + for (int i = 0; i < __git_info_sha_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getGit_info_sha()[i]).length() > 1 ? Integer.toHexString(this.getGit_info_sha()[i]).substring(Integer.toHexString(this.getGit_info_sha()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGit_info_sha()[i]).toUpperCase()); + } + if (this.getGit_info_sha().length > 128) sb.append(" ..."); + } + first = false; + if (isSetVersion()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("version"); + sb.append(space); + sb.append(":").append(space); + if (this.getVersion() == null) { + sb.append("null"); + } else { + int __version_size = Math.min(this.getVersion().length, 128); + for (int i = 0; i < __version_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); + } + if (this.getVersion().length > 128) sb.append(" ..."); + } + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/AgentHBResp.java similarity index 72% rename from client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java rename to client/src/main/generated/com/vesoft/nebula/meta/AgentHBResp.java index c7ddca52f..f85d0c649 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/AgentHBResp.java @@ -24,11 +24,11 @@ import com.facebook.thrift.protocol.*; @SuppressWarnings({ "unused", "serial" }) -public class ListGroupsResp implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("ListGroupsResp"); +public class AgentHBResp implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("AgentHBResp"); private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField GROUPS_FIELD_DESC = new TField("groups", TType.LIST, (short)3); + private static final TField SERVICE_LIST_FIELD_DESC = new TField("service_list", TType.LIST, (short)3); /** * @@ -36,10 +36,10 @@ public class ListGroupsResp implements TBase, java.io.Serializable, Cloneable, C */ public com.vesoft.nebula.ErrorCode code; public com.vesoft.nebula.HostAddr leader; - public List groups; + public List service_list; public static final int CODE = 1; public static final int LEADER = 2; - public static final int GROUPS = 3; + public static final int SERVICE_LIST = 3; // isset id assignments @@ -51,33 +51,33 @@ public class ListGroupsResp implements TBase, java.io.Serializable, Cloneable, C new FieldValueMetaData(TType.I32))); tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(GROUPS, new FieldMetaData("groups", TFieldRequirementType.DEFAULT, + tmpMetaDataMap.put(SERVICE_LIST, new FieldMetaData("service_list", TFieldRequirementType.DEFAULT, new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Group.class)))); + new StructMetaData(TType.STRUCT, ServiceInfo.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(ListGroupsResp.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(AgentHBResp.class, metaDataMap); } - public ListGroupsResp() { + public AgentHBResp() { } - public ListGroupsResp( + public AgentHBResp( com.vesoft.nebula.ErrorCode code, com.vesoft.nebula.HostAddr leader, - List groups) { + List service_list) { this(); this.code = code; this.leader = leader; - this.groups = groups; + this.service_list = service_list; } public static class Builder { private com.vesoft.nebula.ErrorCode code; private com.vesoft.nebula.HostAddr leader; - private List groups; + private List service_list; public Builder() { } @@ -92,16 +92,16 @@ public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { return this; } - public Builder setGroups(final List groups) { - this.groups = groups; + public Builder setService_list(final List service_list) { + this.service_list = service_list; return this; } - public ListGroupsResp build() { - ListGroupsResp result = new ListGroupsResp(); + public AgentHBResp build() { + AgentHBResp result = new AgentHBResp(); result.setCode(this.code); result.setLeader(this.leader); - result.setGroups(this.groups); + result.setService_list(this.service_list); return result; } } @@ -113,20 +113,20 @@ public static Builder builder() { /** * Performs a deep copy on other. */ - public ListGroupsResp(ListGroupsResp other) { + public AgentHBResp(AgentHBResp other) { if (other.isSetCode()) { this.code = TBaseHelper.deepCopy(other.code); } if (other.isSetLeader()) { this.leader = TBaseHelper.deepCopy(other.leader); } - if (other.isSetGroups()) { - this.groups = TBaseHelper.deepCopy(other.groups); + if (other.isSetService_list()) { + this.service_list = TBaseHelper.deepCopy(other.service_list); } } - public ListGroupsResp deepCopy() { - return new ListGroupsResp(this); + public AgentHBResp deepCopy() { + return new AgentHBResp(this); } /** @@ -141,7 +141,7 @@ public com.vesoft.nebula.ErrorCode getCode() { * * @see com.vesoft.nebula.ErrorCode */ - public ListGroupsResp setCode(com.vesoft.nebula.ErrorCode code) { + public AgentHBResp setCode(com.vesoft.nebula.ErrorCode code) { this.code = code; return this; } @@ -165,7 +165,7 @@ public com.vesoft.nebula.HostAddr getLeader() { return this.leader; } - public ListGroupsResp setLeader(com.vesoft.nebula.HostAddr leader) { + public AgentHBResp setLeader(com.vesoft.nebula.HostAddr leader) { this.leader = leader; return this; } @@ -185,27 +185,27 @@ public void setLeaderIsSet(boolean __value) { } } - public List getGroups() { - return this.groups; + public List getService_list() { + return this.service_list; } - public ListGroupsResp setGroups(List groups) { - this.groups = groups; + public AgentHBResp setService_list(List service_list) { + this.service_list = service_list; return this; } - public void unsetGroups() { - this.groups = null; + public void unsetService_list() { + this.service_list = null; } - // Returns true if field groups is set (has been assigned a value) and false otherwise - public boolean isSetGroups() { - return this.groups != null; + // Returns true if field service_list is set (has been assigned a value) and false otherwise + public boolean isSetService_list() { + return this.service_list != null; } - public void setGroupsIsSet(boolean __value) { + public void setService_listIsSet(boolean __value) { if (!__value) { - this.groups = null; + this.service_list = null; } } @@ -228,11 +228,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case GROUPS: + case SERVICE_LIST: if (__value == null) { - unsetGroups(); + unsetService_list(); } else { - setGroups((List)__value); + setService_list((List)__value); } break; @@ -249,8 +249,8 @@ public Object getFieldValue(int fieldID) { case LEADER: return getLeader(); - case GROUPS: - return getGroups(); + case SERVICE_LIST: + return getService_list(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -263,26 +263,26 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof ListGroupsResp)) + if (!(_that instanceof AgentHBResp)) return false; - ListGroupsResp that = (ListGroupsResp)_that; + AgentHBResp that = (AgentHBResp)_that; if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - if (!TBaseHelper.equalsNobinary(this.isSetGroups(), that.isSetGroups(), this.groups, that.groups)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetService_list(), that.isSetService_list(), this.service_list, that.service_list)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, groups}); + return Arrays.deepHashCode(new Object[] {code, leader, service_list}); } @Override - public int compareTo(ListGroupsResp other) { + public int compareTo(AgentHBResp other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -309,11 +309,11 @@ public int compareTo(ListGroupsResp other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetGroups()).compareTo(other.isSetGroups()); + lastComparison = Boolean.valueOf(isSetService_list()).compareTo(other.isSetService_list()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(groups, other.groups); + lastComparison = TBaseHelper.compareTo(service_list, other.service_list); if (lastComparison != 0) { return lastComparison; } @@ -346,19 +346,19 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case GROUPS: + case SERVICE_LIST: if (__field.type == TType.LIST) { { - TList _list222 = iprot.readListBegin(); - this.groups = new ArrayList(Math.max(0, _list222.size)); - for (int _i223 = 0; - (_list222.size < 0) ? iprot.peekList() : (_i223 < _list222.size); - ++_i223) + TList _list175 = iprot.readListBegin(); + this.service_list = new ArrayList(Math.max(0, _list175.size)); + for (int _i176 = 0; + (_list175.size < 0) ? iprot.peekList() : (_i176 < _list175.size); + ++_i176) { - Group _elem224; - _elem224 = new Group(); - _elem224.read(iprot); - this.groups.add(_elem224); + ServiceInfo _elem177; + _elem177 = new ServiceInfo(); + _elem177.read(iprot); + this.service_list.add(_elem177); } iprot.readListEnd(); } @@ -393,12 +393,12 @@ public void write(TProtocol oprot) throws TException { this.leader.write(oprot); oprot.writeFieldEnd(); } - if (this.groups != null) { - oprot.writeFieldBegin(GROUPS_FIELD_DESC); + if (this.service_list != null) { + oprot.writeFieldBegin(SERVICE_LIST_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.STRUCT, this.groups.size())); - for (Group _iter225 : this.groups) { - _iter225.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, this.service_list.size())); + for (ServiceInfo _iter178 : this.service_list) { + _iter178.write(oprot); } oprot.writeListEnd(); } @@ -418,7 +418,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListGroupsResp"); + StringBuilder sb = new StringBuilder("AgentHBResp"); sb.append(space); sb.append("("); sb.append(newLine); @@ -455,13 +455,13 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("groups"); + sb.append("service_list"); sb.append(space); sb.append(":").append(space); - if (this.getGroups() == null) { + if (this.getService_list() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getGroups(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getService_list(), indent + 1, prettyPrint)); } first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java index 0ab43acc0..fd8acb68b 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/BackupMeta.java @@ -26,29 +26,29 @@ @SuppressWarnings({ "unused", "serial" }) public class BackupMeta implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("BackupMeta"); - private static final TField BACKUP_INFO_FIELD_DESC = new TField("backup_info", TType.MAP, (short)1); + private static final TField SPACE_BACKUPS_FIELD_DESC = new TField("space_backups", TType.MAP, (short)1); private static final TField META_FILES_FIELD_DESC = new TField("meta_files", TType.LIST, (short)2); private static final TField BACKUP_NAME_FIELD_DESC = new TField("backup_name", TType.STRING, (short)3); private static final TField FULL_FIELD_DESC = new TField("full", TType.BOOL, (short)4); - private static final TField INCLUDE_SYSTEM_SPACE_FIELD_DESC = new TField("include_system_space", TType.BOOL, (short)5); + private static final TField ALL_SPACES_FIELD_DESC = new TField("all_spaces", TType.BOOL, (short)5); private static final TField CREATE_TIME_FIELD_DESC = new TField("create_time", TType.I64, (short)6); - public Map backup_info; + public Map space_backups; public List meta_files; public byte[] backup_name; public boolean full; - public boolean include_system_space; + public boolean all_spaces; public long create_time; - public static final int BACKUP_INFO = 1; + public static final int SPACE_BACKUPS = 1; public static final int META_FILES = 2; public static final int BACKUP_NAME = 3; public static final int FULL = 4; - public static final int INCLUDE_SYSTEM_SPACE = 5; + public static final int ALL_SPACES = 5; public static final int CREATE_TIME = 6; // isset id assignments private static final int __FULL_ISSET_ID = 0; - private static final int __INCLUDE_SYSTEM_SPACE_ISSET_ID = 1; + private static final int __ALL_SPACES_ISSET_ID = 1; private static final int __CREATE_TIME_ISSET_ID = 2; private BitSet __isset_bit_vector = new BitSet(3); @@ -56,7 +56,7 @@ public class BackupMeta implements TBase, java.io.Serializable, Cloneable, Compa static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(BACKUP_INFO, new FieldMetaData("backup_info", TFieldRequirementType.DEFAULT, + tmpMetaDataMap.put(SPACE_BACKUPS, new FieldMetaData("space_backups", TFieldRequirementType.DEFAULT, new MapMetaData(TType.MAP, new FieldValueMetaData(TType.I32), new StructMetaData(TType.STRUCT, SpaceBackupInfo.class)))); @@ -67,7 +67,7 @@ public class BackupMeta implements TBase, java.io.Serializable, Cloneable, Compa new FieldValueMetaData(TType.STRING))); tmpMetaDataMap.put(FULL, new FieldMetaData("full", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.BOOL))); - tmpMetaDataMap.put(INCLUDE_SYSTEM_SPACE, new FieldMetaData("include_system_space", TFieldRequirementType.DEFAULT, + tmpMetaDataMap.put(ALL_SPACES, new FieldMetaData("all_spaces", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(CREATE_TIME, new FieldMetaData("create_time", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.I64))); @@ -82,30 +82,30 @@ public BackupMeta() { } public BackupMeta( - Map backup_info, + Map space_backups, List meta_files, byte[] backup_name, boolean full, - boolean include_system_space, + boolean all_spaces, long create_time) { this(); - this.backup_info = backup_info; + this.space_backups = space_backups; this.meta_files = meta_files; this.backup_name = backup_name; this.full = full; setFullIsSet(true); - this.include_system_space = include_system_space; - setInclude_system_spaceIsSet(true); + this.all_spaces = all_spaces; + setAll_spacesIsSet(true); this.create_time = create_time; setCreate_timeIsSet(true); } public static class Builder { - private Map backup_info; + private Map space_backups; private List meta_files; private byte[] backup_name; private boolean full; - private boolean include_system_space; + private boolean all_spaces; private long create_time; BitSet __optional_isset = new BitSet(3); @@ -113,8 +113,8 @@ public static class Builder { public Builder() { } - public Builder setBackup_info(final Map backup_info) { - this.backup_info = backup_info; + public Builder setSpace_backups(final Map space_backups) { + this.space_backups = space_backups; return this; } @@ -134,9 +134,9 @@ public Builder setFull(final boolean full) { return this; } - public Builder setInclude_system_space(final boolean include_system_space) { - this.include_system_space = include_system_space; - __optional_isset.set(__INCLUDE_SYSTEM_SPACE_ISSET_ID, true); + public Builder setAll_spaces(final boolean all_spaces) { + this.all_spaces = all_spaces; + __optional_isset.set(__ALL_SPACES_ISSET_ID, true); return this; } @@ -148,14 +148,14 @@ public Builder setCreate_time(final long create_time) { public BackupMeta build() { BackupMeta result = new BackupMeta(); - result.setBackup_info(this.backup_info); + result.setSpace_backups(this.space_backups); result.setMeta_files(this.meta_files); result.setBackup_name(this.backup_name); if (__optional_isset.get(__FULL_ISSET_ID)) { result.setFull(this.full); } - if (__optional_isset.get(__INCLUDE_SYSTEM_SPACE_ISSET_ID)) { - result.setInclude_system_space(this.include_system_space); + if (__optional_isset.get(__ALL_SPACES_ISSET_ID)) { + result.setAll_spaces(this.all_spaces); } if (__optional_isset.get(__CREATE_TIME_ISSET_ID)) { result.setCreate_time(this.create_time); @@ -174,8 +174,8 @@ public static Builder builder() { public BackupMeta(BackupMeta other) { __isset_bit_vector.clear(); __isset_bit_vector.or(other.__isset_bit_vector); - if (other.isSetBackup_info()) { - this.backup_info = TBaseHelper.deepCopy(other.backup_info); + if (other.isSetSpace_backups()) { + this.space_backups = TBaseHelper.deepCopy(other.space_backups); } if (other.isSetMeta_files()) { this.meta_files = TBaseHelper.deepCopy(other.meta_files); @@ -184,7 +184,7 @@ public BackupMeta(BackupMeta other) { this.backup_name = TBaseHelper.deepCopy(other.backup_name); } this.full = TBaseHelper.deepCopy(other.full); - this.include_system_space = TBaseHelper.deepCopy(other.include_system_space); + this.all_spaces = TBaseHelper.deepCopy(other.all_spaces); this.create_time = TBaseHelper.deepCopy(other.create_time); } @@ -192,27 +192,27 @@ public BackupMeta deepCopy() { return new BackupMeta(this); } - public Map getBackup_info() { - return this.backup_info; + public Map getSpace_backups() { + return this.space_backups; } - public BackupMeta setBackup_info(Map backup_info) { - this.backup_info = backup_info; + public BackupMeta setSpace_backups(Map space_backups) { + this.space_backups = space_backups; return this; } - public void unsetBackup_info() { - this.backup_info = null; + public void unsetSpace_backups() { + this.space_backups = null; } - // Returns true if field backup_info is set (has been assigned a value) and false otherwise - public boolean isSetBackup_info() { - return this.backup_info != null; + // Returns true if field space_backups is set (has been assigned a value) and false otherwise + public boolean isSetSpace_backups() { + return this.space_backups != null; } - public void setBackup_infoIsSet(boolean __value) { + public void setSpace_backupsIsSet(boolean __value) { if (!__value) { - this.backup_info = null; + this.space_backups = null; } } @@ -287,27 +287,27 @@ public void setFullIsSet(boolean __value) { __isset_bit_vector.set(__FULL_ISSET_ID, __value); } - public boolean isInclude_system_space() { - return this.include_system_space; + public boolean isAll_spaces() { + return this.all_spaces; } - public BackupMeta setInclude_system_space(boolean include_system_space) { - this.include_system_space = include_system_space; - setInclude_system_spaceIsSet(true); + public BackupMeta setAll_spaces(boolean all_spaces) { + this.all_spaces = all_spaces; + setAll_spacesIsSet(true); return this; } - public void unsetInclude_system_space() { - __isset_bit_vector.clear(__INCLUDE_SYSTEM_SPACE_ISSET_ID); + public void unsetAll_spaces() { + __isset_bit_vector.clear(__ALL_SPACES_ISSET_ID); } - // Returns true if field include_system_space is set (has been assigned a value) and false otherwise - public boolean isSetInclude_system_space() { - return __isset_bit_vector.get(__INCLUDE_SYSTEM_SPACE_ISSET_ID); + // Returns true if field all_spaces is set (has been assigned a value) and false otherwise + public boolean isSetAll_spaces() { + return __isset_bit_vector.get(__ALL_SPACES_ISSET_ID); } - public void setInclude_system_spaceIsSet(boolean __value) { - __isset_bit_vector.set(__INCLUDE_SYSTEM_SPACE_ISSET_ID, __value); + public void setAll_spacesIsSet(boolean __value) { + __isset_bit_vector.set(__ALL_SPACES_ISSET_ID, __value); } public long getCreate_time() { @@ -336,11 +336,11 @@ public void setCreate_timeIsSet(boolean __value) { @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case BACKUP_INFO: + case SPACE_BACKUPS: if (__value == null) { - unsetBackup_info(); + unsetSpace_backups(); } else { - setBackup_info((Map)__value); + setSpace_backups((Map)__value); } break; @@ -368,11 +368,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case INCLUDE_SYSTEM_SPACE: + case ALL_SPACES: if (__value == null) { - unsetInclude_system_space(); + unsetAll_spaces(); } else { - setInclude_system_space((Boolean)__value); + setAll_spaces((Boolean)__value); } break; @@ -391,8 +391,8 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case BACKUP_INFO: - return getBackup_info(); + case SPACE_BACKUPS: + return getSpace_backups(); case META_FILES: return getMeta_files(); @@ -403,8 +403,8 @@ public Object getFieldValue(int fieldID) { case FULL: return new Boolean(isFull()); - case INCLUDE_SYSTEM_SPACE: - return new Boolean(isInclude_system_space()); + case ALL_SPACES: + return new Boolean(isAll_spaces()); case CREATE_TIME: return new Long(getCreate_time()); @@ -424,7 +424,7 @@ public boolean equals(Object _that) { return false; BackupMeta that = (BackupMeta)_that; - if (!TBaseHelper.equalsNobinary(this.isSetBackup_info(), that.isSetBackup_info(), this.backup_info, that.backup_info)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetSpace_backups(), that.isSetSpace_backups(), this.space_backups, that.space_backups)) { return false; } if (!TBaseHelper.equalsSlow(this.isSetMeta_files(), that.isSetMeta_files(), this.meta_files, that.meta_files)) { return false; } @@ -432,7 +432,7 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.full, that.full)) { return false; } - if (!TBaseHelper.equalsNobinary(this.include_system_space, that.include_system_space)) { return false; } + if (!TBaseHelper.equalsNobinary(this.all_spaces, that.all_spaces)) { return false; } if (!TBaseHelper.equalsNobinary(this.create_time, that.create_time)) { return false; } @@ -441,7 +441,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {backup_info, meta_files, backup_name, full, include_system_space, create_time}); + return Arrays.deepHashCode(new Object[] {space_backups, meta_files, backup_name, full, all_spaces, create_time}); } @Override @@ -456,11 +456,11 @@ public int compareTo(BackupMeta other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetBackup_info()).compareTo(other.isSetBackup_info()); + lastComparison = Boolean.valueOf(isSetSpace_backups()).compareTo(other.isSetSpace_backups()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(backup_info, other.backup_info); + lastComparison = TBaseHelper.compareTo(space_backups, other.space_backups); if (lastComparison != 0) { return lastComparison; } @@ -488,11 +488,11 @@ public int compareTo(BackupMeta other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetInclude_system_space()).compareTo(other.isSetInclude_system_space()); + lastComparison = Boolean.valueOf(isSetAll_spaces()).compareTo(other.isSetAll_spaces()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(include_system_space, other.include_system_space); + lastComparison = TBaseHelper.compareTo(all_spaces, other.all_spaces); if (lastComparison != 0) { return lastComparison; } @@ -518,21 +518,21 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case BACKUP_INFO: + case SPACE_BACKUPS: if (__field.type == TType.MAP) { { - TMap _map256 = iprot.readMapBegin(); - this.backup_info = new HashMap(Math.max(0, 2*_map256.size)); - for (int _i257 = 0; - (_map256.size < 0) ? iprot.peekMap() : (_i257 < _map256.size); - ++_i257) + TMap _map260 = iprot.readMapBegin(); + this.space_backups = new HashMap(Math.max(0, 2*_map260.size)); + for (int _i261 = 0; + (_map260.size < 0) ? iprot.peekMap() : (_i261 < _map260.size); + ++_i261) { - int _key258; - SpaceBackupInfo _val259; - _key258 = iprot.readI32(); - _val259 = new SpaceBackupInfo(); - _val259.read(iprot); - this.backup_info.put(_key258, _val259); + int _key262; + SpaceBackupInfo _val263; + _key262 = iprot.readI32(); + _val263 = new SpaceBackupInfo(); + _val263.read(iprot); + this.space_backups.put(_key262, _val263); } iprot.readMapEnd(); } @@ -543,15 +543,15 @@ public void read(TProtocol iprot) throws TException { case META_FILES: if (__field.type == TType.LIST) { { - TList _list260 = iprot.readListBegin(); - this.meta_files = new ArrayList(Math.max(0, _list260.size)); - for (int _i261 = 0; - (_list260.size < 0) ? iprot.peekList() : (_i261 < _list260.size); - ++_i261) + TList _list264 = iprot.readListBegin(); + this.meta_files = new ArrayList(Math.max(0, _list264.size)); + for (int _i265 = 0; + (_list264.size < 0) ? iprot.peekList() : (_i265 < _list264.size); + ++_i265) { - byte[] _elem262; - _elem262 = iprot.readBinary(); - this.meta_files.add(_elem262); + byte[] _elem266; + _elem266 = iprot.readBinary(); + this.meta_files.add(_elem266); } iprot.readListEnd(); } @@ -574,10 +574,10 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case INCLUDE_SYSTEM_SPACE: + case ALL_SPACES: if (__field.type == TType.BOOL) { - this.include_system_space = iprot.readBool(); - setInclude_system_spaceIsSet(true); + this.all_spaces = iprot.readBool(); + setAll_spacesIsSet(true); } else { TProtocolUtil.skip(iprot, __field.type); } @@ -607,13 +607,13 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - if (this.backup_info != null) { - oprot.writeFieldBegin(BACKUP_INFO_FIELD_DESC); + if (this.space_backups != null) { + oprot.writeFieldBegin(SPACE_BACKUPS_FIELD_DESC); { - oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.backup_info.size())); - for (Map.Entry _iter263 : this.backup_info.entrySet()) { - oprot.writeI32(_iter263.getKey()); - _iter263.getValue().write(oprot); + oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.space_backups.size())); + for (Map.Entry _iter267 : this.space_backups.entrySet()) { + oprot.writeI32(_iter267.getKey()); + _iter267.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -623,8 +623,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(META_FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.meta_files.size())); - for (byte[] _iter264 : this.meta_files) { - oprot.writeBinary(_iter264); + for (byte[] _iter268 : this.meta_files) { + oprot.writeBinary(_iter268); } oprot.writeListEnd(); } @@ -638,8 +638,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FULL_FIELD_DESC); oprot.writeBool(this.full); oprot.writeFieldEnd(); - oprot.writeFieldBegin(INCLUDE_SYSTEM_SPACE_FIELD_DESC); - oprot.writeBool(this.include_system_space); + oprot.writeFieldBegin(ALL_SPACES_FIELD_DESC); + oprot.writeBool(this.all_spaces); oprot.writeFieldEnd(); oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); oprot.writeI64(this.create_time); @@ -665,13 +665,13 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("backup_info"); + sb.append("space_backups"); sb.append(space); sb.append(":").append(space); - if (this.getBackup_info() == null) { + if (this.getSpace_backups() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getBackup_info(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getSpace_backups(), indent + 1, prettyPrint)); } first = false; if (!first) sb.append("," + newLine); @@ -710,10 +710,10 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("include_system_space"); + sb.append("all_spaces"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isInclude_system_space(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.isAll_spaces(), indent + 1, prettyPrint)); first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BalanceReq.java b/client/src/main/generated/com/vesoft/nebula/meta/BalanceReq.java deleted file mode 100644 index 7ceed11eb..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/BalanceReq.java +++ /dev/null @@ -1,644 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class BalanceReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("BalanceReq"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - private static final TField ID_FIELD_DESC = new TField("id", TType.I64, (short)2); - private static final TField HOST_DEL_FIELD_DESC = new TField("host_del", TType.LIST, (short)3); - private static final TField STOP_FIELD_DESC = new TField("stop", TType.BOOL, (short)4); - private static final TField RESET_FIELD_DESC = new TField("reset", TType.BOOL, (short)5); - - public int space_id; - public long id; - public List host_del; - public boolean stop; - public boolean reset; - public static final int SPACE_ID = 1; - public static final int ID = 2; - public static final int HOST_DEL = 3; - public static final int STOP = 4; - public static final int RESET = 5; - - // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private static final int __ID_ISSET_ID = 1; - private static final int __STOP_ISSET_ID = 2; - private static final int __RESET_ISSET_ID = 3; - private BitSet __isset_bit_vector = new BitSet(4); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(ID, new FieldMetaData("id", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(HOST_DEL, new FieldMetaData("host_del", TFieldRequirementType.OPTIONAL, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); - tmpMetaDataMap.put(STOP, new FieldMetaData("stop", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.BOOL))); - tmpMetaDataMap.put(RESET, new FieldMetaData("reset", TFieldRequirementType.OPTIONAL, - new FieldValueMetaData(TType.BOOL))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(BalanceReq.class, metaDataMap); - } - - public BalanceReq() { - } - - public BalanceReq( - int space_id, - long id, - List host_del, - boolean stop, - boolean reset) { - this(); - this.space_id = space_id; - setSpace_idIsSet(true); - this.id = id; - setIdIsSet(true); - this.host_del = host_del; - this.stop = stop; - setStopIsSet(true); - this.reset = reset; - setResetIsSet(true); - } - - public static class Builder { - private int space_id; - private long id; - private List host_del; - private boolean stop; - private boolean reset; - - BitSet __optional_isset = new BitSet(4); - - public Builder() { - } - - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); - return this; - } - - public Builder setId(final long id) { - this.id = id; - __optional_isset.set(__ID_ISSET_ID, true); - return this; - } - - public Builder setHost_del(final List host_del) { - this.host_del = host_del; - return this; - } - - public Builder setStop(final boolean stop) { - this.stop = stop; - __optional_isset.set(__STOP_ISSET_ID, true); - return this; - } - - public Builder setReset(final boolean reset) { - this.reset = reset; - __optional_isset.set(__RESET_ISSET_ID, true); - return this; - } - - public BalanceReq build() { - BalanceReq result = new BalanceReq(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } - if (__optional_isset.get(__ID_ISSET_ID)) { - result.setId(this.id); - } - result.setHost_del(this.host_del); - if (__optional_isset.get(__STOP_ISSET_ID)) { - result.setStop(this.stop); - } - if (__optional_isset.get(__RESET_ISSET_ID)) { - result.setReset(this.reset); - } - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public BalanceReq(BalanceReq other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); - this.id = TBaseHelper.deepCopy(other.id); - if (other.isSetHost_del()) { - this.host_del = TBaseHelper.deepCopy(other.host_del); - } - this.stop = TBaseHelper.deepCopy(other.stop); - this.reset = TBaseHelper.deepCopy(other.reset); - } - - public BalanceReq deepCopy() { - return new BalanceReq(this); - } - - public int getSpace_id() { - return this.space_id; - } - - public BalanceReq setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); - return this; - } - - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); - } - - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); - } - - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); - } - - public long getId() { - return this.id; - } - - public BalanceReq setId(long id) { - this.id = id; - setIdIsSet(true); - return this; - } - - public void unsetId() { - __isset_bit_vector.clear(__ID_ISSET_ID); - } - - // Returns true if field id is set (has been assigned a value) and false otherwise - public boolean isSetId() { - return __isset_bit_vector.get(__ID_ISSET_ID); - } - - public void setIdIsSet(boolean __value) { - __isset_bit_vector.set(__ID_ISSET_ID, __value); - } - - public List getHost_del() { - return this.host_del; - } - - public BalanceReq setHost_del(List host_del) { - this.host_del = host_del; - return this; - } - - public void unsetHost_del() { - this.host_del = null; - } - - // Returns true if field host_del is set (has been assigned a value) and false otherwise - public boolean isSetHost_del() { - return this.host_del != null; - } - - public void setHost_delIsSet(boolean __value) { - if (!__value) { - this.host_del = null; - } - } - - public boolean isStop() { - return this.stop; - } - - public BalanceReq setStop(boolean stop) { - this.stop = stop; - setStopIsSet(true); - return this; - } - - public void unsetStop() { - __isset_bit_vector.clear(__STOP_ISSET_ID); - } - - // Returns true if field stop is set (has been assigned a value) and false otherwise - public boolean isSetStop() { - return __isset_bit_vector.get(__STOP_ISSET_ID); - } - - public void setStopIsSet(boolean __value) { - __isset_bit_vector.set(__STOP_ISSET_ID, __value); - } - - public boolean isReset() { - return this.reset; - } - - public BalanceReq setReset(boolean reset) { - this.reset = reset; - setResetIsSet(true); - return this; - } - - public void unsetReset() { - __isset_bit_vector.clear(__RESET_ISSET_ID); - } - - // Returns true if field reset is set (has been assigned a value) and false otherwise - public boolean isSetReset() { - return __isset_bit_vector.get(__RESET_ISSET_ID); - } - - public void setResetIsSet(boolean __value) { - __isset_bit_vector.set(__RESET_ISSET_ID, __value); - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SPACE_ID: - if (__value == null) { - unsetSpace_id(); - } else { - setSpace_id((Integer)__value); - } - break; - - case ID: - if (__value == null) { - unsetId(); - } else { - setId((Long)__value); - } - break; - - case HOST_DEL: - if (__value == null) { - unsetHost_del(); - } else { - setHost_del((List)__value); - } - break; - - case STOP: - if (__value == null) { - unsetStop(); - } else { - setStop((Boolean)__value); - } - break; - - case RESET: - if (__value == null) { - unsetReset(); - } else { - setReset((Boolean)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); - - case ID: - return new Long(getId()); - - case HOST_DEL: - return getHost_del(); - - case STOP: - return new Boolean(isStop()); - - case RESET: - return new Boolean(isReset()); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof BalanceReq)) - return false; - BalanceReq that = (BalanceReq)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSpace_id(), that.isSetSpace_id(), this.space_id, that.space_id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetId(), that.isSetId(), this.id, that.id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetHost_del(), that.isSetHost_del(), this.host_del, that.host_del)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetStop(), that.isSetStop(), this.stop, that.stop)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetReset(), that.isSetReset(), this.reset, that.reset)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, id, host_del, stop, reset}); - } - - @Override - public int compareTo(BalanceReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetId()).compareTo(other.isSetId()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(id, other.id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetHost_del()).compareTo(other.isSetHost_del()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(host_del, other.host_del); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStop()).compareTo(other.isSetStop()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(stop, other.stop); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetReset()).compareTo(other.isSetReset()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(reset, other.reset); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ID: - if (__field.type == TType.I64) { - this.id = iprot.readI64(); - setIdIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case HOST_DEL: - if (__field.type == TType.LIST) { - { - TList _list174 = iprot.readListBegin(); - this.host_del = new ArrayList(Math.max(0, _list174.size)); - for (int _i175 = 0; - (_list174.size < 0) ? iprot.peekList() : (_i175 < _list174.size); - ++_i175) - { - com.vesoft.nebula.HostAddr _elem176; - _elem176 = new com.vesoft.nebula.HostAddr(); - _elem176.read(iprot); - this.host_del.add(_elem176); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case STOP: - if (__field.type == TType.BOOL) { - this.stop = iprot.readBool(); - setStopIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case RESET: - if (__field.type == TType.BOOL) { - this.reset = iprot.readBool(); - setResetIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (isSetSpace_id()) { - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); - } - if (isSetId()) { - oprot.writeFieldBegin(ID_FIELD_DESC); - oprot.writeI64(this.id); - oprot.writeFieldEnd(); - } - if (this.host_del != null) { - if (isSetHost_del()) { - oprot.writeFieldBegin(HOST_DEL_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.host_del.size())); - for (com.vesoft.nebula.HostAddr _iter177 : this.host_del) { - _iter177.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - } - if (isSetStop()) { - oprot.writeFieldBegin(STOP_FIELD_DESC); - oprot.writeBool(this.stop); - oprot.writeFieldEnd(); - } - if (isSetReset()) { - oprot.writeFieldBegin(RESET_FIELD_DESC); - oprot.writeBool(this.reset); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("BalanceReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - if (isSetSpace_id()) - { - sb.append(indentStr); - sb.append("space_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); - first = false; - } - if (isSetId()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getId(), indent + 1, prettyPrint)); - first = false; - } - if (isSetHost_del()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("host_del"); - sb.append(space); - sb.append(":").append(space); - if (this.getHost_del() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getHost_del(), indent + 1, prettyPrint)); - } - first = false; - } - if (isSetStop()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("stop"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isStop(), indent + 1, prettyPrint)); - first = false; - } - if (isSetReset()) - { - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("reset"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isReset(), indent + 1, prettyPrint)); - first = false; - } - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BalanceResp.java b/client/src/main/generated/com/vesoft/nebula/meta/BalanceResp.java deleted file mode 100644 index 18bb9c45b..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/BalanceResp.java +++ /dev/null @@ -1,564 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class BalanceResp implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("BalanceResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField ID_FIELD_DESC = new TField("id", TType.I64, (short)2); - private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)3); - private static final TField TASKS_FIELD_DESC = new TField("tasks", TType.LIST, (short)4); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public long id; - public com.vesoft.nebula.HostAddr leader; - public List tasks; - public static final int CODE = 1; - public static final int ID = 2; - public static final int LEADER = 3; - public static final int TASKS = 4; - - // isset id assignments - private static final int __ID_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(ID, new FieldMetaData("id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(TASKS, new FieldMetaData("tasks", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, BalanceTask.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(BalanceResp.class, metaDataMap); - } - - public BalanceResp() { - } - - public BalanceResp( - com.vesoft.nebula.ErrorCode code, - long id, - com.vesoft.nebula.HostAddr leader, - List tasks) { - this(); - this.code = code; - this.id = id; - setIdIsSet(true); - this.leader = leader; - this.tasks = tasks; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private long id; - private com.vesoft.nebula.HostAddr leader; - private List tasks; - - BitSet __optional_isset = new BitSet(1); - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setId(final long id) { - this.id = id; - __optional_isset.set(__ID_ISSET_ID, true); - return this; - } - - public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public Builder setTasks(final List tasks) { - this.tasks = tasks; - return this; - } - - public BalanceResp build() { - BalanceResp result = new BalanceResp(); - result.setCode(this.code); - if (__optional_isset.get(__ID_ISSET_ID)) { - result.setId(this.id); - } - result.setLeader(this.leader); - result.setTasks(this.tasks); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public BalanceResp(BalanceResp other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - this.id = TBaseHelper.deepCopy(other.id); - if (other.isSetLeader()) { - this.leader = TBaseHelper.deepCopy(other.leader); - } - if (other.isSetTasks()) { - this.tasks = TBaseHelper.deepCopy(other.tasks); - } - } - - public BalanceResp deepCopy() { - return new BalanceResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public BalanceResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public long getId() { - return this.id; - } - - public BalanceResp setId(long id) { - this.id = id; - setIdIsSet(true); - return this; - } - - public void unsetId() { - __isset_bit_vector.clear(__ID_ISSET_ID); - } - - // Returns true if field id is set (has been assigned a value) and false otherwise - public boolean isSetId() { - return __isset_bit_vector.get(__ID_ISSET_ID); - } - - public void setIdIsSet(boolean __value) { - __isset_bit_vector.set(__ID_ISSET_ID, __value); - } - - public com.vesoft.nebula.HostAddr getLeader() { - return this.leader; - } - - public BalanceResp setLeader(com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public void unsetLeader() { - this.leader = null; - } - - // Returns true if field leader is set (has been assigned a value) and false otherwise - public boolean isSetLeader() { - return this.leader != null; - } - - public void setLeaderIsSet(boolean __value) { - if (!__value) { - this.leader = null; - } - } - - public List getTasks() { - return this.tasks; - } - - public BalanceResp setTasks(List tasks) { - this.tasks = tasks; - return this; - } - - public void unsetTasks() { - this.tasks = null; - } - - // Returns true if field tasks is set (has been assigned a value) and false otherwise - public boolean isSetTasks() { - return this.tasks != null; - } - - public void setTasksIsSet(boolean __value) { - if (!__value) { - this.tasks = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case ID: - if (__value == null) { - unsetId(); - } else { - setId((Long)__value); - } - break; - - case LEADER: - if (__value == null) { - unsetLeader(); - } else { - setLeader((com.vesoft.nebula.HostAddr)__value); - } - break; - - case TASKS: - if (__value == null) { - unsetTasks(); - } else { - setTasks((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case ID: - return new Long(getId()); - - case LEADER: - return getLeader(); - - case TASKS: - return getTasks(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof BalanceResp)) - return false; - BalanceResp that = (BalanceResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.id, that.id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetTasks(), that.isSetTasks(), this.tasks, that.tasks)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, id, leader, tasks}); - } - - @Override - public int compareTo(BalanceResp other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetCode()).compareTo(other.isSetCode()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(code, other.code); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetId()).compareTo(other.isSetId()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(id, other.id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetLeader()).compareTo(other.isSetLeader()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(leader, other.leader); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetTasks()).compareTo(other.isSetTasks()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(tasks, other.tasks); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ID: - if (__field.type == TType.I64) { - this.id = iprot.readI64(); - setIdIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LEADER: - if (__field.type == TType.STRUCT) { - this.leader = new com.vesoft.nebula.HostAddr(); - this.leader.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case TASKS: - if (__field.type == TType.LIST) { - { - TList _list178 = iprot.readListBegin(); - this.tasks = new ArrayList(Math.max(0, _list178.size)); - for (int _i179 = 0; - (_list178.size < 0) ? iprot.peekList() : (_i179 < _list178.size); - ++_i179) - { - BalanceTask _elem180; - _elem180 = new BalanceTask(); - _elem180.read(iprot); - this.tasks.add(_elem180); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(ID_FIELD_DESC); - oprot.writeI64(this.id); - oprot.writeFieldEnd(); - if (this.leader != null) { - oprot.writeFieldBegin(LEADER_FIELD_DESC); - this.leader.write(oprot); - oprot.writeFieldEnd(); - } - if (this.tasks != null) { - oprot.writeFieldBegin(TASKS_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.tasks.size())); - for (BalanceTask _iter181 : this.tasks) { - _iter181.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("BalanceResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getId(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("leader"); - sb.append(space); - sb.append(":").append(space); - if (this.getLeader() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("tasks"); - sb.append(space); - sb.append(":").append(space); - if (this.getTasks() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getTasks(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java index 7df101c4d..668128efc 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateBackupReq.java @@ -198,15 +198,15 @@ public void read(TProtocol iprot) throws TException { case SPACES: if (__field.type == TType.LIST) { { - TList _list265 = iprot.readListBegin(); - this.spaces = new ArrayList(Math.max(0, _list265.size)); - for (int _i266 = 0; - (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); - ++_i266) + TList _list269 = iprot.readListBegin(); + this.spaces = new ArrayList(Math.max(0, _list269.size)); + for (int _i270 = 0; + (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); + ++_i270) { - byte[] _elem267; - _elem267 = iprot.readBinary(); - this.spaces.add(_elem267); + byte[] _elem271; + _elem271 = iprot.readBinary(); + this.spaces.add(_elem271); } iprot.readListEnd(); } @@ -236,8 +236,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SPACES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.spaces.size())); - for (byte[] _iter268 : this.spaces) { - oprot.writeBinary(_iter268); + for (byte[] _iter272 : this.spaces) { + oprot.writeBinary(_iter272); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java index 3c72e04db..46711d28c 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateEdgeIndexReq.java @@ -32,6 +32,7 @@ public class CreateEdgeIndexReq implements TBase, java.io.Serializable, Cloneabl private static final TField FIELDS_FIELD_DESC = new TField("fields", TType.LIST, (short)4); private static final TField IF_NOT_EXISTS_FIELD_DESC = new TField("if_not_exists", TType.BOOL, (short)5); private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)6); + private static final TField INDEX_PARAMS_FIELD_DESC = new TField("index_params", TType.STRUCT, (short)7); public int space_id; public byte[] index_name; @@ -39,12 +40,14 @@ public class CreateEdgeIndexReq implements TBase, java.io.Serializable, Cloneabl public List fields; public boolean if_not_exists; public byte[] comment; + public IndexParams index_params; public static final int SPACE_ID = 1; public static final int INDEX_NAME = 2; public static final int EDGE_NAME = 3; public static final int FIELDS = 4; public static final int IF_NOT_EXISTS = 5; public static final int COMMENT = 6; + public static final int INDEX_PARAMS = 7; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; @@ -68,6 +71,8 @@ public class CreateEdgeIndexReq implements TBase, java.io.Serializable, Cloneabl new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(INDEX_PARAMS, new FieldMetaData("index_params", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, IndexParams.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -100,7 +105,8 @@ public CreateEdgeIndexReq( byte[] edge_name, List fields, boolean if_not_exists, - byte[] comment) { + byte[] comment, + IndexParams index_params) { this(); this.space_id = space_id; setSpace_idIsSet(true); @@ -110,6 +116,7 @@ public CreateEdgeIndexReq( this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); this.comment = comment; + this.index_params = index_params; } public static class Builder { @@ -119,6 +126,7 @@ public static class Builder { private List fields; private boolean if_not_exists; private byte[] comment; + private IndexParams index_params; BitSet __optional_isset = new BitSet(2); @@ -157,6 +165,11 @@ public Builder setComment(final byte[] comment) { return this; } + public Builder setIndex_params(final IndexParams index_params) { + this.index_params = index_params; + return this; + } + public CreateEdgeIndexReq build() { CreateEdgeIndexReq result = new CreateEdgeIndexReq(); if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { @@ -169,6 +182,7 @@ public CreateEdgeIndexReq build() { result.setIf_not_exists(this.if_not_exists); } result.setComment(this.comment); + result.setIndex_params(this.index_params); return result; } } @@ -197,6 +211,9 @@ public CreateEdgeIndexReq(CreateEdgeIndexReq other) { if (other.isSetComment()) { this.comment = TBaseHelper.deepCopy(other.comment); } + if (other.isSetIndex_params()) { + this.index_params = TBaseHelper.deepCopy(other.index_params); + } } public CreateEdgeIndexReq deepCopy() { @@ -345,6 +362,30 @@ public void setCommentIsSet(boolean __value) { } } + public IndexParams getIndex_params() { + return this.index_params; + } + + public CreateEdgeIndexReq setIndex_params(IndexParams index_params) { + this.index_params = index_params; + return this; + } + + public void unsetIndex_params() { + this.index_params = null; + } + + // Returns true if field index_params is set (has been assigned a value) and false otherwise + public boolean isSetIndex_params() { + return this.index_params != null; + } + + public void setIndex_paramsIsSet(boolean __value) { + if (!__value) { + this.index_params = null; + } + } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { @@ -396,6 +437,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case INDEX_PARAMS: + if (__value == null) { + unsetIndex_params(); + } else { + setIndex_params((IndexParams)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -421,6 +470,9 @@ public Object getFieldValue(int fieldID) { case COMMENT: return getComment(); + case INDEX_PARAMS: + return getIndex_params(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -448,12 +500,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetComment(), that.isSetComment(), this.comment, that.comment)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetIndex_params(), that.isSetIndex_params(), this.index_params, that.index_params)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, index_name, edge_name, fields, if_not_exists, comment}); + return Arrays.deepHashCode(new Object[] {space_id, index_name, edge_name, fields, if_not_exists, comment, index_params}); } @Override @@ -516,6 +570,14 @@ public int compareTo(CreateEdgeIndexReq other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetIndex_params()).compareTo(other.isSetIndex_params()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(index_params, other.index_params); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -555,16 +617,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list183 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list183.size)); - for (int _i184 = 0; - (_list183.size < 0) ? iprot.peekList() : (_i184 < _list183.size); - ++_i184) + TList _list187 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list187.size)); + for (int _i188 = 0; + (_list187.size < 0) ? iprot.peekList() : (_i188 < _list187.size); + ++_i188) { - IndexFieldDef _elem185; - _elem185 = new IndexFieldDef(); - _elem185.read(iprot); - this.fields.add(_elem185); + IndexFieldDef _elem189; + _elem189 = new IndexFieldDef(); + _elem189.read(iprot); + this.fields.add(_elem189); } iprot.readListEnd(); } @@ -587,6 +649,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case INDEX_PARAMS: + if (__field.type == TType.STRUCT) { + this.index_params = new IndexParams(); + this.index_params.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -621,8 +691,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter186 : this.fields) { - _iter186.write(oprot); + for (IndexFieldDef _iter190 : this.fields) { + _iter190.write(oprot); } oprot.writeListEnd(); } @@ -638,6 +708,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } } + if (this.index_params != null) { + if (isSetIndex_params()) { + oprot.writeFieldBegin(INDEX_PARAMS_FIELD_DESC); + this.index_params.write(oprot); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -733,6 +810,20 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } + if (isSetIndex_params()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("index_params"); + sb.append(space); + sb.append(":").append(space); + if (this.getIndex_params() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getIndex_params(), indent + 1, prettyPrint)); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java index d60dd1465..832458cfe 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/CreateTagIndexReq.java @@ -32,6 +32,7 @@ public class CreateTagIndexReq implements TBase, java.io.Serializable, Cloneable private static final TField FIELDS_FIELD_DESC = new TField("fields", TType.LIST, (short)4); private static final TField IF_NOT_EXISTS_FIELD_DESC = new TField("if_not_exists", TType.BOOL, (short)5); private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)6); + private static final TField INDEX_PARAMS_FIELD_DESC = new TField("index_params", TType.STRUCT, (short)7); public int space_id; public byte[] index_name; @@ -39,12 +40,14 @@ public class CreateTagIndexReq implements TBase, java.io.Serializable, Cloneable public List fields; public boolean if_not_exists; public byte[] comment; + public IndexParams index_params; public static final int SPACE_ID = 1; public static final int INDEX_NAME = 2; public static final int TAG_NAME = 3; public static final int FIELDS = 4; public static final int IF_NOT_EXISTS = 5; public static final int COMMENT = 6; + public static final int INDEX_PARAMS = 7; // isset id assignments private static final int __SPACE_ID_ISSET_ID = 0; @@ -68,6 +71,8 @@ public class CreateTagIndexReq implements TBase, java.io.Serializable, Cloneable new FieldValueMetaData(TType.BOOL))); tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(INDEX_PARAMS, new FieldMetaData("index_params", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, IndexParams.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -100,7 +105,8 @@ public CreateTagIndexReq( byte[] tag_name, List fields, boolean if_not_exists, - byte[] comment) { + byte[] comment, + IndexParams index_params) { this(); this.space_id = space_id; setSpace_idIsSet(true); @@ -110,6 +116,7 @@ public CreateTagIndexReq( this.if_not_exists = if_not_exists; setIf_not_existsIsSet(true); this.comment = comment; + this.index_params = index_params; } public static class Builder { @@ -119,6 +126,7 @@ public static class Builder { private List fields; private boolean if_not_exists; private byte[] comment; + private IndexParams index_params; BitSet __optional_isset = new BitSet(2); @@ -157,6 +165,11 @@ public Builder setComment(final byte[] comment) { return this; } + public Builder setIndex_params(final IndexParams index_params) { + this.index_params = index_params; + return this; + } + public CreateTagIndexReq build() { CreateTagIndexReq result = new CreateTagIndexReq(); if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { @@ -169,6 +182,7 @@ public CreateTagIndexReq build() { result.setIf_not_exists(this.if_not_exists); } result.setComment(this.comment); + result.setIndex_params(this.index_params); return result; } } @@ -197,6 +211,9 @@ public CreateTagIndexReq(CreateTagIndexReq other) { if (other.isSetComment()) { this.comment = TBaseHelper.deepCopy(other.comment); } + if (other.isSetIndex_params()) { + this.index_params = TBaseHelper.deepCopy(other.index_params); + } } public CreateTagIndexReq deepCopy() { @@ -345,6 +362,30 @@ public void setCommentIsSet(boolean __value) { } } + public IndexParams getIndex_params() { + return this.index_params; + } + + public CreateTagIndexReq setIndex_params(IndexParams index_params) { + this.index_params = index_params; + return this; + } + + public void unsetIndex_params() { + this.index_params = null; + } + + // Returns true if field index_params is set (has been assigned a value) and false otherwise + public boolean isSetIndex_params() { + return this.index_params != null; + } + + public void setIndex_paramsIsSet(boolean __value) { + if (!__value) { + this.index_params = null; + } + } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { @@ -396,6 +437,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case INDEX_PARAMS: + if (__value == null) { + unsetIndex_params(); + } else { + setIndex_params((IndexParams)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -421,6 +470,9 @@ public Object getFieldValue(int fieldID) { case COMMENT: return getComment(); + case INDEX_PARAMS: + return getIndex_params(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -448,12 +500,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetComment(), that.isSetComment(), this.comment, that.comment)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetIndex_params(), that.isSetIndex_params(), this.index_params, that.index_params)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, index_name, tag_name, fields, if_not_exists, comment}); + return Arrays.deepHashCode(new Object[] {space_id, index_name, tag_name, fields, if_not_exists, comment, index_params}); } @Override @@ -516,6 +570,14 @@ public int compareTo(CreateTagIndexReq other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetIndex_params()).compareTo(other.isSetIndex_params()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(index_params, other.index_params); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -555,16 +617,16 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list175 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list175.size)); - for (int _i176 = 0; - (_list175.size < 0) ? iprot.peekList() : (_i176 < _list175.size); - ++_i176) + TList _list179 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list179.size)); + for (int _i180 = 0; + (_list179.size < 0) ? iprot.peekList() : (_i180 < _list179.size); + ++_i180) { - IndexFieldDef _elem177; - _elem177 = new IndexFieldDef(); - _elem177.read(iprot); - this.fields.add(_elem177); + IndexFieldDef _elem181; + _elem181 = new IndexFieldDef(); + _elem181.read(iprot); + this.fields.add(_elem181); } iprot.readListEnd(); } @@ -587,6 +649,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case INDEX_PARAMS: + if (__field.type == TType.STRUCT) { + this.index_params = new IndexParams(); + this.index_params.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -621,8 +691,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.fields.size())); - for (IndexFieldDef _iter178 : this.fields) { - _iter178.write(oprot); + for (IndexFieldDef _iter182 : this.fields) { + _iter182.write(oprot); } oprot.writeListEnd(); } @@ -638,6 +708,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } } + if (this.index_params != null) { + if (isSetIndex_params()) { + oprot.writeFieldBegin(INDEX_PARAMS_FIELD_DESC); + this.index_params.write(oprot); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -733,6 +810,20 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } + if (isSetIndex_params()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("index_params"); + sb.append(space); + sb.append(":").append(space); + if (this.getIndex_params() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getIndex_params(), indent + 1, prettyPrint)); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/DropGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/DropGroupReq.java deleted file mode 100644 index 19036ccb1..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/DropGroupReq.java +++ /dev/null @@ -1,270 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class DropGroupReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("DropGroupReq"); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)1); - - public byte[] group_name; - public static final int GROUP_NAME = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(DropGroupReq.class, metaDataMap); - } - - public DropGroupReq() { - } - - public DropGroupReq( - byte[] group_name) { - this(); - this.group_name = group_name; - } - - public static class Builder { - private byte[] group_name; - - public Builder() { - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public DropGroupReq build() { - DropGroupReq result = new DropGroupReq(); - result.setGroup_name(this.group_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public DropGroupReq(DropGroupReq other) { - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - } - - public DropGroupReq deepCopy() { - return new DropGroupReq(this); - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public DropGroupReq setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case GROUP_NAME: - return getGroup_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof DropGroupReq)) - return false; - DropGroupReq that = (DropGroupReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {group_name}); - } - - @Override - public int compareTo(DropGroupReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("DropGroupReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/DropHostFromZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/DropHostFromZoneReq.java deleted file mode 100644 index 87e390596..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/DropHostFromZoneReq.java +++ /dev/null @@ -1,356 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class DropHostFromZoneReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("DropHostFromZoneReq"); - private static final TField NODE_FIELD_DESC = new TField("node", TType.STRUCT, (short)1); - private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)2); - - public com.vesoft.nebula.HostAddr node; - public byte[] zone_name; - public static final int NODE = 1; - public static final int ZONE_NAME = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(NODE, new FieldMetaData("node", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(DropHostFromZoneReq.class, metaDataMap); - } - - public DropHostFromZoneReq() { - } - - public DropHostFromZoneReq( - com.vesoft.nebula.HostAddr node, - byte[] zone_name) { - this(); - this.node = node; - this.zone_name = zone_name; - } - - public static class Builder { - private com.vesoft.nebula.HostAddr node; - private byte[] zone_name; - - public Builder() { - } - - public Builder setNode(final com.vesoft.nebula.HostAddr node) { - this.node = node; - return this; - } - - public Builder setZone_name(final byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public DropHostFromZoneReq build() { - DropHostFromZoneReq result = new DropHostFromZoneReq(); - result.setNode(this.node); - result.setZone_name(this.zone_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public DropHostFromZoneReq(DropHostFromZoneReq other) { - if (other.isSetNode()) { - this.node = TBaseHelper.deepCopy(other.node); - } - if (other.isSetZone_name()) { - this.zone_name = TBaseHelper.deepCopy(other.zone_name); - } - } - - public DropHostFromZoneReq deepCopy() { - return new DropHostFromZoneReq(this); - } - - public com.vesoft.nebula.HostAddr getNode() { - return this.node; - } - - public DropHostFromZoneReq setNode(com.vesoft.nebula.HostAddr node) { - this.node = node; - return this; - } - - public void unsetNode() { - this.node = null; - } - - // Returns true if field node is set (has been assigned a value) and false otherwise - public boolean isSetNode() { - return this.node != null; - } - - public void setNodeIsSet(boolean __value) { - if (!__value) { - this.node = null; - } - } - - public byte[] getZone_name() { - return this.zone_name; - } - - public DropHostFromZoneReq setZone_name(byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public void unsetZone_name() { - this.zone_name = null; - } - - // Returns true if field zone_name is set (has been assigned a value) and false otherwise - public boolean isSetZone_name() { - return this.zone_name != null; - } - - public void setZone_nameIsSet(boolean __value) { - if (!__value) { - this.zone_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case NODE: - if (__value == null) { - unsetNode(); - } else { - setNode((com.vesoft.nebula.HostAddr)__value); - } - break; - - case ZONE_NAME: - if (__value == null) { - unsetZone_name(); - } else { - setZone_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case NODE: - return getNode(); - - case ZONE_NAME: - return getZone_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof DropHostFromZoneReq)) - return false; - DropHostFromZoneReq that = (DropHostFromZoneReq)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetNode(), that.isSetNode(), this.node, that.node)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {node, zone_name}); - } - - @Override - public int compareTo(DropHostFromZoneReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetNode()).compareTo(other.isSetNode()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(node, other.node); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case NODE: - if (__field.type == TType.STRUCT) { - this.node = new com.vesoft.nebula.HostAddr(); - this.node.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ZONE_NAME: - if (__field.type == TType.STRING) { - this.zone_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.node != null) { - oprot.writeFieldBegin(NODE_FIELD_DESC); - this.node.write(oprot); - oprot.writeFieldEnd(); - } - if (this.zone_name != null) { - oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); - oprot.writeBinary(this.zone_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("DropHostFromZoneReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("node"); - sb.append(space); - sb.append(":").append(space); - if (this.getNode() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getNode(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("zone_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_name() == null) { - sb.append("null"); - } else { - int __zone_name_size = Math.min(this.getZone_name().length, 128); - for (int i = 0; i < __zone_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); - } - if (this.getZone_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/DropZoneFromGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/DropZoneFromGroupReq.java deleted file mode 100644 index 0f12c436d..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/DropZoneFromGroupReq.java +++ /dev/null @@ -1,360 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class DropZoneFromGroupReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("DropZoneFromGroupReq"); - private static final TField ZONE_NAME_FIELD_DESC = new TField("zone_name", TType.STRING, (short)1); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)2); - - public byte[] zone_name; - public byte[] group_name; - public static final int ZONE_NAME = 1; - public static final int GROUP_NAME = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(ZONE_NAME, new FieldMetaData("zone_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(DropZoneFromGroupReq.class, metaDataMap); - } - - public DropZoneFromGroupReq() { - } - - public DropZoneFromGroupReq( - byte[] zone_name, - byte[] group_name) { - this(); - this.zone_name = zone_name; - this.group_name = group_name; - } - - public static class Builder { - private byte[] zone_name; - private byte[] group_name; - - public Builder() { - } - - public Builder setZone_name(final byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public DropZoneFromGroupReq build() { - DropZoneFromGroupReq result = new DropZoneFromGroupReq(); - result.setZone_name(this.zone_name); - result.setGroup_name(this.group_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public DropZoneFromGroupReq(DropZoneFromGroupReq other) { - if (other.isSetZone_name()) { - this.zone_name = TBaseHelper.deepCopy(other.zone_name); - } - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - } - - public DropZoneFromGroupReq deepCopy() { - return new DropZoneFromGroupReq(this); - } - - public byte[] getZone_name() { - return this.zone_name; - } - - public DropZoneFromGroupReq setZone_name(byte[] zone_name) { - this.zone_name = zone_name; - return this; - } - - public void unsetZone_name() { - this.zone_name = null; - } - - // Returns true if field zone_name is set (has been assigned a value) and false otherwise - public boolean isSetZone_name() { - return this.zone_name != null; - } - - public void setZone_nameIsSet(boolean __value) { - if (!__value) { - this.zone_name = null; - } - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public DropZoneFromGroupReq setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case ZONE_NAME: - if (__value == null) { - unsetZone_name(); - } else { - setZone_name((byte[])__value); - } - break; - - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case ZONE_NAME: - return getZone_name(); - - case GROUP_NAME: - return getGroup_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof DropZoneFromGroupReq)) - return false; - DropZoneFromGroupReq that = (DropZoneFromGroupReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetZone_name(), that.isSetZone_name(), this.zone_name, that.zone_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {zone_name, group_name}); - } - - @Override - public int compareTo(DropZoneFromGroupReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetZone_name()).compareTo(other.isSetZone_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_name, other.zone_name); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case ZONE_NAME: - if (__field.type == TType.STRING) { - this.zone_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.zone_name != null) { - oprot.writeFieldBegin(ZONE_NAME_FIELD_DESC); - oprot.writeBinary(this.zone_name); - oprot.writeFieldEnd(); - } - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("DropZoneFromGroupReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("zone_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_name() == null) { - sb.append("null"); - } else { - int __zone_name_size = Math.min(this.getZone_name().length, 128); - for (int i = 0; i < __zone_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getZone_name()[i]).length() > 1 ? Integer.toHexString(this.getZone_name()[i]).substring(Integer.toHexString(this.getZone_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getZone_name()[i]).toUpperCase()); - } - if (this.getZone_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java index ebdf0ec4c..813795b67 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/FTIndex.java @@ -345,15 +345,15 @@ public void read(TProtocol iprot) throws TException { case FIELDS: if (__field.type == TType.LIST) { { - TList _list285 = iprot.readListBegin(); - this.fields = new ArrayList(Math.max(0, _list285.size)); - for (int _i286 = 0; - (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); - ++_i286) + TList _list289 = iprot.readListBegin(); + this.fields = new ArrayList(Math.max(0, _list289.size)); + for (int _i290 = 0; + (_list289.size < 0) ? iprot.peekList() : (_i290 < _list289.size); + ++_i290) { - byte[] _elem287; - _elem287 = iprot.readBinary(); - this.fields.add(_elem287); + byte[] _elem291; + _elem291 = iprot.readBinary(); + this.fields.add(_elem291); } iprot.readListEnd(); } @@ -390,8 +390,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FIELDS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.fields.size())); - for (byte[] _iter288 : this.fields) { - oprot.writeBinary(_iter288); + for (byte[] _iter292 : this.fields) { + oprot.writeBinary(_iter292); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java index b685c7e55..130547651 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetConfigResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list204 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list204.size)); - for (int _i205 = 0; - (_list204.size < 0) ? iprot.peekList() : (_i205 < _list204.size); - ++_i205) + TList _list208 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list208.size)); + for (int _i209 = 0; + (_list208.size < 0) ? iprot.peekList() : (_i209 < _list208.size); + ++_i209) { - ConfigItem _elem206; - _elem206 = new ConfigItem(); - _elem206.read(iprot); - this.items.add(_elem206); + ConfigItem _elem210; + _elem210 = new ConfigItem(); + _elem210.read(iprot); + this.items.add(_elem210); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter207 : this.items) { - _iter207.write(oprot); + for (ConfigItem _iter211 : this.items) { + _iter211.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupReq.java b/client/src/main/generated/com/vesoft/nebula/meta/GetGroupReq.java deleted file mode 100644 index 557b7838c..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupReq.java +++ /dev/null @@ -1,270 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetGroupReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetGroupReq"); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)1); - - public byte[] group_name; - public static final int GROUP_NAME = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetGroupReq.class, metaDataMap); - } - - public GetGroupReq() { - } - - public GetGroupReq( - byte[] group_name) { - this(); - this.group_name = group_name; - } - - public static class Builder { - private byte[] group_name; - - public Builder() { - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public GetGroupReq build() { - GetGroupReq result = new GetGroupReq(); - result.setGroup_name(this.group_name); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetGroupReq(GetGroupReq other) { - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - } - - public GetGroupReq deepCopy() { - return new GetGroupReq(this); - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public GetGroupReq setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case GROUP_NAME: - return getGroup_name(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetGroupReq)) - return false; - GetGroupReq that = (GetGroupReq)_that; - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {group_name}); - } - - @Override - public int compareTo(GetGroupReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetGroupReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java deleted file mode 100644 index 83be4c9b1..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetGroupResp.java +++ /dev/null @@ -1,476 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetGroupResp implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetGroupResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField ZONE_NAMES_FIELD_DESC = new TField("zone_names", TType.LIST, (short)3); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public com.vesoft.nebula.HostAddr leader; - public List zone_names; - public static final int CODE = 1; - public static final int LEADER = 2; - public static final int ZONE_NAMES = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(ZONE_NAMES, new FieldMetaData("zone_names", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new FieldValueMetaData(TType.STRING)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetGroupResp.class, metaDataMap); - } - - public GetGroupResp() { - } - - public GetGroupResp( - com.vesoft.nebula.ErrorCode code, - com.vesoft.nebula.HostAddr leader, - List zone_names) { - this(); - this.code = code; - this.leader = leader; - this.zone_names = zone_names; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private com.vesoft.nebula.HostAddr leader; - private List zone_names; - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public Builder setZone_names(final List zone_names) { - this.zone_names = zone_names; - return this; - } - - public GetGroupResp build() { - GetGroupResp result = new GetGroupResp(); - result.setCode(this.code); - result.setLeader(this.leader); - result.setZone_names(this.zone_names); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetGroupResp(GetGroupResp other) { - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - if (other.isSetLeader()) { - this.leader = TBaseHelper.deepCopy(other.leader); - } - if (other.isSetZone_names()) { - this.zone_names = TBaseHelper.deepCopy(other.zone_names); - } - } - - public GetGroupResp deepCopy() { - return new GetGroupResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public GetGroupResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public com.vesoft.nebula.HostAddr getLeader() { - return this.leader; - } - - public GetGroupResp setLeader(com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public void unsetLeader() { - this.leader = null; - } - - // Returns true if field leader is set (has been assigned a value) and false otherwise - public boolean isSetLeader() { - return this.leader != null; - } - - public void setLeaderIsSet(boolean __value) { - if (!__value) { - this.leader = null; - } - } - - public List getZone_names() { - return this.zone_names; - } - - public GetGroupResp setZone_names(List zone_names) { - this.zone_names = zone_names; - return this; - } - - public void unsetZone_names() { - this.zone_names = null; - } - - // Returns true if field zone_names is set (has been assigned a value) and false otherwise - public boolean isSetZone_names() { - return this.zone_names != null; - } - - public void setZone_namesIsSet(boolean __value) { - if (!__value) { - this.zone_names = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case LEADER: - if (__value == null) { - unsetLeader(); - } else { - setLeader((com.vesoft.nebula.HostAddr)__value); - } - break; - - case ZONE_NAMES: - if (__value == null) { - unsetZone_names(); - } else { - setZone_names((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case LEADER: - return getLeader(); - - case ZONE_NAMES: - return getZone_names(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetGroupResp)) - return false; - GetGroupResp that = (GetGroupResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetZone_names(), that.isSetZone_names(), this.zone_names, that.zone_names)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, zone_names}); - } - - @Override - public int compareTo(GetGroupResp other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetCode()).compareTo(other.isSetCode()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(code, other.code); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetLeader()).compareTo(other.isSetLeader()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(leader, other.leader); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetZone_names()).compareTo(other.isSetZone_names()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_names, other.zone_names); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LEADER: - if (__field.type == TType.STRUCT) { - this.leader = new com.vesoft.nebula.HostAddr(); - this.leader.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ZONE_NAMES: - if (__field.type == TType.LIST) { - { - TList _list214 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list214.size)); - for (int _i215 = 0; - (_list214.size < 0) ? iprot.peekList() : (_i215 < _list214.size); - ++_i215) - { - byte[] _elem216; - _elem216 = iprot.readBinary(); - this.zone_names.add(_elem216); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - if (this.leader != null) { - oprot.writeFieldBegin(LEADER_FIELD_DESC); - this.leader.write(oprot); - oprot.writeFieldEnd(); - } - if (this.zone_names != null) { - oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter217 : this.zone_names) { - oprot.writeBinary(_iter217); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetGroupResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("leader"); - sb.append(space); - sb.append(":").append(space); - if (this.getLeader() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("zone_names"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_names() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getZone_names(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java deleted file mode 100644 index 9070aac9b..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisReq.java +++ /dev/null @@ -1,267 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetStatisReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetStatisReq"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - - public int space_id; - public static final int SPACE_ID = 1; - - // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetStatisReq.class, metaDataMap); - } - - public GetStatisReq() { - } - - public GetStatisReq( - int space_id) { - this(); - this.space_id = space_id; - setSpace_idIsSet(true); - } - - public static class Builder { - private int space_id; - - BitSet __optional_isset = new BitSet(1); - - public Builder() { - } - - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); - return this; - } - - public GetStatisReq build() { - GetStatisReq result = new GetStatisReq(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetStatisReq(GetStatisReq other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); - } - - public GetStatisReq deepCopy() { - return new GetStatisReq(this); - } - - public int getSpace_id() { - return this.space_id; - } - - public GetStatisReq setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); - return this; - } - - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); - } - - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); - } - - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SPACE_ID: - if (__value == null) { - unsetSpace_id(); - } else { - setSpace_id((Integer)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetStatisReq)) - return false; - GetStatisReq that = (GetStatisReq)_that; - - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id}); - } - - @Override - public int compareTo(GetStatisReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetStatisReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("space_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java deleted file mode 100644 index 4a018a286..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetStatisResp.java +++ /dev/null @@ -1,457 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetStatisResp implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetStatisResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField STATIS_FIELD_DESC = new TField("statis", TType.STRUCT, (short)3); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public com.vesoft.nebula.HostAddr leader; - public StatisItem statis; - public static final int CODE = 1; - public static final int LEADER = 2; - public static final int STATIS = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(STATIS, new FieldMetaData("statis", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, StatisItem.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetStatisResp.class, metaDataMap); - } - - public GetStatisResp() { - } - - public GetStatisResp( - com.vesoft.nebula.ErrorCode code, - com.vesoft.nebula.HostAddr leader, - StatisItem statis) { - this(); - this.code = code; - this.leader = leader; - this.statis = statis; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private com.vesoft.nebula.HostAddr leader; - private StatisItem statis; - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public Builder setStatis(final StatisItem statis) { - this.statis = statis; - return this; - } - - public GetStatisResp build() { - GetStatisResp result = new GetStatisResp(); - result.setCode(this.code); - result.setLeader(this.leader); - result.setStatis(this.statis); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetStatisResp(GetStatisResp other) { - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - if (other.isSetLeader()) { - this.leader = TBaseHelper.deepCopy(other.leader); - } - if (other.isSetStatis()) { - this.statis = TBaseHelper.deepCopy(other.statis); - } - } - - public GetStatisResp deepCopy() { - return new GetStatisResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public GetStatisResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public com.vesoft.nebula.HostAddr getLeader() { - return this.leader; - } - - public GetStatisResp setLeader(com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public void unsetLeader() { - this.leader = null; - } - - // Returns true if field leader is set (has been assigned a value) and false otherwise - public boolean isSetLeader() { - return this.leader != null; - } - - public void setLeaderIsSet(boolean __value) { - if (!__value) { - this.leader = null; - } - } - - public StatisItem getStatis() { - return this.statis; - } - - public GetStatisResp setStatis(StatisItem statis) { - this.statis = statis; - return this; - } - - public void unsetStatis() { - this.statis = null; - } - - // Returns true if field statis is set (has been assigned a value) and false otherwise - public boolean isSetStatis() { - return this.statis != null; - } - - public void setStatisIsSet(boolean __value) { - if (!__value) { - this.statis = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case LEADER: - if (__value == null) { - unsetLeader(); - } else { - setLeader((com.vesoft.nebula.HostAddr)__value); - } - break; - - case STATIS: - if (__value == null) { - unsetStatis(); - } else { - setStatis((StatisItem)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case LEADER: - return getLeader(); - - case STATIS: - return getStatis(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetStatisResp)) - return false; - GetStatisResp that = (GetStatisResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetStatis(), that.isSetStatis(), this.statis, that.statis)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, statis}); - } - - @Override - public int compareTo(GetStatisResp other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetCode()).compareTo(other.isSetCode()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(code, other.code); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetLeader()).compareTo(other.isSetLeader()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(leader, other.leader); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStatis()).compareTo(other.isSetStatis()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(statis, other.statis); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LEADER: - if (__field.type == TType.STRUCT) { - this.leader = new com.vesoft.nebula.HostAddr(); - this.leader.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case STATIS: - if (__field.type == TType.STRUCT) { - this.statis = new StatisItem(); - this.statis.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - if (this.leader != null) { - oprot.writeFieldBegin(LEADER_FIELD_DESC); - this.leader.write(oprot); - oprot.writeFieldEnd(); - } - if (this.statis != null) { - oprot.writeFieldBegin(STATIS_FIELD_DESC); - this.statis.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetStatisResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("leader"); - sb.append(space); - sb.append(":").append(space); - if (this.getLeader() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("statis"); - sb.append(space); - sb.append(":").append(space); - if (this.getStatis() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getStatis(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java index 3a74cfcd4..c6f6a63d8 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/GetZoneResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list228 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list228.size)); - for (int _i229 = 0; - (_list228.size < 0) ? iprot.peekList() : (_i229 < _list228.size); - ++_i229) + TList _list232 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list232.size)); + for (int _i233 = 0; + (_list232.size < 0) ? iprot.peekList() : (_i233 < _list232.size); + ++_i233) { - com.vesoft.nebula.HostAddr _elem230; - _elem230 = new com.vesoft.nebula.HostAddr(); - _elem230.read(iprot); - this.hosts.add(_elem230); + com.vesoft.nebula.HostAddr _elem234; + _elem234 = new com.vesoft.nebula.HostAddr(); + _elem234.read(iprot); + this.hosts.add(_elem234); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (com.vesoft.nebula.HostAddr _iter231 : this.hosts) { - _iter231.write(oprot); + for (com.vesoft.nebula.HostAddr _iter235 : this.hosts) { + _iter235.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Group.java b/client/src/main/generated/com/vesoft/nebula/meta/Group.java deleted file mode 100644 index 4dd7090c1..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/Group.java +++ /dev/null @@ -1,375 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class Group implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("Group"); - private static final TField GROUP_NAME_FIELD_DESC = new TField("group_name", TType.STRING, (short)1); - private static final TField ZONE_NAMES_FIELD_DESC = new TField("zone_names", TType.LIST, (short)2); - - public byte[] group_name; - public List zone_names; - public static final int GROUP_NAME = 1; - public static final int ZONE_NAMES = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(GROUP_NAME, new FieldMetaData("group_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(ZONE_NAMES, new FieldMetaData("zone_names", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new FieldValueMetaData(TType.STRING)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(Group.class, metaDataMap); - } - - public Group() { - } - - public Group( - byte[] group_name, - List zone_names) { - this(); - this.group_name = group_name; - this.zone_names = zone_names; - } - - public static class Builder { - private byte[] group_name; - private List zone_names; - - public Builder() { - } - - public Builder setGroup_name(final byte[] group_name) { - this.group_name = group_name; - return this; - } - - public Builder setZone_names(final List zone_names) { - this.zone_names = zone_names; - return this; - } - - public Group build() { - Group result = new Group(); - result.setGroup_name(this.group_name); - result.setZone_names(this.zone_names); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public Group(Group other) { - if (other.isSetGroup_name()) { - this.group_name = TBaseHelper.deepCopy(other.group_name); - } - if (other.isSetZone_names()) { - this.zone_names = TBaseHelper.deepCopy(other.zone_names); - } - } - - public Group deepCopy() { - return new Group(this); - } - - public byte[] getGroup_name() { - return this.group_name; - } - - public Group setGroup_name(byte[] group_name) { - this.group_name = group_name; - return this; - } - - public void unsetGroup_name() { - this.group_name = null; - } - - // Returns true if field group_name is set (has been assigned a value) and false otherwise - public boolean isSetGroup_name() { - return this.group_name != null; - } - - public void setGroup_nameIsSet(boolean __value) { - if (!__value) { - this.group_name = null; - } - } - - public List getZone_names() { - return this.zone_names; - } - - public Group setZone_names(List zone_names) { - this.zone_names = zone_names; - return this; - } - - public void unsetZone_names() { - this.zone_names = null; - } - - // Returns true if field zone_names is set (has been assigned a value) and false otherwise - public boolean isSetZone_names() { - return this.zone_names != null; - } - - public void setZone_namesIsSet(boolean __value) { - if (!__value) { - this.zone_names = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case GROUP_NAME: - if (__value == null) { - unsetGroup_name(); - } else { - setGroup_name((byte[])__value); - } - break; - - case ZONE_NAMES: - if (__value == null) { - unsetZone_names(); - } else { - setZone_names((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case GROUP_NAME: - return getGroup_name(); - - case ZONE_NAMES: - return getZone_names(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof Group)) - return false; - Group that = (Group)_that; - - if (!TBaseHelper.equalsSlow(this.isSetGroup_name(), that.isSetGroup_name(), this.group_name, that.group_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetZone_names(), that.isSetZone_names(), this.zone_names, that.zone_names)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {group_name, zone_names}); - } - - @Override - public int compareTo(Group other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetGroup_name()).compareTo(other.isSetGroup_name()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(group_name, other.group_name); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetZone_names()).compareTo(other.isSetZone_names()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(zone_names, other.zone_names); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case GROUP_NAME: - if (__field.type == TType.STRING) { - this.group_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case ZONE_NAMES: - if (__field.type == TType.LIST) { - { - TList _list218 = iprot.readListBegin(); - this.zone_names = new ArrayList(Math.max(0, _list218.size)); - for (int _i219 = 0; - (_list218.size < 0) ? iprot.peekList() : (_i219 < _list218.size); - ++_i219) - { - byte[] _elem220; - _elem220 = iprot.readBinary(); - this.zone_names.add(_elem220); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.group_name != null) { - oprot.writeFieldBegin(GROUP_NAME_FIELD_DESC); - oprot.writeBinary(this.group_name); - oprot.writeFieldEnd(); - } - if (this.zone_names != null) { - oprot.writeFieldBegin(ZONE_NAMES_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRING, this.zone_names.size())); - for (byte[] _iter221 : this.zone_names) { - oprot.writeBinary(_iter221); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("Group"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("group_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getGroup_name() == null) { - sb.append("null"); - } else { - int __group_name_size = Math.min(this.getGroup_name().length, 128); - for (int i = 0; i < __group_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getGroup_name()[i]).length() > 1 ? Integer.toHexString(this.getGroup_name()[i]).substring(Integer.toHexString(this.getGroup_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getGroup_name()[i]).toUpperCase()); - } - if (this.getGroup_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("zone_names"); - sb.append(space); - sb.append(":").append(space); - if (this.getZone_names() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getZone_names(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java index ea800cae9..5f482dd6e 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HBReq.java @@ -32,6 +32,8 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable private static final TField LEADER_PART_IDS_FIELD_DESC = new TField("leader_partIds", TType.MAP, (short)4); private static final TField GIT_INFO_SHA_FIELD_DESC = new TField("git_info_sha", TType.STRING, (short)5); private static final TField DISK_PARTS_FIELD_DESC = new TField("disk_parts", TType.MAP, (short)6); + private static final TField DIR_FIELD_DESC = new TField("dir", TType.STRUCT, (short)7); + private static final TField VERSION_FIELD_DESC = new TField("version", TType.STRING, (short)8); /** * @@ -43,12 +45,16 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable public Map> leader_partIds; public byte[] git_info_sha; public Map> disk_parts; + public com.vesoft.nebula.DirInfo dir; + public byte[] version; public static final int ROLE = 1; public static final int HOST = 2; public static final int CLUSTER_ID = 3; public static final int LEADER_PARTIDS = 4; public static final int GIT_INFO_SHA = 5; public static final int DISK_PARTS = 6; + public static final int DIR = 7; + public static final int VERSION = 8; // isset id assignments private static final int __CLUSTER_ID_ISSET_ID = 0; @@ -77,6 +83,10 @@ public class HBReq implements TBase, java.io.Serializable, Cloneable, Comparable new MapMetaData(TType.MAP, new FieldValueMetaData(TType.STRING), new StructMetaData(TType.STRUCT, PartitionList.class))))); + tmpMetaDataMap.put(DIR, new FieldMetaData("dir", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.DirInfo.class))); + tmpMetaDataMap.put(VERSION, new FieldMetaData("version", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -106,7 +116,9 @@ public HBReq( long cluster_id, Map> leader_partIds, byte[] git_info_sha, - Map> disk_parts) { + Map> disk_parts, + com.vesoft.nebula.DirInfo dir, + byte[] version) { this(); this.role = role; this.host = host; @@ -115,6 +127,8 @@ public HBReq( this.leader_partIds = leader_partIds; this.git_info_sha = git_info_sha; this.disk_parts = disk_parts; + this.dir = dir; + this.version = version; } public static class Builder { @@ -124,6 +138,8 @@ public static class Builder { private Map> leader_partIds; private byte[] git_info_sha; private Map> disk_parts; + private com.vesoft.nebula.DirInfo dir; + private byte[] version; BitSet __optional_isset = new BitSet(1); @@ -161,6 +177,16 @@ public Builder setDisk_parts(final Map> disk_p return this; } + public Builder setDir(final com.vesoft.nebula.DirInfo dir) { + this.dir = dir; + return this; + } + + public Builder setVersion(final byte[] version) { + this.version = version; + return this; + } + public HBReq build() { HBReq result = new HBReq(); result.setRole(this.role); @@ -171,6 +197,8 @@ public HBReq build() { result.setLeader_partIds(this.leader_partIds); result.setGit_info_sha(this.git_info_sha); result.setDisk_parts(this.disk_parts); + result.setDir(this.dir); + result.setVersion(this.version); return result; } } @@ -201,6 +229,12 @@ public HBReq(HBReq other) { if (other.isSetDisk_parts()) { this.disk_parts = TBaseHelper.deepCopy(other.disk_parts); } + if (other.isSetDir()) { + this.dir = TBaseHelper.deepCopy(other.dir); + } + if (other.isSetVersion()) { + this.version = TBaseHelper.deepCopy(other.version); + } } public HBReq deepCopy() { @@ -358,6 +392,54 @@ public void setDisk_partsIsSet(boolean __value) { } } + public com.vesoft.nebula.DirInfo getDir() { + return this.dir; + } + + public HBReq setDir(com.vesoft.nebula.DirInfo dir) { + this.dir = dir; + return this; + } + + public void unsetDir() { + this.dir = null; + } + + // Returns true if field dir is set (has been assigned a value) and false otherwise + public boolean isSetDir() { + return this.dir != null; + } + + public void setDirIsSet(boolean __value) { + if (!__value) { + this.dir = null; + } + } + + public byte[] getVersion() { + return this.version; + } + + public HBReq setVersion(byte[] version) { + this.version = version; + return this; + } + + public void unsetVersion() { + this.version = null; + } + + // Returns true if field version is set (has been assigned a value) and false otherwise + public boolean isSetVersion() { + return this.version != null; + } + + public void setVersionIsSet(boolean __value) { + if (!__value) { + this.version = null; + } + } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { @@ -409,6 +491,22 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case DIR: + if (__value == null) { + unsetDir(); + } else { + setDir((com.vesoft.nebula.DirInfo)__value); + } + break; + + case VERSION: + if (__value == null) { + unsetVersion(); + } else { + setVersion((byte[])__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -434,6 +532,12 @@ public Object getFieldValue(int fieldID) { case DISK_PARTS: return getDisk_parts(); + case DIR: + return getDir(); + + case VERSION: + return getVersion(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -461,12 +565,16 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetDisk_parts(), that.isSetDisk_parts(), this.disk_parts, that.disk_parts)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetDir(), that.isSetDir(), this.dir, that.dir)) { return false; } + + if (!TBaseHelper.equalsSlow(this.isSetVersion(), that.isSetVersion(), this.version, that.version)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {role, host, cluster_id, leader_partIds, git_info_sha, disk_parts}); + return Arrays.deepHashCode(new Object[] {role, host, cluster_id, leader_partIds, git_info_sha, disk_parts, dir, version}); } @Override @@ -529,6 +637,22 @@ public int compareTo(HBReq other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetDir()).compareTo(other.isSetDir()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(dir, other.dir); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetVersion()).compareTo(other.isSetVersion()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(version, other.version); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -643,6 +767,21 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case DIR: + if (__field.type == TType.STRUCT) { + this.dir = new com.vesoft.nebula.DirInfo(); + this.dir.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case VERSION: + if (__field.type == TType.STRING) { + this.version = iprot.readBinary(); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -719,6 +858,20 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } } + if (this.dir != null) { + if (isSetDir()) { + oprot.writeFieldBegin(DIR_FIELD_DESC); + this.dir.write(oprot); + oprot.writeFieldEnd(); + } + } + if (this.version != null) { + if (isSetVersion()) { + oprot.writeFieldBegin(VERSION_FIELD_DESC); + oprot.writeBinary(this.version); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -819,6 +972,39 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } + if (isSetDir()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("dir"); + sb.append(space); + sb.append(":").append(space); + if (this.getDir() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getDir(), indent + 1, prettyPrint)); + } + first = false; + } + if (isSetVersion()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("version"); + sb.append(space); + sb.append(":").append(space); + if (this.getVersion() == null) { + sb.append("null"); + } else { + int __version_size = Math.min(this.getVersion().length, 128); + for (int i = 0; i < __version_size; i++) { + if (i != 0) sb.append(" "); + sb.append(Integer.toHexString(this.getVersion()[i]).length() > 1 ? Integer.toHexString(this.getVersion()[i]).substring(Integer.toHexString(this.getVersion()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getVersion()[i]).toUpperCase()); + } + if (this.getVersion().length > 128) sb.append(" ..."); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/HostBackupInfo.java similarity index 64% rename from client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java rename to client/src/main/generated/com/vesoft/nebula/meta/HostBackupInfo.java index f8387b031..87523998f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/BackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HostBackupInfo.java @@ -24,15 +24,15 @@ import com.facebook.thrift.protocol.*; @SuppressWarnings({ "unused", "serial" }) -public class BackupInfo implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("BackupInfo"); +public class HostBackupInfo implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("HostBackupInfo"); private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)1); - private static final TField INFO_FIELD_DESC = new TField("info", TType.LIST, (short)2); + private static final TField CHECKPOINTS_FIELD_DESC = new TField("checkpoints", TType.LIST, (short)2); public com.vesoft.nebula.HostAddr host; - public List info; + public List checkpoints; public static final int HOST = 1; - public static final int INFO = 2; + public static final int CHECKPOINTS = 2; // isset id assignments @@ -42,30 +42,30 @@ public class BackupInfo implements TBase, java.io.Serializable, Cloneable, Compa Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(HOST, new FieldMetaData("host", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(INFO, new FieldMetaData("info", TFieldRequirementType.DEFAULT, + tmpMetaDataMap.put(CHECKPOINTS, new FieldMetaData("checkpoints", TFieldRequirementType.DEFAULT, new ListMetaData(TType.LIST, new StructMetaData(TType.STRUCT, com.vesoft.nebula.CheckpointInfo.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(BackupInfo.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(HostBackupInfo.class, metaDataMap); } - public BackupInfo() { + public HostBackupInfo() { } - public BackupInfo( + public HostBackupInfo( com.vesoft.nebula.HostAddr host, - List info) { + List checkpoints) { this(); this.host = host; - this.info = info; + this.checkpoints = checkpoints; } public static class Builder { private com.vesoft.nebula.HostAddr host; - private List info; + private List checkpoints; public Builder() { } @@ -75,15 +75,15 @@ public Builder setHost(final com.vesoft.nebula.HostAddr host) { return this; } - public Builder setInfo(final List info) { - this.info = info; + public Builder setCheckpoints(final List checkpoints) { + this.checkpoints = checkpoints; return this; } - public BackupInfo build() { - BackupInfo result = new BackupInfo(); + public HostBackupInfo build() { + HostBackupInfo result = new HostBackupInfo(); result.setHost(this.host); - result.setInfo(this.info); + result.setCheckpoints(this.checkpoints); return result; } } @@ -95,24 +95,24 @@ public static Builder builder() { /** * Performs a deep copy on other. */ - public BackupInfo(BackupInfo other) { + public HostBackupInfo(HostBackupInfo other) { if (other.isSetHost()) { this.host = TBaseHelper.deepCopy(other.host); } - if (other.isSetInfo()) { - this.info = TBaseHelper.deepCopy(other.info); + if (other.isSetCheckpoints()) { + this.checkpoints = TBaseHelper.deepCopy(other.checkpoints); } } - public BackupInfo deepCopy() { - return new BackupInfo(this); + public HostBackupInfo deepCopy() { + return new HostBackupInfo(this); } public com.vesoft.nebula.HostAddr getHost() { return this.host; } - public BackupInfo setHost(com.vesoft.nebula.HostAddr host) { + public HostBackupInfo setHost(com.vesoft.nebula.HostAddr host) { this.host = host; return this; } @@ -132,27 +132,27 @@ public void setHostIsSet(boolean __value) { } } - public List getInfo() { - return this.info; + public List getCheckpoints() { + return this.checkpoints; } - public BackupInfo setInfo(List info) { - this.info = info; + public HostBackupInfo setCheckpoints(List checkpoints) { + this.checkpoints = checkpoints; return this; } - public void unsetInfo() { - this.info = null; + public void unsetCheckpoints() { + this.checkpoints = null; } - // Returns true if field info is set (has been assigned a value) and false otherwise - public boolean isSetInfo() { - return this.info != null; + // Returns true if field checkpoints is set (has been assigned a value) and false otherwise + public boolean isSetCheckpoints() { + return this.checkpoints != null; } - public void setInfoIsSet(boolean __value) { + public void setCheckpointsIsSet(boolean __value) { if (!__value) { - this.info = null; + this.checkpoints = null; } } @@ -167,11 +167,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case INFO: + case CHECKPOINTS: if (__value == null) { - unsetInfo(); + unsetCheckpoints(); } else { - setInfo((List)__value); + setCheckpoints((List)__value); } break; @@ -185,8 +185,8 @@ public Object getFieldValue(int fieldID) { case HOST: return getHost(); - case INFO: - return getInfo(); + case CHECKPOINTS: + return getCheckpoints(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -199,24 +199,24 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof BackupInfo)) + if (!(_that instanceof HostBackupInfo)) return false; - BackupInfo that = (BackupInfo)_that; + HostBackupInfo that = (HostBackupInfo)_that; if (!TBaseHelper.equalsNobinary(this.isSetHost(), that.isSetHost(), this.host, that.host)) { return false; } - if (!TBaseHelper.equalsNobinary(this.isSetInfo(), that.isSetInfo(), this.info, that.info)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetCheckpoints(), that.isSetCheckpoints(), this.checkpoints, that.checkpoints)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {host, info}); + return Arrays.deepHashCode(new Object[] {host, checkpoints}); } @Override - public int compareTo(BackupInfo other) { + public int compareTo(HostBackupInfo other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -235,11 +235,11 @@ public int compareTo(BackupInfo other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetInfo()).compareTo(other.isSetInfo()); + lastComparison = Boolean.valueOf(isSetCheckpoints()).compareTo(other.isSetCheckpoints()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(info, other.info); + lastComparison = TBaseHelper.compareTo(checkpoints, other.checkpoints); if (lastComparison != 0) { return lastComparison; } @@ -265,19 +265,19 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case INFO: + case CHECKPOINTS: if (__field.type == TType.LIST) { { - TList _list248 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list248.size)); - for (int _i249 = 0; - (_list248.size < 0) ? iprot.peekList() : (_i249 < _list248.size); - ++_i249) + TList _list252 = iprot.readListBegin(); + this.checkpoints = new ArrayList(Math.max(0, _list252.size)); + for (int _i253 = 0; + (_list252.size < 0) ? iprot.peekList() : (_i253 < _list252.size); + ++_i253) { - com.vesoft.nebula.CheckpointInfo _elem250; - _elem250 = new com.vesoft.nebula.CheckpointInfo(); - _elem250.read(iprot); - this.info.add(_elem250); + com.vesoft.nebula.CheckpointInfo _elem254; + _elem254 = new com.vesoft.nebula.CheckpointInfo(); + _elem254.read(iprot); + this.checkpoints.add(_elem254); } iprot.readListEnd(); } @@ -307,12 +307,12 @@ public void write(TProtocol oprot) throws TException { this.host.write(oprot); oprot.writeFieldEnd(); } - if (this.info != null) { - oprot.writeFieldBegin(INFO_FIELD_DESC); + if (this.checkpoints != null) { + oprot.writeFieldBegin(CHECKPOINTS_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter251 : this.info) { - _iter251.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, this.checkpoints.size())); + for (com.vesoft.nebula.CheckpointInfo _iter255 : this.checkpoints) { + _iter255.write(oprot); } oprot.writeListEnd(); } @@ -332,7 +332,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("BackupInfo"); + StringBuilder sb = new StringBuilder("HostBackupInfo"); sb.append(space); sb.append("("); sb.append(newLine); @@ -350,13 +350,13 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("info"); + sb.append("checkpoints"); sb.append(space); sb.append(":").append(space); - if (this.getInfo() == null) { + if (this.getCheckpoints() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getInfo(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getCheckpoints(), indent + 1, prettyPrint)); } first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/HostRole.java b/client/src/main/generated/com/vesoft/nebula/meta/HostRole.java index 23067c70a..5b3fdf29f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/HostRole.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/HostRole.java @@ -17,7 +17,8 @@ public enum HostRole implements com.facebook.thrift.TEnum { META(1), STORAGE(2), LISTENER(3), - UNKNOWN(4); + AGENT(4), + UNKNOWN(5); private final int value; @@ -47,6 +48,8 @@ public static HostRole findByValue(int value) { case 3: return LISTENER; case 4: + return AGENT; + case 5: return UNKNOWN; default: return null; diff --git a/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java b/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java index 20fabbffe..6df66ef3a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/IndexItem.java @@ -32,6 +32,7 @@ public class IndexItem implements TBase, java.io.Serializable, Cloneable, Compar private static final TField SCHEMA_NAME_FIELD_DESC = new TField("schema_name", TType.STRING, (short)4); private static final TField FIELDS_FIELD_DESC = new TField("fields", TType.LIST, (short)5); private static final TField COMMENT_FIELD_DESC = new TField("comment", TType.STRING, (short)6); + private static final TField INDEX_PARAMS_FIELD_DESC = new TField("index_params", TType.STRUCT, (short)7); public int index_id; public byte[] index_name; @@ -39,12 +40,14 @@ public class IndexItem implements TBase, java.io.Serializable, Cloneable, Compar public byte[] schema_name; public List fields; public byte[] comment; + public IndexParams index_params; public static final int INDEX_ID = 1; public static final int INDEX_NAME = 2; public static final int SCHEMA_ID = 3; public static final int SCHEMA_NAME = 4; public static final int FIELDS = 5; public static final int COMMENT = 6; + public static final int INDEX_PARAMS = 7; // isset id assignments private static final int __INDEX_ID_ISSET_ID = 0; @@ -67,6 +70,8 @@ public class IndexItem implements TBase, java.io.Serializable, Cloneable, Compar new StructMetaData(TType.STRUCT, ColumnDef.class)))); tmpMetaDataMap.put(COMMENT, new FieldMetaData("comment", TFieldRequirementType.OPTIONAL, new FieldValueMetaData(TType.STRING))); + tmpMetaDataMap.put(INDEX_PARAMS, new FieldMetaData("index_params", TFieldRequirementType.OPTIONAL, + new StructMetaData(TType.STRUCT, IndexParams.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -98,7 +103,8 @@ public IndexItem( com.vesoft.nebula.SchemaID schema_id, byte[] schema_name, List fields, - byte[] comment) { + byte[] comment, + IndexParams index_params) { this(); this.index_id = index_id; setIndex_idIsSet(true); @@ -107,6 +113,7 @@ public IndexItem( this.schema_name = schema_name; this.fields = fields; this.comment = comment; + this.index_params = index_params; } public static class Builder { @@ -116,6 +123,7 @@ public static class Builder { private byte[] schema_name; private List fields; private byte[] comment; + private IndexParams index_params; BitSet __optional_isset = new BitSet(1); @@ -153,6 +161,11 @@ public Builder setComment(final byte[] comment) { return this; } + public Builder setIndex_params(final IndexParams index_params) { + this.index_params = index_params; + return this; + } + public IndexItem build() { IndexItem result = new IndexItem(); if (__optional_isset.get(__INDEX_ID_ISSET_ID)) { @@ -163,6 +176,7 @@ public IndexItem build() { result.setSchema_name(this.schema_name); result.setFields(this.fields); result.setComment(this.comment); + result.setIndex_params(this.index_params); return result; } } @@ -193,6 +207,9 @@ public IndexItem(IndexItem other) { if (other.isSetComment()) { this.comment = TBaseHelper.deepCopy(other.comment); } + if (other.isSetIndex_params()) { + this.index_params = TBaseHelper.deepCopy(other.index_params); + } } public IndexItem deepCopy() { @@ -342,6 +359,30 @@ public void setCommentIsSet(boolean __value) { } } + public IndexParams getIndex_params() { + return this.index_params; + } + + public IndexItem setIndex_params(IndexParams index_params) { + this.index_params = index_params; + return this; + } + + public void unsetIndex_params() { + this.index_params = null; + } + + // Returns true if field index_params is set (has been assigned a value) and false otherwise + public boolean isSetIndex_params() { + return this.index_params != null; + } + + public void setIndex_paramsIsSet(boolean __value) { + if (!__value) { + this.index_params = null; + } + } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { @@ -393,6 +434,14 @@ public void setFieldValue(int fieldID, Object __value) { } break; + case INDEX_PARAMS: + if (__value == null) { + unsetIndex_params(); + } else { + setIndex_params((IndexParams)__value); + } + break; + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -418,6 +467,9 @@ public Object getFieldValue(int fieldID) { case COMMENT: return getComment(); + case INDEX_PARAMS: + return getIndex_params(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -445,12 +497,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsSlow(this.isSetComment(), that.isSetComment(), this.comment, that.comment)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetIndex_params(), that.isSetIndex_params(), this.index_params, that.index_params)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {index_id, index_name, schema_id, schema_name, fields, comment}); + return Arrays.deepHashCode(new Object[] {index_id, index_name, schema_id, schema_name, fields, comment, index_params}); } @Override @@ -513,6 +567,14 @@ public int compareTo(IndexItem other) { if (lastComparison != 0) { return lastComparison; } + lastComparison = Boolean.valueOf(isSetIndex_params()).compareTo(other.isSetIndex_params()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(index_params, other.index_params); + if (lastComparison != 0) { + return lastComparison; + } return 0; } @@ -584,6 +646,14 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; + case INDEX_PARAMS: + if (__field.type == TType.STRUCT) { + this.index_params = new IndexParams(); + this.index_params.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; default: TProtocolUtil.skip(iprot, __field.type); break; @@ -637,6 +707,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldEnd(); } } + if (this.index_params != null) { + if (isSetIndex_params()) { + oprot.writeFieldBegin(INDEX_PARAMS_FIELD_DESC); + this.index_params.write(oprot); + oprot.writeFieldEnd(); + } + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -736,6 +813,20 @@ public String toString(int indent, boolean prettyPrint) { } first = false; } + if (isSetIndex_params()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("index_params"); + sb.append(space); + sb.append(":").append(space); + if (this.getIndex_params() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getIndex_params(), indent + 1, prettyPrint)); + } + first = false; + } sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); sb.append(")"); return sb.toString(); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java b/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java new file mode 100644 index 000000000..e96d81751 --- /dev/null +++ b/client/src/main/generated/com/vesoft/nebula/meta/IndexParams.java @@ -0,0 +1,359 @@ +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package com.vesoft.nebula.meta; + +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; +import java.util.Collections; +import java.util.BitSet; +import java.util.Arrays; +import com.facebook.thrift.*; +import com.facebook.thrift.annotations.*; +import com.facebook.thrift.async.*; +import com.facebook.thrift.meta_data.*; +import com.facebook.thrift.server.*; +import com.facebook.thrift.transport.*; +import com.facebook.thrift.protocol.*; + +@SuppressWarnings({ "unused", "serial" }) +public class IndexParams implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("IndexParams"); + private static final TField S2_MAX_LEVEL_FIELD_DESC = new TField("s2_max_level", TType.I32, (short)1); + private static final TField S2_MAX_CELLS_FIELD_DESC = new TField("s2_max_cells", TType.I32, (short)2); + + public int s2_max_level; + public int s2_max_cells; + public static final int S2_MAX_LEVEL = 1; + public static final int S2_MAX_CELLS = 2; + + // isset id assignments + private static final int __S2_MAX_LEVEL_ISSET_ID = 0; + private static final int __S2_MAX_CELLS_ISSET_ID = 1; + private BitSet __isset_bit_vector = new BitSet(2); + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(S2_MAX_LEVEL, new FieldMetaData("s2_max_level", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(S2_MAX_CELLS, new FieldMetaData("s2_max_cells", TFieldRequirementType.OPTIONAL, + new FieldValueMetaData(TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(IndexParams.class, metaDataMap); + } + + public IndexParams() { + } + + public IndexParams( + int s2_max_level, + int s2_max_cells) { + this(); + this.s2_max_level = s2_max_level; + setS2_max_levelIsSet(true); + this.s2_max_cells = s2_max_cells; + setS2_max_cellsIsSet(true); + } + + public static class Builder { + private int s2_max_level; + private int s2_max_cells; + + BitSet __optional_isset = new BitSet(2); + + public Builder() { + } + + public Builder setS2_max_level(final int s2_max_level) { + this.s2_max_level = s2_max_level; + __optional_isset.set(__S2_MAX_LEVEL_ISSET_ID, true); + return this; + } + + public Builder setS2_max_cells(final int s2_max_cells) { + this.s2_max_cells = s2_max_cells; + __optional_isset.set(__S2_MAX_CELLS_ISSET_ID, true); + return this; + } + + public IndexParams build() { + IndexParams result = new IndexParams(); + if (__optional_isset.get(__S2_MAX_LEVEL_ISSET_ID)) { + result.setS2_max_level(this.s2_max_level); + } + if (__optional_isset.get(__S2_MAX_CELLS_ISSET_ID)) { + result.setS2_max_cells(this.s2_max_cells); + } + return result; + } + } + + public static Builder builder() { + return new Builder(); + } + + /** + * Performs a deep copy on other. + */ + public IndexParams(IndexParams other) { + __isset_bit_vector.clear(); + __isset_bit_vector.or(other.__isset_bit_vector); + this.s2_max_level = TBaseHelper.deepCopy(other.s2_max_level); + this.s2_max_cells = TBaseHelper.deepCopy(other.s2_max_cells); + } + + public IndexParams deepCopy() { + return new IndexParams(this); + } + + public int getS2_max_level() { + return this.s2_max_level; + } + + public IndexParams setS2_max_level(int s2_max_level) { + this.s2_max_level = s2_max_level; + setS2_max_levelIsSet(true); + return this; + } + + public void unsetS2_max_level() { + __isset_bit_vector.clear(__S2_MAX_LEVEL_ISSET_ID); + } + + // Returns true if field s2_max_level is set (has been assigned a value) and false otherwise + public boolean isSetS2_max_level() { + return __isset_bit_vector.get(__S2_MAX_LEVEL_ISSET_ID); + } + + public void setS2_max_levelIsSet(boolean __value) { + __isset_bit_vector.set(__S2_MAX_LEVEL_ISSET_ID, __value); + } + + public int getS2_max_cells() { + return this.s2_max_cells; + } + + public IndexParams setS2_max_cells(int s2_max_cells) { + this.s2_max_cells = s2_max_cells; + setS2_max_cellsIsSet(true); + return this; + } + + public void unsetS2_max_cells() { + __isset_bit_vector.clear(__S2_MAX_CELLS_ISSET_ID); + } + + // Returns true if field s2_max_cells is set (has been assigned a value) and false otherwise + public boolean isSetS2_max_cells() { + return __isset_bit_vector.get(__S2_MAX_CELLS_ISSET_ID); + } + + public void setS2_max_cellsIsSet(boolean __value) { + __isset_bit_vector.set(__S2_MAX_CELLS_ISSET_ID, __value); + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case S2_MAX_LEVEL: + if (__value == null) { + unsetS2_max_level(); + } else { + setS2_max_level((Integer)__value); + } + break; + + case S2_MAX_CELLS: + if (__value == null) { + unsetS2_max_cells(); + } else { + setS2_max_cells((Integer)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case S2_MAX_LEVEL: + return new Integer(getS2_max_level()); + + case S2_MAX_CELLS: + return new Integer(getS2_max_cells()); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof IndexParams)) + return false; + IndexParams that = (IndexParams)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetS2_max_level(), that.isSetS2_max_level(), this.s2_max_level, that.s2_max_level)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetS2_max_cells(), that.isSetS2_max_cells(), this.s2_max_cells, that.s2_max_cells)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {s2_max_level, s2_max_cells}); + } + + @Override + public int compareTo(IndexParams other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetS2_max_level()).compareTo(other.isSetS2_max_level()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(s2_max_level, other.s2_max_level); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetS2_max_cells()).compareTo(other.isSetS2_max_cells()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(s2_max_cells, other.s2_max_cells); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case S2_MAX_LEVEL: + if (__field.type == TType.I32) { + this.s2_max_level = iprot.readI32(); + setS2_max_levelIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case S2_MAX_CELLS: + if (__field.type == TType.I32) { + this.s2_max_cells = iprot.readI32(); + setS2_max_cellsIsSet(true); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (isSetS2_max_level()) { + oprot.writeFieldBegin(S2_MAX_LEVEL_FIELD_DESC); + oprot.writeI32(this.s2_max_level); + oprot.writeFieldEnd(); + } + if (isSetS2_max_cells()) { + oprot.writeFieldBegin(S2_MAX_CELLS_FIELD_DESC); + oprot.writeI32(this.s2_max_cells); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("IndexParams"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + if (isSetS2_max_level()) + { + sb.append(indentStr); + sb.append("s2_max_level"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getS2_max_level(), indent + 1, prettyPrint)); + first = false; + } + if (isSetS2_max_cells()) + { + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("s2_max_cells"); + sb.append(space); + sb.append(":").append(space); + sb.append(TBaseHelper.toString(this.getS2_max_cells(), indent + 1, prettyPrint)); + first = false; + } + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + +} + diff --git a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java index ebdd259a9..b06cb44bc 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/KillQueryReq.java @@ -200,29 +200,29 @@ public void read(TProtocol iprot) throws TException { case KILL_QUERIES: if (__field.type == TType.MAP) { { - TMap _map322 = iprot.readMapBegin(); - this.kill_queries = new HashMap>(Math.max(0, 2*_map322.size)); - for (int _i323 = 0; - (_map322.size < 0) ? iprot.peekMap() : (_i323 < _map322.size); - ++_i323) + TMap _map326 = iprot.readMapBegin(); + this.kill_queries = new HashMap>(Math.max(0, 2*_map326.size)); + for (int _i327 = 0; + (_map326.size < 0) ? iprot.peekMap() : (_i327 < _map326.size); + ++_i327) { - long _key324; - Set _val325; - _key324 = iprot.readI64(); + long _key328; + Set _val329; + _key328 = iprot.readI64(); { - TSet _set326 = iprot.readSetBegin(); - _val325 = new HashSet(Math.max(0, 2*_set326.size)); - for (int _i327 = 0; - (_set326.size < 0) ? iprot.peekSet() : (_i327 < _set326.size); - ++_i327) + TSet _set330 = iprot.readSetBegin(); + _val329 = new HashSet(Math.max(0, 2*_set330.size)); + for (int _i331 = 0; + (_set330.size < 0) ? iprot.peekSet() : (_i331 < _set330.size); + ++_i331) { - long _elem328; - _elem328 = iprot.readI64(); - _val325.add(_elem328); + long _elem332; + _elem332 = iprot.readI64(); + _val329.add(_elem332); } iprot.readSetEnd(); } - this.kill_queries.put(_key324, _val325); + this.kill_queries.put(_key328, _val329); } iprot.readMapEnd(); } @@ -251,12 +251,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILL_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.SET, this.kill_queries.size())); - for (Map.Entry> _iter329 : this.kill_queries.entrySet()) { - oprot.writeI64(_iter329.getKey()); + for (Map.Entry> _iter333 : this.kill_queries.entrySet()) { + oprot.writeI64(_iter333.getKey()); { - oprot.writeSetBegin(new TSet(TType.I64, _iter329.getValue().size())); - for (long _iter330 : _iter329.getValue()) { - oprot.writeI64(_iter330); + oprot.writeSetBegin(new TSet(TType.I64, _iter333.getValue().size())); + for (long _iter334 : _iter333.getValue()) { + oprot.writeI64(_iter334); } oprot.writeSetEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/LeaderBalanceReq.java b/client/src/main/generated/com/vesoft/nebula/meta/LeaderBalanceReq.java deleted file mode 100644 index c9c4a6bc0..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/LeaderBalanceReq.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class LeaderBalanceReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("LeaderBalanceReq"); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(LeaderBalanceReq.class, metaDataMap); - } - - public LeaderBalanceReq() { - } - - public static class Builder { - - public Builder() { - } - - public LeaderBalanceReq build() { - LeaderBalanceReq result = new LeaderBalanceReq(); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public LeaderBalanceReq(LeaderBalanceReq other) { - } - - public LeaderBalanceReq deepCopy() { - return new LeaderBalanceReq(this); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof LeaderBalanceReq)) - return false; - LeaderBalanceReq that = (LeaderBalanceReq)_that; - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {}); - } - - @Override - public int compareTo(LeaderBalanceReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("LeaderBalanceReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java deleted file mode 100644 index dae1437e8..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsReq.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListAllSessionsReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsReq"); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListAllSessionsReq.class, metaDataMap); - } - - public ListAllSessionsReq() { - } - - public static class Builder { - - public Builder() { - } - - public ListAllSessionsReq build() { - ListAllSessionsReq result = new ListAllSessionsReq(); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListAllSessionsReq(ListAllSessionsReq other) { - } - - public ListAllSessionsReq deepCopy() { - return new ListAllSessionsReq(this); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListAllSessionsReq)) - return false; - ListAllSessionsReq that = (ListAllSessionsReq)_that; - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {}); - } - - @Override - public int compareTo(ListAllSessionsReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListAllSessionsReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java deleted file mode 100644 index 53c5a5115..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListAllSessionsResp.java +++ /dev/null @@ -1,438 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListAllSessionsResp implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("ListAllSessionsResp"); - private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); - private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField SESSIONS_FIELD_DESC = new TField("sessions", TType.LIST, (short)3); - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode code; - public com.vesoft.nebula.HostAddr leader; - public List sessions; - public static final int CODE = 1; - public static final int LEADER = 2; - public static final int SESSIONS = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CODE, new FieldMetaData("code", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(SESSIONS, new FieldMetaData("sessions", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Session.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListAllSessionsResp.class, metaDataMap); - } - - public ListAllSessionsResp() { - } - - public ListAllSessionsResp( - com.vesoft.nebula.ErrorCode code, - com.vesoft.nebula.HostAddr leader, - List sessions) { - this(); - this.code = code; - this.leader = leader; - this.sessions = sessions; - } - - public static class Builder { - private com.vesoft.nebula.ErrorCode code; - private com.vesoft.nebula.HostAddr leader; - private List sessions; - - public Builder() { - } - - public Builder setCode(final com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public Builder setSessions(final List sessions) { - this.sessions = sessions; - return this; - } - - public ListAllSessionsResp build() { - ListAllSessionsResp result = new ListAllSessionsResp(); - result.setCode(this.code); - result.setLeader(this.leader); - result.setSessions(this.sessions); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListAllSessionsResp(ListAllSessionsResp other) { - if (other.isSetCode()) { - this.code = TBaseHelper.deepCopy(other.code); - } - if (other.isSetLeader()) { - this.leader = TBaseHelper.deepCopy(other.leader); - } - if (other.isSetSessions()) { - this.sessions = TBaseHelper.deepCopy(other.sessions); - } - } - - public ListAllSessionsResp deepCopy() { - return new ListAllSessionsResp(this); - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public com.vesoft.nebula.ErrorCode getCode() { - return this.code; - } - - /** - * - * @see com.vesoft.nebula.ErrorCode - */ - public ListAllSessionsResp setCode(com.vesoft.nebula.ErrorCode code) { - this.code = code; - return this; - } - - public void unsetCode() { - this.code = null; - } - - // Returns true if field code is set (has been assigned a value) and false otherwise - public boolean isSetCode() { - return this.code != null; - } - - public void setCodeIsSet(boolean __value) { - if (!__value) { - this.code = null; - } - } - - public com.vesoft.nebula.HostAddr getLeader() { - return this.leader; - } - - public ListAllSessionsResp setLeader(com.vesoft.nebula.HostAddr leader) { - this.leader = leader; - return this; - } - - public void unsetLeader() { - this.leader = null; - } - - // Returns true if field leader is set (has been assigned a value) and false otherwise - public boolean isSetLeader() { - return this.leader != null; - } - - public void setLeaderIsSet(boolean __value) { - if (!__value) { - this.leader = null; - } - } - - public List getSessions() { - return this.sessions; - } - - public ListAllSessionsResp setSessions(List sessions) { - this.sessions = sessions; - return this; - } - - public void unsetSessions() { - this.sessions = null; - } - - // Returns true if field sessions is set (has been assigned a value) and false otherwise - public boolean isSetSessions() { - return this.sessions != null; - } - - public void setSessionsIsSet(boolean __value) { - if (!__value) { - this.sessions = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CODE: - if (__value == null) { - unsetCode(); - } else { - setCode((com.vesoft.nebula.ErrorCode)__value); - } - break; - - case LEADER: - if (__value == null) { - unsetLeader(); - } else { - setLeader((com.vesoft.nebula.HostAddr)__value); - } - break; - - case SESSIONS: - if (__value == null) { - unsetSessions(); - } else { - setSessions((List)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CODE: - return getCode(); - - case LEADER: - return getLeader(); - - case SESSIONS: - return getSessions(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListAllSessionsResp)) - return false; - ListAllSessionsResp that = (ListAllSessionsResp)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetCode(), that.isSetCode(), this.code, that.code)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetSessions(), that.isSetSessions(), this.sessions, that.sessions)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, sessions}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CODE: - if (__field.type == TType.I32) { - this.code = com.vesoft.nebula.ErrorCode.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case LEADER: - if (__field.type == TType.STRUCT) { - this.leader = new com.vesoft.nebula.HostAddr(); - this.leader.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SESSIONS: - if (__field.type == TType.LIST) { - { - TList _list308 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list308.size)); - for (int _i309 = 0; - (_list308.size < 0) ? iprot.peekList() : (_i309 < _list308.size); - ++_i309) - { - Session _elem310; - _elem310 = new Session(); - _elem310.read(iprot); - this.sessions.add(_elem310); - } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.code != null) { - oprot.writeFieldBegin(CODE_FIELD_DESC); - oprot.writeI32(this.code == null ? 0 : this.code.getValue()); - oprot.writeFieldEnd(); - } - if (this.leader != null) { - oprot.writeFieldBegin(LEADER_FIELD_DESC); - this.leader.write(oprot); - oprot.writeFieldEnd(); - } - if (this.sessions != null) { - oprot.writeFieldBegin(SESSIONS_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter311 : this.sessions) { - _iter311.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListAllSessionsResp"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("code"); - sb.append(space); - sb.append(":").append(space); - if (this.getCode() == null) { - sb.append("null"); - } else { - String code_name = this.getCode() == null ? "null" : this.getCode().name(); - if (code_name != null) { - sb.append(code_name); - sb.append(" ("); - } - sb.append(this.getCode()); - if (code_name != null) { - sb.append(")"); - } - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("leader"); - sb.append(space); - sb.append(":").append(space); - if (this.getLeader() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getLeader(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("sessions"); - sb.append(space); - sb.append(":").append(space); - if (this.getSessions() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSessions(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java index a8c99667b..518ed0c4a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListClusterInfoResp.java @@ -28,8 +28,7 @@ public class ListClusterInfoResp implements TBase, java.io.Serializable, Cloneab private static final TStruct STRUCT_DESC = new TStruct("ListClusterInfoResp"); private static final TField CODE_FIELD_DESC = new TField("code", TType.I32, (short)1); private static final TField LEADER_FIELD_DESC = new TField("leader", TType.STRUCT, (short)2); - private static final TField META_SERVERS_FIELD_DESC = new TField("meta_servers", TType.LIST, (short)3); - private static final TField STORAGE_SERVERS_FIELD_DESC = new TField("storage_servers", TType.LIST, (short)4); + private static final TField HOST_SERVICES_FIELD_DESC = new TField("host_services", TType.MAP, (short)3); /** * @@ -37,12 +36,10 @@ public class ListClusterInfoResp implements TBase, java.io.Serializable, Cloneab */ public com.vesoft.nebula.ErrorCode code; public com.vesoft.nebula.HostAddr leader; - public List meta_servers; - public List storage_servers; + public Map> host_services; public static final int CODE = 1; public static final int LEADER = 2; - public static final int META_SERVERS = 3; - public static final int STORAGE_SERVERS = 4; + public static final int HOST_SERVICES = 3; // isset id assignments @@ -54,12 +51,11 @@ public class ListClusterInfoResp implements TBase, java.io.Serializable, Cloneab new FieldValueMetaData(TType.I32))); tmpMetaDataMap.put(LEADER, new FieldMetaData("leader", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(META_SERVERS, new FieldMetaData("meta_servers", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class)))); - tmpMetaDataMap.put(STORAGE_SERVERS, new FieldMetaData("storage_servers", TFieldRequirementType.DEFAULT, - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.NodeInfo.class)))); + tmpMetaDataMap.put(HOST_SERVICES, new FieldMetaData("host_services", TFieldRequirementType.DEFAULT, + new MapMetaData(TType.MAP, + new FieldValueMetaData(TType.STRING), + new ListMetaData(TType.LIST, + new StructMetaData(TType.STRUCT, ServiceInfo.class))))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -73,20 +69,17 @@ public ListClusterInfoResp() { public ListClusterInfoResp( com.vesoft.nebula.ErrorCode code, com.vesoft.nebula.HostAddr leader, - List meta_servers, - List storage_servers) { + Map> host_services) { this(); this.code = code; this.leader = leader; - this.meta_servers = meta_servers; - this.storage_servers = storage_servers; + this.host_services = host_services; } public static class Builder { private com.vesoft.nebula.ErrorCode code; private com.vesoft.nebula.HostAddr leader; - private List meta_servers; - private List storage_servers; + private Map> host_services; public Builder() { } @@ -101,13 +94,8 @@ public Builder setLeader(final com.vesoft.nebula.HostAddr leader) { return this; } - public Builder setMeta_servers(final List meta_servers) { - this.meta_servers = meta_servers; - return this; - } - - public Builder setStorage_servers(final List storage_servers) { - this.storage_servers = storage_servers; + public Builder setHost_services(final Map> host_services) { + this.host_services = host_services; return this; } @@ -115,8 +103,7 @@ public ListClusterInfoResp build() { ListClusterInfoResp result = new ListClusterInfoResp(); result.setCode(this.code); result.setLeader(this.leader); - result.setMeta_servers(this.meta_servers); - result.setStorage_servers(this.storage_servers); + result.setHost_services(this.host_services); return result; } } @@ -135,11 +122,8 @@ public ListClusterInfoResp(ListClusterInfoResp other) { if (other.isSetLeader()) { this.leader = TBaseHelper.deepCopy(other.leader); } - if (other.isSetMeta_servers()) { - this.meta_servers = TBaseHelper.deepCopy(other.meta_servers); - } - if (other.isSetStorage_servers()) { - this.storage_servers = TBaseHelper.deepCopy(other.storage_servers); + if (other.isSetHost_services()) { + this.host_services = TBaseHelper.deepCopy(other.host_services); } } @@ -203,51 +187,27 @@ public void setLeaderIsSet(boolean __value) { } } - public List getMeta_servers() { - return this.meta_servers; + public Map> getHost_services() { + return this.host_services; } - public ListClusterInfoResp setMeta_servers(List meta_servers) { - this.meta_servers = meta_servers; + public ListClusterInfoResp setHost_services(Map> host_services) { + this.host_services = host_services; return this; } - public void unsetMeta_servers() { - this.meta_servers = null; + public void unsetHost_services() { + this.host_services = null; } - // Returns true if field meta_servers is set (has been assigned a value) and false otherwise - public boolean isSetMeta_servers() { - return this.meta_servers != null; + // Returns true if field host_services is set (has been assigned a value) and false otherwise + public boolean isSetHost_services() { + return this.host_services != null; } - public void setMeta_serversIsSet(boolean __value) { + public void setHost_servicesIsSet(boolean __value) { if (!__value) { - this.meta_servers = null; - } - } - - public List getStorage_servers() { - return this.storage_servers; - } - - public ListClusterInfoResp setStorage_servers(List storage_servers) { - this.storage_servers = storage_servers; - return this; - } - - public void unsetStorage_servers() { - this.storage_servers = null; - } - - // Returns true if field storage_servers is set (has been assigned a value) and false otherwise - public boolean isSetStorage_servers() { - return this.storage_servers != null; - } - - public void setStorage_serversIsSet(boolean __value) { - if (!__value) { - this.storage_servers = null; + this.host_services = null; } } @@ -270,19 +230,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case META_SERVERS: + case HOST_SERVICES: if (__value == null) { - unsetMeta_servers(); + unsetHost_services(); } else { - setMeta_servers((List)__value); - } - break; - - case STORAGE_SERVERS: - if (__value == null) { - unsetStorage_servers(); - } else { - setStorage_servers((List)__value); + setHost_services((Map>)__value); } break; @@ -299,11 +251,8 @@ public Object getFieldValue(int fieldID) { case LEADER: return getLeader(); - case META_SERVERS: - return getMeta_servers(); - - case STORAGE_SERVERS: - return getStorage_servers(); + case HOST_SERVICES: + return getHost_services(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -324,16 +273,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetLeader(), that.isSetLeader(), this.leader, that.leader)) { return false; } - if (!TBaseHelper.equalsNobinary(this.isSetMeta_servers(), that.isSetMeta_servers(), this.meta_servers, that.meta_servers)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetStorage_servers(), that.isSetStorage_servers(), this.storage_servers, that.storage_servers)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetHost_services(), that.isSetHost_services(), this.host_services, that.host_services)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {code, leader, meta_servers, storage_servers}); + return Arrays.deepHashCode(new Object[] {code, leader, host_services}); } @Override @@ -364,19 +311,11 @@ public int compareTo(ListClusterInfoResp other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetMeta_servers()).compareTo(other.isSetMeta_servers()); + lastComparison = Boolean.valueOf(isSetHost_services()).compareTo(other.isSetHost_services()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(meta_servers, other.meta_servers); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStorage_servers()).compareTo(other.isSetStorage_servers()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(storage_servers, other.storage_servers); + lastComparison = TBaseHelper.compareTo(host_services, other.host_services); if (lastComparison != 0) { return lastComparison; } @@ -409,41 +348,35 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case META_SERVERS: - if (__field.type == TType.LIST) { + case HOST_SERVICES: + if (__field.type == TType.MAP) { { - TList _list331 = iprot.readListBegin(); - this.meta_servers = new ArrayList(Math.max(0, _list331.size)); - for (int _i332 = 0; - (_list331.size < 0) ? iprot.peekList() : (_i332 < _list331.size); - ++_i332) + TMap _map335 = iprot.readMapBegin(); + this.host_services = new HashMap>(Math.max(0, 2*_map335.size)); + for (int _i336 = 0; + (_map335.size < 0) ? iprot.peekMap() : (_i336 < _map335.size); + ++_i336) { - com.vesoft.nebula.HostAddr _elem333; - _elem333 = new com.vesoft.nebula.HostAddr(); - _elem333.read(iprot); - this.meta_servers.add(_elem333); + String _key337; + List _val338; + _key337 = iprot.readString(); + { + TList _list339 = iprot.readListBegin(); + _val338 = new ArrayList(Math.max(0, _list339.size)); + for (int _i340 = 0; + (_list339.size < 0) ? iprot.peekList() : (_i340 < _list339.size); + ++_i340) + { + ServiceInfo _elem341; + _elem341 = new ServiceInfo(); + _elem341.read(iprot); + _val338.add(_elem341); + } + iprot.readListEnd(); + } + this.host_services.put(_key337, _val338); } - iprot.readListEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case STORAGE_SERVERS: - if (__field.type == TType.LIST) { - { - TList _list334 = iprot.readListBegin(); - this.storage_servers = new ArrayList(Math.max(0, _list334.size)); - for (int _i335 = 0; - (_list334.size < 0) ? iprot.peekList() : (_i335 < _list334.size); - ++_i335) - { - com.vesoft.nebula.NodeInfo _elem336; - _elem336 = new com.vesoft.nebula.NodeInfo(); - _elem336.read(iprot); - this.storage_servers.add(_elem336); - } - iprot.readListEnd(); + iprot.readMapEnd(); } } else { TProtocolUtil.skip(iprot, __field.type); @@ -476,25 +409,21 @@ public void write(TProtocol oprot) throws TException { this.leader.write(oprot); oprot.writeFieldEnd(); } - if (this.meta_servers != null) { - oprot.writeFieldBegin(META_SERVERS_FIELD_DESC); - { - oprot.writeListBegin(new TList(TType.STRUCT, this.meta_servers.size())); - for (com.vesoft.nebula.HostAddr _iter337 : this.meta_servers) { - _iter337.write(oprot); - } - oprot.writeListEnd(); - } - oprot.writeFieldEnd(); - } - if (this.storage_servers != null) { - oprot.writeFieldBegin(STORAGE_SERVERS_FIELD_DESC); + if (this.host_services != null) { + oprot.writeFieldBegin(HOST_SERVICES_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.STRUCT, this.storage_servers.size())); - for (com.vesoft.nebula.NodeInfo _iter338 : this.storage_servers) { - _iter338.write(oprot); + oprot.writeMapBegin(new TMap(TType.STRING, TType.LIST, this.host_services.size())); + for (Map.Entry> _iter342 : this.host_services.entrySet()) { + oprot.writeString(_iter342.getKey()); + { + oprot.writeListBegin(new TList(TType.STRUCT, _iter342.getValue().size())); + for (ServiceInfo _iter343 : _iter342.getValue()) { + _iter343.write(oprot); + } + oprot.writeListEnd(); + } } - oprot.writeListEnd(); + oprot.writeMapEnd(); } oprot.writeFieldEnd(); } @@ -549,24 +478,13 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("meta_servers"); - sb.append(space); - sb.append(":").append(space); - if (this.getMeta_servers() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getMeta_servers(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("storage_servers"); + sb.append("host_services"); sb.append(space); sb.append(":").append(space); - if (this.getStorage_servers() == null) { + if (this.getHost_services() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getStorage_servers(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getHost_services(), indent + 1, prettyPrint)); } first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java index 48d8ce763..fd51989fc 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListConfigsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list208 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list208.size)); - for (int _i209 = 0; - (_list208.size < 0) ? iprot.peekList() : (_i209 < _list208.size); - ++_i209) + TList _list212 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list212.size)); + for (int _i213 = 0; + (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); + ++_i213) { - ConfigItem _elem210; - _elem210 = new ConfigItem(); - _elem210.read(iprot); - this.items.add(_elem210); + ConfigItem _elem214; + _elem214 = new ConfigItem(); + _elem214.read(iprot); + this.items.add(_elem214); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter211 : this.items) { - _iter211.write(oprot); + for (ConfigItem _iter215 : this.items) { + _iter215.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java index ce7ed97b4..119b1e11b 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListEdgeIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list187 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list187.size)); - for (int _i188 = 0; - (_list187.size < 0) ? iprot.peekList() : (_i188 < _list187.size); - ++_i188) + TList _list191 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list191.size)); + for (int _i192 = 0; + (_list191.size < 0) ? iprot.peekList() : (_i192 < _list191.size); + ++_i192) { - IndexItem _elem189; - _elem189 = new IndexItem(); - _elem189.read(iprot); - this.items.add(_elem189); + IndexItem _elem193; + _elem193 = new IndexItem(); + _elem193.read(iprot); + this.items.add(_elem193); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter190 : this.items) { - _iter190.write(oprot); + for (IndexItem _iter194 : this.items) { + _iter194.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java index 292c9609f..3a27008ed 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTClientsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list281 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list281.size)); - for (int _i282 = 0; - (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); - ++_i282) + TList _list285 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list285.size)); + for (int _i286 = 0; + (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); + ++_i286) { - FTClient _elem283; - _elem283 = new FTClient(); - _elem283.read(iprot); - this.clients.add(_elem283); + FTClient _elem287; + _elem287 = new FTClient(); + _elem287.read(iprot); + this.clients.add(_elem287); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter284 : this.clients) { - _iter284.write(oprot); + for (FTClient _iter288 : this.clients) { + _iter288.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java index 5cc6ec2e7..228521ffb 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListFTIndexesResp.java @@ -350,18 +350,18 @@ public void read(TProtocol iprot) throws TException { case INDEXES: if (__field.type == TType.MAP) { { - TMap _map289 = iprot.readMapBegin(); - this.indexes = new HashMap(Math.max(0, 2*_map289.size)); - for (int _i290 = 0; - (_map289.size < 0) ? iprot.peekMap() : (_i290 < _map289.size); - ++_i290) + TMap _map293 = iprot.readMapBegin(); + this.indexes = new HashMap(Math.max(0, 2*_map293.size)); + for (int _i294 = 0; + (_map293.size < 0) ? iprot.peekMap() : (_i294 < _map293.size); + ++_i294) { - byte[] _key291; - FTIndex _val292; - _key291 = iprot.readBinary(); - _val292 = new FTIndex(); - _val292.read(iprot); - this.indexes.put(_key291, _val292); + byte[] _key295; + FTIndex _val296; + _key295 = iprot.readBinary(); + _val296 = new FTIndex(); + _val296.read(iprot); + this.indexes.put(_key295, _val296); } iprot.readMapEnd(); } @@ -400,9 +400,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INDEXES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.indexes.size())); - for (Map.Entry _iter293 : this.indexes.entrySet()) { - oprot.writeBinary(_iter293.getKey()); - _iter293.getValue().write(oprot); + for (Map.Entry _iter297 : this.indexes.entrySet()) { + oprot.writeBinary(_iter297.getKey()); + _iter297.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsReq.java deleted file mode 100644 index a90fe8eb1..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListGroupsReq.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ListGroupsReq implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("ListGroupsReq"); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ListGroupsReq.class, metaDataMap); - } - - public ListGroupsReq() { - } - - public static class Builder { - - public Builder() { - } - - public ListGroupsReq build() { - ListGroupsReq result = new ListGroupsReq(); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ListGroupsReq(ListGroupsReq other) { - } - - public ListGroupsReq deepCopy() { - return new ListGroupsReq(this); - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ListGroupsReq)) - return false; - ListGroupsReq that = (ListGroupsReq)_that; - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {}); - } - - @Override - public int compareTo(ListGroupsReq other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ListGroupsReq"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java index 200baa313..957a51874 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListIndexStatusResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case STATUSES: if (__field.type == TType.LIST) { { - TList _list216 = iprot.readListBegin(); - this.statuses = new ArrayList(Math.max(0, _list216.size)); - for (int _i217 = 0; - (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); - ++_i217) + TList _list220 = iprot.readListBegin(); + this.statuses = new ArrayList(Math.max(0, _list220.size)); + for (int _i221 = 0; + (_list220.size < 0) ? iprot.peekList() : (_i221 < _list220.size); + ++_i221) { - IndexStatus _elem218; - _elem218 = new IndexStatus(); - _elem218.read(iprot); - this.statuses.add(_elem218); + IndexStatus _elem222; + _elem222 = new IndexStatus(); + _elem222.read(iprot); + this.statuses.add(_elem222); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(STATUSES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.statuses.size())); - for (IndexStatus _iter219 : this.statuses) { - _iter219.write(oprot); + for (IndexStatus _iter223 : this.statuses) { + _iter223.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java index 8aaacf82c..0f6db6966 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListListenerResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case LISTENERS: if (__field.type == TType.LIST) { { - TList _list244 = iprot.readListBegin(); - this.listeners = new ArrayList(Math.max(0, _list244.size)); - for (int _i245 = 0; - (_list244.size < 0) ? iprot.peekList() : (_i245 < _list244.size); - ++_i245) + TList _list248 = iprot.readListBegin(); + this.listeners = new ArrayList(Math.max(0, _list248.size)); + for (int _i249 = 0; + (_list248.size < 0) ? iprot.peekList() : (_i249 < _list248.size); + ++_i249) { - ListenerInfo _elem246; - _elem246 = new ListenerInfo(); - _elem246.read(iprot); - this.listeners.add(_elem246); + ListenerInfo _elem250; + _elem250 = new ListenerInfo(); + _elem250.read(iprot); + this.listeners.add(_elem250); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LISTENERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.listeners.size())); - for (ListenerInfo _iter247 : this.listeners) { - _iter247.write(oprot); + for (ListenerInfo _iter251 : this.listeners) { + _iter251.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java index 537b0b495..1c7772b6f 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListRolesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ROLES: if (__field.type == TType.LIST) { { - TList _list196 = iprot.readListBegin(); - this.roles = new ArrayList(Math.max(0, _list196.size)); - for (int _i197 = 0; - (_list196.size < 0) ? iprot.peekList() : (_i197 < _list196.size); - ++_i197) + TList _list200 = iprot.readListBegin(); + this.roles = new ArrayList(Math.max(0, _list200.size)); + for (int _i201 = 0; + (_list200.size < 0) ? iprot.peekList() : (_i201 < _list200.size); + ++_i201) { - RoleItem _elem198; - _elem198 = new RoleItem(); - _elem198.read(iprot); - this.roles.add(_elem198); + RoleItem _elem202; + _elem202 = new RoleItem(); + _elem202.read(iprot); + this.roles.add(_elem202); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ROLES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.roles.size())); - for (RoleItem _iter199 : this.roles) { - _iter199.write(oprot); + for (RoleItem _iter203 : this.roles) { + _iter203.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java index 28163db3a..b24492dc5 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSessionsResp.java @@ -310,16 +310,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list318 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list318.size)); - for (int _i319 = 0; - (_list318.size < 0) ? iprot.peekList() : (_i319 < _list318.size); - ++_i319) + TList _list322 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list322.size)); + for (int _i323 = 0; + (_list322.size < 0) ? iprot.peekList() : (_i323 < _list322.size); + ++_i323) { - Session _elem320; - _elem320 = new Session(); - _elem320.read(iprot); - this.sessions.add(_elem320); + Session _elem324; + _elem324 = new Session(); + _elem324.read(iprot); + this.sessions.add(_elem324); } iprot.readListEnd(); } @@ -358,8 +358,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter321 : this.sessions) { - _iter321.write(oprot); + for (Session _iter325 : this.sessions) { + _iter325.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java index c409ba5d3..9e1cf7d93 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListSnapshotsResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case SNAPSHOTS: if (__field.type == TType.LIST) { { - TList _list212 = iprot.readListBegin(); - this.snapshots = new ArrayList(Math.max(0, _list212.size)); - for (int _i213 = 0; - (_list212.size < 0) ? iprot.peekList() : (_i213 < _list212.size); - ++_i213) + TList _list216 = iprot.readListBegin(); + this.snapshots = new ArrayList(Math.max(0, _list216.size)); + for (int _i217 = 0; + (_list216.size < 0) ? iprot.peekList() : (_i217 < _list216.size); + ++_i217) { - Snapshot _elem214; - _elem214 = new Snapshot(); - _elem214.read(iprot); - this.snapshots.add(_elem214); + Snapshot _elem218; + _elem218 = new Snapshot(); + _elem218.read(iprot); + this.snapshots.add(_elem218); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SNAPSHOTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.snapshots.size())); - for (Snapshot _iter215 : this.snapshots) { - _iter215.write(oprot); + for (Snapshot _iter219 : this.snapshots) { + _iter219.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java index c7ac5a393..2c74d22c2 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListTagIndexesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list179 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list179.size)); - for (int _i180 = 0; - (_list179.size < 0) ? iprot.peekList() : (_i180 < _list179.size); - ++_i180) + TList _list183 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list183.size)); + for (int _i184 = 0; + (_list183.size < 0) ? iprot.peekList() : (_i184 < _list183.size); + ++_i184) { - IndexItem _elem181; - _elem181 = new IndexItem(); - _elem181.read(iprot); - this.items.add(_elem181); + IndexItem _elem185; + _elem185 = new IndexItem(); + _elem185.read(iprot); + this.items.add(_elem185); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (IndexItem _iter182 : this.items) { - _iter182.write(oprot); + for (IndexItem _iter186 : this.items) { + _iter186.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java index dbaa37e01..9c211e881 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListUsersResp.java @@ -350,17 +350,17 @@ public void read(TProtocol iprot) throws TException { case USERS: if (__field.type == TType.MAP) { { - TMap _map191 = iprot.readMapBegin(); - this.users = new HashMap(Math.max(0, 2*_map191.size)); - for (int _i192 = 0; - (_map191.size < 0) ? iprot.peekMap() : (_i192 < _map191.size); - ++_i192) + TMap _map195 = iprot.readMapBegin(); + this.users = new HashMap(Math.max(0, 2*_map195.size)); + for (int _i196 = 0; + (_map195.size < 0) ? iprot.peekMap() : (_i196 < _map195.size); + ++_i196) { - byte[] _key193; - byte[] _val194; - _key193 = iprot.readBinary(); - _val194 = iprot.readBinary(); - this.users.put(_key193, _val194); + byte[] _key197; + byte[] _val198; + _key197 = iprot.readBinary(); + _val198 = iprot.readBinary(); + this.users.put(_key197, _val198); } iprot.readMapEnd(); } @@ -399,9 +399,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(USERS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.users.size())); - for (Map.Entry _iter195 : this.users.entrySet()) { - oprot.writeBinary(_iter195.getKey()); - oprot.writeBinary(_iter195.getValue()); + for (Map.Entry _iter199 : this.users.entrySet()) { + oprot.writeBinary(_iter199.getKey()); + oprot.writeBinary(_iter199.getValue()); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java index 0fd330bf7..1af4f6da2 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ListZonesResp.java @@ -349,16 +349,16 @@ public void read(TProtocol iprot) throws TException { case ZONES: if (__field.type == TType.LIST) { { - TList _list236 = iprot.readListBegin(); - this.zones = new ArrayList(Math.max(0, _list236.size)); - for (int _i237 = 0; - (_list236.size < 0) ? iprot.peekList() : (_i237 < _list236.size); - ++_i237) + TList _list240 = iprot.readListBegin(); + this.zones = new ArrayList(Math.max(0, _list240.size)); + for (int _i241 = 0; + (_list240.size < 0) ? iprot.peekList() : (_i241 < _list240.size); + ++_i241) { - Zone _elem238; - _elem238 = new Zone(); - _elem238.read(iprot); - this.zones.add(_elem238); + Zone _elem242; + _elem242 = new Zone(); + _elem242.read(iprot); + this.zones.add(_elem242); } iprot.readListEnd(); } @@ -397,8 +397,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.zones.size())); - for (Zone _iter239 : this.zones) { - _iter239.write(oprot); + for (Zone _iter243 : this.zones) { + _iter243.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java b/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java index 8437c68b1..d2db72d0d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MergeZoneReq.java @@ -260,15 +260,15 @@ public void read(TProtocol iprot) throws TException { case ZONES: if (__field.type == TType.LIST) { { - TList _list220 = iprot.readListBegin(); - this.zones = new ArrayList(Math.max(0, _list220.size)); - for (int _i221 = 0; - (_list220.size < 0) ? iprot.peekList() : (_i221 < _list220.size); - ++_i221) + TList _list224 = iprot.readListBegin(); + this.zones = new ArrayList(Math.max(0, _list224.size)); + for (int _i225 = 0; + (_list224.size < 0) ? iprot.peekList() : (_i225 < _list224.size); + ++_i225) { - byte[] _elem222; - _elem222 = iprot.readBinary(); - this.zones.add(_elem222); + byte[] _elem226; + _elem226 = iprot.readBinary(); + this.zones.add(_elem226); } iprot.readListEnd(); } @@ -304,8 +304,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ZONES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.zones.size())); - for (byte[] _iter223 : this.zones) { - oprot.writeBinary(_iter223); + for (byte[] _iter227 : this.zones) { + oprot.writeBinary(_iter227); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java index 4d333aa95..39b7e7b4a 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/MetaService.java @@ -129,6 +129,8 @@ public interface Iface { public HBResp heartBeat(HBReq req) throws TException; + public AgentHBResp agentHeartbeat(AgentHBReq req) throws TException; + public ExecResp regConfig(RegConfigReq req) throws TException; public GetConfigResp getConfig(GetConfigReq req) throws TException; @@ -157,10 +159,6 @@ public interface Iface { public ListZonesResp listZones(ListZonesReq req) throws TException; - public CreateBackupResp createBackup(CreateBackupReq req) throws TException; - - public ExecResp restoreMeta(RestoreMetaReq req) throws TException; - public ExecResp addListener(AddListenerReq req) throws TException; public ExecResp removeListener(RemoveListenerReq req) throws TException; @@ -195,6 +193,10 @@ public interface Iface { public ExecResp reportTaskFinish(ReportTaskReq req) throws TException; + public CreateBackupResp createBackup(CreateBackupReq req) throws TException; + + public ExecResp restoreMeta(RestoreMetaReq req) throws TException; + public ListClusterInfoResp listCluster(ListClusterInfoReq req) throws TException; public GetMetaDirInfoResp getMetaDirInfo(GetMetaDirInfoReq req) throws TException; @@ -303,6 +305,8 @@ public interface AsyncIface { public void heartBeat(HBReq req, AsyncMethodCallback resultHandler) throws TException; + public void agentHeartbeat(AgentHBReq req, AsyncMethodCallback resultHandler) throws TException; + public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler) throws TException; public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler) throws TException; @@ -331,10 +335,6 @@ public interface AsyncIface { public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler) throws TException; - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler) throws TException; - - public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler) throws TException; - public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler) throws TException; public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler) throws TException; @@ -369,6 +369,10 @@ public interface AsyncIface { public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler) throws TException; + public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler) throws TException; + + public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler) throws TException; + public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler) throws TException; public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler) throws TException; @@ -2611,6 +2615,51 @@ public HBResp recv_heartBeat() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "heartBeat failed: unknown result"); } + public AgentHBResp agentHeartbeat(AgentHBReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.agentHeartbeat", null); + this.setContextStack(ctx); + send_agentHeartbeat(req); + return recv_agentHeartbeat(); + } + + public void send_agentHeartbeat(AgentHBReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.agentHeartbeat", null); + oprot_.writeMessageBegin(new TMessage("agentHeartbeat", TMessageType.CALL, seqid_)); + agentHeartbeat_args args = new agentHeartbeat_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.agentHeartbeat", args); + return; + } + + public AgentHBResp recv_agentHeartbeat() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.agentHeartbeat"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + agentHeartbeat_result result = new agentHeartbeat_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.agentHeartbeat", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "agentHeartbeat failed: unknown result"); + } + public ExecResp regConfig(RegConfigReq req) throws TException { ContextStack ctx = getContextStack("MetaService.regConfig", null); @@ -3241,96 +3290,6 @@ public ListZonesResp recv_listZones() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "listZones failed: unknown result"); } - public CreateBackupResp createBackup(CreateBackupReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.createBackup", null); - this.setContextStack(ctx); - send_createBackup(req); - return recv_createBackup(); - } - - public void send_createBackup(CreateBackupReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.createBackup", null); - oprot_.writeMessageBegin(new TMessage("createBackup", TMessageType.CALL, seqid_)); - createBackup_args args = new createBackup_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.createBackup", args); - return; - } - - public CreateBackupResp recv_createBackup() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.createBackup"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - createBackup_result result = new createBackup_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.createBackup", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "createBackup failed: unknown result"); - } - - public ExecResp restoreMeta(RestoreMetaReq req) throws TException - { - ContextStack ctx = getContextStack("MetaService.restoreMeta", null); - this.setContextStack(ctx); - send_restoreMeta(req); - return recv_restoreMeta(); - } - - public void send_restoreMeta(RestoreMetaReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "MetaService.restoreMeta", null); - oprot_.writeMessageBegin(new TMessage("restoreMeta", TMessageType.CALL, seqid_)); - restoreMeta_args args = new restoreMeta_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "MetaService.restoreMeta", args); - return; - } - - public ExecResp recv_restoreMeta() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "MetaService.restoreMeta"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - restoreMeta_result result = new restoreMeta_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "MetaService.restoreMeta", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "restoreMeta failed: unknown result"); - } - public ExecResp addListener(AddListenerReq req) throws TException { ContextStack ctx = getContextStack("MetaService.addListener", null); @@ -4096,6 +4055,96 @@ public ExecResp recv_reportTaskFinish() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "reportTaskFinish failed: unknown result"); } + public CreateBackupResp createBackup(CreateBackupReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.createBackup", null); + this.setContextStack(ctx); + send_createBackup(req); + return recv_createBackup(); + } + + public void send_createBackup(CreateBackupReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.createBackup", null); + oprot_.writeMessageBegin(new TMessage("createBackup", TMessageType.CALL, seqid_)); + createBackup_args args = new createBackup_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.createBackup", args); + return; + } + + public CreateBackupResp recv_createBackup() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.createBackup"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + createBackup_result result = new createBackup_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.createBackup", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "createBackup failed: unknown result"); + } + + public ExecResp restoreMeta(RestoreMetaReq req) throws TException + { + ContextStack ctx = getContextStack("MetaService.restoreMeta", null); + this.setContextStack(ctx); + send_restoreMeta(req); + return recv_restoreMeta(); + } + + public void send_restoreMeta(RestoreMetaReq req) throws TException + { + ContextStack ctx = this.getContextStack(); + super.preWrite(ctx, "MetaService.restoreMeta", null); + oprot_.writeMessageBegin(new TMessage("restoreMeta", TMessageType.CALL, seqid_)); + restoreMeta_args args = new restoreMeta_args(); + args.req = req; + args.write(oprot_); + oprot_.writeMessageEnd(); + oprot_.getTransport().flush(); + super.postWrite(ctx, "MetaService.restoreMeta", args); + return; + } + + public ExecResp recv_restoreMeta() throws TException + { + ContextStack ctx = super.getContextStack(); + long bytes; + TMessageType mtype; + super.preRead(ctx, "MetaService.restoreMeta"); + TMessage msg = iprot_.readMessageBegin(); + if (msg.type == TMessageType.EXCEPTION) { + TApplicationException x = TApplicationException.read(iprot_); + iprot_.readMessageEnd(); + throw x; + } + restoreMeta_result result = new restoreMeta_result(); + result.read(iprot_); + iprot_.readMessageEnd(); + super.postRead(ctx, "MetaService.restoreMeta", result); + + if (result.isSetSuccess()) { + return result.success; + } + throw new TApplicationException(TApplicationException.MISSING_RESULT, "restoreMeta failed: unknown result"); + } + public ListClusterInfoResp listCluster(ListClusterInfoReq req) throws TException { ContextStack ctx = getContextStack("MetaService.listCluster", null); @@ -4249,17 +4298,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler427) throws TException { + public void createSpace(CreateSpaceReq req, AsyncMethodCallback resultHandler433) throws TException { checkReady(); - createSpace_call method_call = new createSpace_call(req, resultHandler427, this, ___protocolFactory, ___transport); + createSpace_call method_call = new createSpace_call(req, resultHandler433, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpace_call extends TAsyncMethodCall { private CreateSpaceReq req; - public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler428, TAsyncClient client424, TProtocolFactory protocolFactory425, TNonblockingTransport transport426) throws TException { - super(client424, protocolFactory425, transport426, resultHandler428, false); + public createSpace_call(CreateSpaceReq req, AsyncMethodCallback resultHandler434, TAsyncClient client430, TProtocolFactory protocolFactory431, TNonblockingTransport transport432) throws TException { + super(client430, protocolFactory431, transport432, resultHandler434, false); this.req = req; } @@ -4281,17 +4330,17 @@ public ExecResp getResult() throws TException { } } - public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler432) throws TException { + public void dropSpace(DropSpaceReq req, AsyncMethodCallback resultHandler438) throws TException { checkReady(); - dropSpace_call method_call = new dropSpace_call(req, resultHandler432, this, ___protocolFactory, ___transport); + dropSpace_call method_call = new dropSpace_call(req, resultHandler438, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSpace_call extends TAsyncMethodCall { private DropSpaceReq req; - public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler433, TAsyncClient client429, TProtocolFactory protocolFactory430, TNonblockingTransport transport431) throws TException { - super(client429, protocolFactory430, transport431, resultHandler433, false); + public dropSpace_call(DropSpaceReq req, AsyncMethodCallback resultHandler439, TAsyncClient client435, TProtocolFactory protocolFactory436, TNonblockingTransport transport437) throws TException { + super(client435, protocolFactory436, transport437, resultHandler439, false); this.req = req; } @@ -4313,17 +4362,17 @@ public ExecResp getResult() throws TException { } } - public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler437) throws TException { + public void getSpace(GetSpaceReq req, AsyncMethodCallback resultHandler443) throws TException { checkReady(); - getSpace_call method_call = new getSpace_call(req, resultHandler437, this, ___protocolFactory, ___transport); + getSpace_call method_call = new getSpace_call(req, resultHandler443, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSpace_call extends TAsyncMethodCall { private GetSpaceReq req; - public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler438, TAsyncClient client434, TProtocolFactory protocolFactory435, TNonblockingTransport transport436) throws TException { - super(client434, protocolFactory435, transport436, resultHandler438, false); + public getSpace_call(GetSpaceReq req, AsyncMethodCallback resultHandler444, TAsyncClient client440, TProtocolFactory protocolFactory441, TNonblockingTransport transport442) throws TException { + super(client440, protocolFactory441, transport442, resultHandler444, false); this.req = req; } @@ -4345,17 +4394,17 @@ public GetSpaceResp getResult() throws TException { } } - public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler442) throws TException { + public void listSpaces(ListSpacesReq req, AsyncMethodCallback resultHandler448) throws TException { checkReady(); - listSpaces_call method_call = new listSpaces_call(req, resultHandler442, this, ___protocolFactory, ___transport); + listSpaces_call method_call = new listSpaces_call(req, resultHandler448, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSpaces_call extends TAsyncMethodCall { private ListSpacesReq req; - public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler443, TAsyncClient client439, TProtocolFactory protocolFactory440, TNonblockingTransport transport441) throws TException { - super(client439, protocolFactory440, transport441, resultHandler443, false); + public listSpaces_call(ListSpacesReq req, AsyncMethodCallback resultHandler449, TAsyncClient client445, TProtocolFactory protocolFactory446, TNonblockingTransport transport447) throws TException { + super(client445, protocolFactory446, transport447, resultHandler449, false); this.req = req; } @@ -4377,17 +4426,17 @@ public ListSpacesResp getResult() throws TException { } } - public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler447) throws TException { + public void createSpaceAs(CreateSpaceAsReq req, AsyncMethodCallback resultHandler453) throws TException { checkReady(); - createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler447, this, ___protocolFactory, ___transport); + createSpaceAs_call method_call = new createSpaceAs_call(req, resultHandler453, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSpaceAs_call extends TAsyncMethodCall { private CreateSpaceAsReq req; - public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler448, TAsyncClient client444, TProtocolFactory protocolFactory445, TNonblockingTransport transport446) throws TException { - super(client444, protocolFactory445, transport446, resultHandler448, false); + public createSpaceAs_call(CreateSpaceAsReq req, AsyncMethodCallback resultHandler454, TAsyncClient client450, TProtocolFactory protocolFactory451, TNonblockingTransport transport452) throws TException { + super(client450, protocolFactory451, transport452, resultHandler454, false); this.req = req; } @@ -4409,17 +4458,17 @@ public ExecResp getResult() throws TException { } } - public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler452) throws TException { + public void createTag(CreateTagReq req, AsyncMethodCallback resultHandler458) throws TException { checkReady(); - createTag_call method_call = new createTag_call(req, resultHandler452, this, ___protocolFactory, ___transport); + createTag_call method_call = new createTag_call(req, resultHandler458, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTag_call extends TAsyncMethodCall { private CreateTagReq req; - public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler453, TAsyncClient client449, TProtocolFactory protocolFactory450, TNonblockingTransport transport451) throws TException { - super(client449, protocolFactory450, transport451, resultHandler453, false); + public createTag_call(CreateTagReq req, AsyncMethodCallback resultHandler459, TAsyncClient client455, TProtocolFactory protocolFactory456, TNonblockingTransport transport457) throws TException { + super(client455, protocolFactory456, transport457, resultHandler459, false); this.req = req; } @@ -4441,17 +4490,17 @@ public ExecResp getResult() throws TException { } } - public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler457) throws TException { + public void alterTag(AlterTagReq req, AsyncMethodCallback resultHandler463) throws TException { checkReady(); - alterTag_call method_call = new alterTag_call(req, resultHandler457, this, ___protocolFactory, ___transport); + alterTag_call method_call = new alterTag_call(req, resultHandler463, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterTag_call extends TAsyncMethodCall { private AlterTagReq req; - public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler458, TAsyncClient client454, TProtocolFactory protocolFactory455, TNonblockingTransport transport456) throws TException { - super(client454, protocolFactory455, transport456, resultHandler458, false); + public alterTag_call(AlterTagReq req, AsyncMethodCallback resultHandler464, TAsyncClient client460, TProtocolFactory protocolFactory461, TNonblockingTransport transport462) throws TException { + super(client460, protocolFactory461, transport462, resultHandler464, false); this.req = req; } @@ -4473,17 +4522,17 @@ public ExecResp getResult() throws TException { } } - public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler462) throws TException { + public void dropTag(DropTagReq req, AsyncMethodCallback resultHandler468) throws TException { checkReady(); - dropTag_call method_call = new dropTag_call(req, resultHandler462, this, ___protocolFactory, ___transport); + dropTag_call method_call = new dropTag_call(req, resultHandler468, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTag_call extends TAsyncMethodCall { private DropTagReq req; - public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler463, TAsyncClient client459, TProtocolFactory protocolFactory460, TNonblockingTransport transport461) throws TException { - super(client459, protocolFactory460, transport461, resultHandler463, false); + public dropTag_call(DropTagReq req, AsyncMethodCallback resultHandler469, TAsyncClient client465, TProtocolFactory protocolFactory466, TNonblockingTransport transport467) throws TException { + super(client465, protocolFactory466, transport467, resultHandler469, false); this.req = req; } @@ -4505,17 +4554,17 @@ public ExecResp getResult() throws TException { } } - public void getTag(GetTagReq req, AsyncMethodCallback resultHandler467) throws TException { + public void getTag(GetTagReq req, AsyncMethodCallback resultHandler473) throws TException { checkReady(); - getTag_call method_call = new getTag_call(req, resultHandler467, this, ___protocolFactory, ___transport); + getTag_call method_call = new getTag_call(req, resultHandler473, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTag_call extends TAsyncMethodCall { private GetTagReq req; - public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler468, TAsyncClient client464, TProtocolFactory protocolFactory465, TNonblockingTransport transport466) throws TException { - super(client464, protocolFactory465, transport466, resultHandler468, false); + public getTag_call(GetTagReq req, AsyncMethodCallback resultHandler474, TAsyncClient client470, TProtocolFactory protocolFactory471, TNonblockingTransport transport472) throws TException { + super(client470, protocolFactory471, transport472, resultHandler474, false); this.req = req; } @@ -4537,17 +4586,17 @@ public GetTagResp getResult() throws TException { } } - public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler472) throws TException { + public void listTags(ListTagsReq req, AsyncMethodCallback resultHandler478) throws TException { checkReady(); - listTags_call method_call = new listTags_call(req, resultHandler472, this, ___protocolFactory, ___transport); + listTags_call method_call = new listTags_call(req, resultHandler478, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTags_call extends TAsyncMethodCall { private ListTagsReq req; - public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler473, TAsyncClient client469, TProtocolFactory protocolFactory470, TNonblockingTransport transport471) throws TException { - super(client469, protocolFactory470, transport471, resultHandler473, false); + public listTags_call(ListTagsReq req, AsyncMethodCallback resultHandler479, TAsyncClient client475, TProtocolFactory protocolFactory476, TNonblockingTransport transport477) throws TException { + super(client475, protocolFactory476, transport477, resultHandler479, false); this.req = req; } @@ -4569,17 +4618,17 @@ public ListTagsResp getResult() throws TException { } } - public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler477) throws TException { + public void createEdge(CreateEdgeReq req, AsyncMethodCallback resultHandler483) throws TException { checkReady(); - createEdge_call method_call = new createEdge_call(req, resultHandler477, this, ___protocolFactory, ___transport); + createEdge_call method_call = new createEdge_call(req, resultHandler483, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdge_call extends TAsyncMethodCall { private CreateEdgeReq req; - public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler478, TAsyncClient client474, TProtocolFactory protocolFactory475, TNonblockingTransport transport476) throws TException { - super(client474, protocolFactory475, transport476, resultHandler478, false); + public createEdge_call(CreateEdgeReq req, AsyncMethodCallback resultHandler484, TAsyncClient client480, TProtocolFactory protocolFactory481, TNonblockingTransport transport482) throws TException { + super(client480, protocolFactory481, transport482, resultHandler484, false); this.req = req; } @@ -4601,17 +4650,17 @@ public ExecResp getResult() throws TException { } } - public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler482) throws TException { + public void alterEdge(AlterEdgeReq req, AsyncMethodCallback resultHandler488) throws TException { checkReady(); - alterEdge_call method_call = new alterEdge_call(req, resultHandler482, this, ___protocolFactory, ___transport); + alterEdge_call method_call = new alterEdge_call(req, resultHandler488, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterEdge_call extends TAsyncMethodCall { private AlterEdgeReq req; - public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler483, TAsyncClient client479, TProtocolFactory protocolFactory480, TNonblockingTransport transport481) throws TException { - super(client479, protocolFactory480, transport481, resultHandler483, false); + public alterEdge_call(AlterEdgeReq req, AsyncMethodCallback resultHandler489, TAsyncClient client485, TProtocolFactory protocolFactory486, TNonblockingTransport transport487) throws TException { + super(client485, protocolFactory486, transport487, resultHandler489, false); this.req = req; } @@ -4633,17 +4682,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler487) throws TException { + public void dropEdge(DropEdgeReq req, AsyncMethodCallback resultHandler493) throws TException { checkReady(); - dropEdge_call method_call = new dropEdge_call(req, resultHandler487, this, ___protocolFactory, ___transport); + dropEdge_call method_call = new dropEdge_call(req, resultHandler493, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdge_call extends TAsyncMethodCall { private DropEdgeReq req; - public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler488, TAsyncClient client484, TProtocolFactory protocolFactory485, TNonblockingTransport transport486) throws TException { - super(client484, protocolFactory485, transport486, resultHandler488, false); + public dropEdge_call(DropEdgeReq req, AsyncMethodCallback resultHandler494, TAsyncClient client490, TProtocolFactory protocolFactory491, TNonblockingTransport transport492) throws TException { + super(client490, protocolFactory491, transport492, resultHandler494, false); this.req = req; } @@ -4665,17 +4714,17 @@ public ExecResp getResult() throws TException { } } - public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler492) throws TException { + public void getEdge(GetEdgeReq req, AsyncMethodCallback resultHandler498) throws TException { checkReady(); - getEdge_call method_call = new getEdge_call(req, resultHandler492, this, ___protocolFactory, ___transport); + getEdge_call method_call = new getEdge_call(req, resultHandler498, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdge_call extends TAsyncMethodCall { private GetEdgeReq req; - public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler493, TAsyncClient client489, TProtocolFactory protocolFactory490, TNonblockingTransport transport491) throws TException { - super(client489, protocolFactory490, transport491, resultHandler493, false); + public getEdge_call(GetEdgeReq req, AsyncMethodCallback resultHandler499, TAsyncClient client495, TProtocolFactory protocolFactory496, TNonblockingTransport transport497) throws TException { + super(client495, protocolFactory496, transport497, resultHandler499, false); this.req = req; } @@ -4697,17 +4746,17 @@ public GetEdgeResp getResult() throws TException { } } - public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler497) throws TException { + public void listEdges(ListEdgesReq req, AsyncMethodCallback resultHandler503) throws TException { checkReady(); - listEdges_call method_call = new listEdges_call(req, resultHandler497, this, ___protocolFactory, ___transport); + listEdges_call method_call = new listEdges_call(req, resultHandler503, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdges_call extends TAsyncMethodCall { private ListEdgesReq req; - public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler498, TAsyncClient client494, TProtocolFactory protocolFactory495, TNonblockingTransport transport496) throws TException { - super(client494, protocolFactory495, transport496, resultHandler498, false); + public listEdges_call(ListEdgesReq req, AsyncMethodCallback resultHandler504, TAsyncClient client500, TProtocolFactory protocolFactory501, TNonblockingTransport transport502) throws TException { + super(client500, protocolFactory501, transport502, resultHandler504, false); this.req = req; } @@ -4729,17 +4778,17 @@ public ListEdgesResp getResult() throws TException { } } - public void addHosts(AddHostsReq req, AsyncMethodCallback resultHandler502) throws TException { + public void addHosts(AddHostsReq req, AsyncMethodCallback resultHandler508) throws TException { checkReady(); - addHosts_call method_call = new addHosts_call(req, resultHandler502, this, ___protocolFactory, ___transport); + addHosts_call method_call = new addHosts_call(req, resultHandler508, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addHosts_call extends TAsyncMethodCall { private AddHostsReq req; - public addHosts_call(AddHostsReq req, AsyncMethodCallback resultHandler503, TAsyncClient client499, TProtocolFactory protocolFactory500, TNonblockingTransport transport501) throws TException { - super(client499, protocolFactory500, transport501, resultHandler503, false); + public addHosts_call(AddHostsReq req, AsyncMethodCallback resultHandler509, TAsyncClient client505, TProtocolFactory protocolFactory506, TNonblockingTransport transport507) throws TException { + super(client505, protocolFactory506, transport507, resultHandler509, false); this.req = req; } @@ -4761,17 +4810,17 @@ public ExecResp getResult() throws TException { } } - public void addHostsIntoZone(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler507) throws TException { + public void addHostsIntoZone(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler513) throws TException { checkReady(); - addHostsIntoZone_call method_call = new addHostsIntoZone_call(req, resultHandler507, this, ___protocolFactory, ___transport); + addHostsIntoZone_call method_call = new addHostsIntoZone_call(req, resultHandler513, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addHostsIntoZone_call extends TAsyncMethodCall { private AddHostsIntoZoneReq req; - public addHostsIntoZone_call(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler508, TAsyncClient client504, TProtocolFactory protocolFactory505, TNonblockingTransport transport506) throws TException { - super(client504, protocolFactory505, transport506, resultHandler508, false); + public addHostsIntoZone_call(AddHostsIntoZoneReq req, AsyncMethodCallback resultHandler514, TAsyncClient client510, TProtocolFactory protocolFactory511, TNonblockingTransport transport512) throws TException { + super(client510, protocolFactory511, transport512, resultHandler514, false); this.req = req; } @@ -4793,17 +4842,17 @@ public ExecResp getResult() throws TException { } } - public void dropHosts(DropHostsReq req, AsyncMethodCallback resultHandler512) throws TException { + public void dropHosts(DropHostsReq req, AsyncMethodCallback resultHandler518) throws TException { checkReady(); - dropHosts_call method_call = new dropHosts_call(req, resultHandler512, this, ___protocolFactory, ___transport); + dropHosts_call method_call = new dropHosts_call(req, resultHandler518, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropHosts_call extends TAsyncMethodCall { private DropHostsReq req; - public dropHosts_call(DropHostsReq req, AsyncMethodCallback resultHandler513, TAsyncClient client509, TProtocolFactory protocolFactory510, TNonblockingTransport transport511) throws TException { - super(client509, protocolFactory510, transport511, resultHandler513, false); + public dropHosts_call(DropHostsReq req, AsyncMethodCallback resultHandler519, TAsyncClient client515, TProtocolFactory protocolFactory516, TNonblockingTransport transport517) throws TException { + super(client515, protocolFactory516, transport517, resultHandler519, false); this.req = req; } @@ -4825,17 +4874,17 @@ public ExecResp getResult() throws TException { } } - public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler517) throws TException { + public void listHosts(ListHostsReq req, AsyncMethodCallback resultHandler523) throws TException { checkReady(); - listHosts_call method_call = new listHosts_call(req, resultHandler517, this, ___protocolFactory, ___transport); + listHosts_call method_call = new listHosts_call(req, resultHandler523, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listHosts_call extends TAsyncMethodCall { private ListHostsReq req; - public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler518, TAsyncClient client514, TProtocolFactory protocolFactory515, TNonblockingTransport transport516) throws TException { - super(client514, protocolFactory515, transport516, resultHandler518, false); + public listHosts_call(ListHostsReq req, AsyncMethodCallback resultHandler524, TAsyncClient client520, TProtocolFactory protocolFactory521, TNonblockingTransport transport522) throws TException { + super(client520, protocolFactory521, transport522, resultHandler524, false); this.req = req; } @@ -4857,17 +4906,17 @@ public ListHostsResp getResult() throws TException { } } - public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler522) throws TException { + public void getPartsAlloc(GetPartsAllocReq req, AsyncMethodCallback resultHandler528) throws TException { checkReady(); - getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler522, this, ___protocolFactory, ___transport); + getPartsAlloc_call method_call = new getPartsAlloc_call(req, resultHandler528, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getPartsAlloc_call extends TAsyncMethodCall { private GetPartsAllocReq req; - public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler523, TAsyncClient client519, TProtocolFactory protocolFactory520, TNonblockingTransport transport521) throws TException { - super(client519, protocolFactory520, transport521, resultHandler523, false); + public getPartsAlloc_call(GetPartsAllocReq req, AsyncMethodCallback resultHandler529, TAsyncClient client525, TProtocolFactory protocolFactory526, TNonblockingTransport transport527) throws TException { + super(client525, protocolFactory526, transport527, resultHandler529, false); this.req = req; } @@ -4889,17 +4938,17 @@ public GetPartsAllocResp getResult() throws TException { } } - public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler527) throws TException { + public void listParts(ListPartsReq req, AsyncMethodCallback resultHandler533) throws TException { checkReady(); - listParts_call method_call = new listParts_call(req, resultHandler527, this, ___protocolFactory, ___transport); + listParts_call method_call = new listParts_call(req, resultHandler533, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listParts_call extends TAsyncMethodCall { private ListPartsReq req; - public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler528, TAsyncClient client524, TProtocolFactory protocolFactory525, TNonblockingTransport transport526) throws TException { - super(client524, protocolFactory525, transport526, resultHandler528, false); + public listParts_call(ListPartsReq req, AsyncMethodCallback resultHandler534, TAsyncClient client530, TProtocolFactory protocolFactory531, TNonblockingTransport transport532) throws TException { + super(client530, protocolFactory531, transport532, resultHandler534, false); this.req = req; } @@ -4921,17 +4970,17 @@ public ListPartsResp getResult() throws TException { } } - public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler532) throws TException { + public void multiPut(MultiPutReq req, AsyncMethodCallback resultHandler538) throws TException { checkReady(); - multiPut_call method_call = new multiPut_call(req, resultHandler532, this, ___protocolFactory, ___transport); + multiPut_call method_call = new multiPut_call(req, resultHandler538, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiPut_call extends TAsyncMethodCall { private MultiPutReq req; - public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler533, TAsyncClient client529, TProtocolFactory protocolFactory530, TNonblockingTransport transport531) throws TException { - super(client529, protocolFactory530, transport531, resultHandler533, false); + public multiPut_call(MultiPutReq req, AsyncMethodCallback resultHandler539, TAsyncClient client535, TProtocolFactory protocolFactory536, TNonblockingTransport transport537) throws TException { + super(client535, protocolFactory536, transport537, resultHandler539, false); this.req = req; } @@ -4953,17 +5002,17 @@ public ExecResp getResult() throws TException { } } - public void get(GetReq req, AsyncMethodCallback resultHandler537) throws TException { + public void get(GetReq req, AsyncMethodCallback resultHandler543) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler537, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler543, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private GetReq req; - public get_call(GetReq req, AsyncMethodCallback resultHandler538, TAsyncClient client534, TProtocolFactory protocolFactory535, TNonblockingTransport transport536) throws TException { - super(client534, protocolFactory535, transport536, resultHandler538, false); + public get_call(GetReq req, AsyncMethodCallback resultHandler544, TAsyncClient client540, TProtocolFactory protocolFactory541, TNonblockingTransport transport542) throws TException { + super(client540, protocolFactory541, transport542, resultHandler544, false); this.req = req; } @@ -4985,17 +5034,17 @@ public GetResp getResult() throws TException { } } - public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler542) throws TException { + public void multiGet(MultiGetReq req, AsyncMethodCallback resultHandler548) throws TException { checkReady(); - multiGet_call method_call = new multiGet_call(req, resultHandler542, this, ___protocolFactory, ___transport); + multiGet_call method_call = new multiGet_call(req, resultHandler548, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class multiGet_call extends TAsyncMethodCall { private MultiGetReq req; - public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler543, TAsyncClient client539, TProtocolFactory protocolFactory540, TNonblockingTransport transport541) throws TException { - super(client539, protocolFactory540, transport541, resultHandler543, false); + public multiGet_call(MultiGetReq req, AsyncMethodCallback resultHandler549, TAsyncClient client545, TProtocolFactory protocolFactory546, TNonblockingTransport transport547) throws TException { + super(client545, protocolFactory546, transport547, resultHandler549, false); this.req = req; } @@ -5017,17 +5066,17 @@ public MultiGetResp getResult() throws TException { } } - public void remove(RemoveReq req, AsyncMethodCallback resultHandler547) throws TException { + public void remove(RemoveReq req, AsyncMethodCallback resultHandler553) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler547, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler553, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private RemoveReq req; - public remove_call(RemoveReq req, AsyncMethodCallback resultHandler548, TAsyncClient client544, TProtocolFactory protocolFactory545, TNonblockingTransport transport546) throws TException { - super(client544, protocolFactory545, transport546, resultHandler548, false); + public remove_call(RemoveReq req, AsyncMethodCallback resultHandler554, TAsyncClient client550, TProtocolFactory protocolFactory551, TNonblockingTransport transport552) throws TException { + super(client550, protocolFactory551, transport552, resultHandler554, false); this.req = req; } @@ -5049,17 +5098,17 @@ public ExecResp getResult() throws TException { } } - public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler552) throws TException { + public void removeRange(RemoveRangeReq req, AsyncMethodCallback resultHandler558) throws TException { checkReady(); - removeRange_call method_call = new removeRange_call(req, resultHandler552, this, ___protocolFactory, ___transport); + removeRange_call method_call = new removeRange_call(req, resultHandler558, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeRange_call extends TAsyncMethodCall { private RemoveRangeReq req; - public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler553, TAsyncClient client549, TProtocolFactory protocolFactory550, TNonblockingTransport transport551) throws TException { - super(client549, protocolFactory550, transport551, resultHandler553, false); + public removeRange_call(RemoveRangeReq req, AsyncMethodCallback resultHandler559, TAsyncClient client555, TProtocolFactory protocolFactory556, TNonblockingTransport transport557) throws TException { + super(client555, protocolFactory556, transport557, resultHandler559, false); this.req = req; } @@ -5081,17 +5130,17 @@ public ExecResp getResult() throws TException { } } - public void scan(ScanReq req, AsyncMethodCallback resultHandler557) throws TException { + public void scan(ScanReq req, AsyncMethodCallback resultHandler563) throws TException { checkReady(); - scan_call method_call = new scan_call(req, resultHandler557, this, ___protocolFactory, ___transport); + scan_call method_call = new scan_call(req, resultHandler563, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scan_call extends TAsyncMethodCall { private ScanReq req; - public scan_call(ScanReq req, AsyncMethodCallback resultHandler558, TAsyncClient client554, TProtocolFactory protocolFactory555, TNonblockingTransport transport556) throws TException { - super(client554, protocolFactory555, transport556, resultHandler558, false); + public scan_call(ScanReq req, AsyncMethodCallback resultHandler564, TAsyncClient client560, TProtocolFactory protocolFactory561, TNonblockingTransport transport562) throws TException { + super(client560, protocolFactory561, transport562, resultHandler564, false); this.req = req; } @@ -5113,17 +5162,17 @@ public ScanResp getResult() throws TException { } } - public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler562) throws TException { + public void createTagIndex(CreateTagIndexReq req, AsyncMethodCallback resultHandler568) throws TException { checkReady(); - createTagIndex_call method_call = new createTagIndex_call(req, resultHandler562, this, ___protocolFactory, ___transport); + createTagIndex_call method_call = new createTagIndex_call(req, resultHandler568, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createTagIndex_call extends TAsyncMethodCall { private CreateTagIndexReq req; - public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler563, TAsyncClient client559, TProtocolFactory protocolFactory560, TNonblockingTransport transport561) throws TException { - super(client559, protocolFactory560, transport561, resultHandler563, false); + public createTagIndex_call(CreateTagIndexReq req, AsyncMethodCallback resultHandler569, TAsyncClient client565, TProtocolFactory protocolFactory566, TNonblockingTransport transport567) throws TException { + super(client565, protocolFactory566, transport567, resultHandler569, false); this.req = req; } @@ -5145,17 +5194,17 @@ public ExecResp getResult() throws TException { } } - public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler567) throws TException { + public void dropTagIndex(DropTagIndexReq req, AsyncMethodCallback resultHandler573) throws TException { checkReady(); - dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler567, this, ___protocolFactory, ___transport); + dropTagIndex_call method_call = new dropTagIndex_call(req, resultHandler573, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropTagIndex_call extends TAsyncMethodCall { private DropTagIndexReq req; - public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler568, TAsyncClient client564, TProtocolFactory protocolFactory565, TNonblockingTransport transport566) throws TException { - super(client564, protocolFactory565, transport566, resultHandler568, false); + public dropTagIndex_call(DropTagIndexReq req, AsyncMethodCallback resultHandler574, TAsyncClient client570, TProtocolFactory protocolFactory571, TNonblockingTransport transport572) throws TException { + super(client570, protocolFactory571, transport572, resultHandler574, false); this.req = req; } @@ -5177,17 +5226,17 @@ public ExecResp getResult() throws TException { } } - public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler572) throws TException { + public void getTagIndex(GetTagIndexReq req, AsyncMethodCallback resultHandler578) throws TException { checkReady(); - getTagIndex_call method_call = new getTagIndex_call(req, resultHandler572, this, ___protocolFactory, ___transport); + getTagIndex_call method_call = new getTagIndex_call(req, resultHandler578, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getTagIndex_call extends TAsyncMethodCall { private GetTagIndexReq req; - public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler573, TAsyncClient client569, TProtocolFactory protocolFactory570, TNonblockingTransport transport571) throws TException { - super(client569, protocolFactory570, transport571, resultHandler573, false); + public getTagIndex_call(GetTagIndexReq req, AsyncMethodCallback resultHandler579, TAsyncClient client575, TProtocolFactory protocolFactory576, TNonblockingTransport transport577) throws TException { + super(client575, protocolFactory576, transport577, resultHandler579, false); this.req = req; } @@ -5209,17 +5258,17 @@ public GetTagIndexResp getResult() throws TException { } } - public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler577) throws TException { + public void listTagIndexes(ListTagIndexesReq req, AsyncMethodCallback resultHandler583) throws TException { checkReady(); - listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler577, this, ___protocolFactory, ___transport); + listTagIndexes_call method_call = new listTagIndexes_call(req, resultHandler583, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexes_call extends TAsyncMethodCall { private ListTagIndexesReq req; - public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler578, TAsyncClient client574, TProtocolFactory protocolFactory575, TNonblockingTransport transport576) throws TException { - super(client574, protocolFactory575, transport576, resultHandler578, false); + public listTagIndexes_call(ListTagIndexesReq req, AsyncMethodCallback resultHandler584, TAsyncClient client580, TProtocolFactory protocolFactory581, TNonblockingTransport transport582) throws TException { + super(client580, protocolFactory581, transport582, resultHandler584, false); this.req = req; } @@ -5241,17 +5290,17 @@ public ListTagIndexesResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler582) throws TException { + public void rebuildTagIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler588) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler582, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler588, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler583, TAsyncClient client579, TProtocolFactory protocolFactory580, TNonblockingTransport transport581) throws TException { - super(client579, protocolFactory580, transport581, resultHandler583, false); + public rebuildTagIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler589, TAsyncClient client585, TProtocolFactory protocolFactory586, TNonblockingTransport transport587) throws TException { + super(client585, protocolFactory586, transport587, resultHandler589, false); this.req = req; } @@ -5273,17 +5322,17 @@ public ExecResp getResult() throws TException { } } - public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler587) throws TException { + public void listTagIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler593) throws TException { checkReady(); - listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler587, this, ___protocolFactory, ___transport); + listTagIndexStatus_call method_call = new listTagIndexStatus_call(req, resultHandler593, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listTagIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler588, TAsyncClient client584, TProtocolFactory protocolFactory585, TNonblockingTransport transport586) throws TException { - super(client584, protocolFactory585, transport586, resultHandler588, false); + public listTagIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler594, TAsyncClient client590, TProtocolFactory protocolFactory591, TNonblockingTransport transport592) throws TException { + super(client590, protocolFactory591, transport592, resultHandler594, false); this.req = req; } @@ -5305,17 +5354,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler592) throws TException { + public void createEdgeIndex(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler598) throws TException { checkReady(); - createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler592, this, ___protocolFactory, ___transport); + createEdgeIndex_call method_call = new createEdgeIndex_call(req, resultHandler598, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createEdgeIndex_call extends TAsyncMethodCall { private CreateEdgeIndexReq req; - public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler593, TAsyncClient client589, TProtocolFactory protocolFactory590, TNonblockingTransport transport591) throws TException { - super(client589, protocolFactory590, transport591, resultHandler593, false); + public createEdgeIndex_call(CreateEdgeIndexReq req, AsyncMethodCallback resultHandler599, TAsyncClient client595, TProtocolFactory protocolFactory596, TNonblockingTransport transport597) throws TException { + super(client595, protocolFactory596, transport597, resultHandler599, false); this.req = req; } @@ -5337,17 +5386,17 @@ public ExecResp getResult() throws TException { } } - public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler597) throws TException { + public void dropEdgeIndex(DropEdgeIndexReq req, AsyncMethodCallback resultHandler603) throws TException { checkReady(); - dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler597, this, ___protocolFactory, ___transport); + dropEdgeIndex_call method_call = new dropEdgeIndex_call(req, resultHandler603, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropEdgeIndex_call extends TAsyncMethodCall { private DropEdgeIndexReq req; - public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler598, TAsyncClient client594, TProtocolFactory protocolFactory595, TNonblockingTransport transport596) throws TException { - super(client594, protocolFactory595, transport596, resultHandler598, false); + public dropEdgeIndex_call(DropEdgeIndexReq req, AsyncMethodCallback resultHandler604, TAsyncClient client600, TProtocolFactory protocolFactory601, TNonblockingTransport transport602) throws TException { + super(client600, protocolFactory601, transport602, resultHandler604, false); this.req = req; } @@ -5369,17 +5418,17 @@ public ExecResp getResult() throws TException { } } - public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler602) throws TException { + public void getEdgeIndex(GetEdgeIndexReq req, AsyncMethodCallback resultHandler608) throws TException { checkReady(); - getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler602, this, ___protocolFactory, ___transport); + getEdgeIndex_call method_call = new getEdgeIndex_call(req, resultHandler608, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getEdgeIndex_call extends TAsyncMethodCall { private GetEdgeIndexReq req; - public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler603, TAsyncClient client599, TProtocolFactory protocolFactory600, TNonblockingTransport transport601) throws TException { - super(client599, protocolFactory600, transport601, resultHandler603, false); + public getEdgeIndex_call(GetEdgeIndexReq req, AsyncMethodCallback resultHandler609, TAsyncClient client605, TProtocolFactory protocolFactory606, TNonblockingTransport transport607) throws TException { + super(client605, protocolFactory606, transport607, resultHandler609, false); this.req = req; } @@ -5401,17 +5450,17 @@ public GetEdgeIndexResp getResult() throws TException { } } - public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler607) throws TException { + public void listEdgeIndexes(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler613) throws TException { checkReady(); - listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler607, this, ___protocolFactory, ___transport); + listEdgeIndexes_call method_call = new listEdgeIndexes_call(req, resultHandler613, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexes_call extends TAsyncMethodCall { private ListEdgeIndexesReq req; - public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler608, TAsyncClient client604, TProtocolFactory protocolFactory605, TNonblockingTransport transport606) throws TException { - super(client604, protocolFactory605, transport606, resultHandler608, false); + public listEdgeIndexes_call(ListEdgeIndexesReq req, AsyncMethodCallback resultHandler614, TAsyncClient client610, TProtocolFactory protocolFactory611, TNonblockingTransport transport612) throws TException { + super(client610, protocolFactory611, transport612, resultHandler614, false); this.req = req; } @@ -5433,17 +5482,17 @@ public ListEdgeIndexesResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler612) throws TException { + public void rebuildEdgeIndex(RebuildIndexReq req, AsyncMethodCallback resultHandler618) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler612, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler618, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexReq req; - public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler613, TAsyncClient client609, TProtocolFactory protocolFactory610, TNonblockingTransport transport611) throws TException { - super(client609, protocolFactory610, transport611, resultHandler613, false); + public rebuildEdgeIndex_call(RebuildIndexReq req, AsyncMethodCallback resultHandler619, TAsyncClient client615, TProtocolFactory protocolFactory616, TNonblockingTransport transport617) throws TException { + super(client615, protocolFactory616, transport617, resultHandler619, false); this.req = req; } @@ -5465,17 +5514,17 @@ public ExecResp getResult() throws TException { } } - public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler617) throws TException { + public void listEdgeIndexStatus(ListIndexStatusReq req, AsyncMethodCallback resultHandler623) throws TException { checkReady(); - listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler617, this, ___protocolFactory, ___transport); + listEdgeIndexStatus_call method_call = new listEdgeIndexStatus_call(req, resultHandler623, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listEdgeIndexStatus_call extends TAsyncMethodCall { private ListIndexStatusReq req; - public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler618, TAsyncClient client614, TProtocolFactory protocolFactory615, TNonblockingTransport transport616) throws TException { - super(client614, protocolFactory615, transport616, resultHandler618, false); + public listEdgeIndexStatus_call(ListIndexStatusReq req, AsyncMethodCallback resultHandler624, TAsyncClient client620, TProtocolFactory protocolFactory621, TNonblockingTransport transport622) throws TException { + super(client620, protocolFactory621, transport622, resultHandler624, false); this.req = req; } @@ -5497,17 +5546,17 @@ public ListIndexStatusResp getResult() throws TException { } } - public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler622) throws TException { + public void createUser(CreateUserReq req, AsyncMethodCallback resultHandler628) throws TException { checkReady(); - createUser_call method_call = new createUser_call(req, resultHandler622, this, ___protocolFactory, ___transport); + createUser_call method_call = new createUser_call(req, resultHandler628, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createUser_call extends TAsyncMethodCall { private CreateUserReq req; - public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler623, TAsyncClient client619, TProtocolFactory protocolFactory620, TNonblockingTransport transport621) throws TException { - super(client619, protocolFactory620, transport621, resultHandler623, false); + public createUser_call(CreateUserReq req, AsyncMethodCallback resultHandler629, TAsyncClient client625, TProtocolFactory protocolFactory626, TNonblockingTransport transport627) throws TException { + super(client625, protocolFactory626, transport627, resultHandler629, false); this.req = req; } @@ -5529,17 +5578,17 @@ public ExecResp getResult() throws TException { } } - public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler627) throws TException { + public void dropUser(DropUserReq req, AsyncMethodCallback resultHandler633) throws TException { checkReady(); - dropUser_call method_call = new dropUser_call(req, resultHandler627, this, ___protocolFactory, ___transport); + dropUser_call method_call = new dropUser_call(req, resultHandler633, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropUser_call extends TAsyncMethodCall { private DropUserReq req; - public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler628, TAsyncClient client624, TProtocolFactory protocolFactory625, TNonblockingTransport transport626) throws TException { - super(client624, protocolFactory625, transport626, resultHandler628, false); + public dropUser_call(DropUserReq req, AsyncMethodCallback resultHandler634, TAsyncClient client630, TProtocolFactory protocolFactory631, TNonblockingTransport transport632) throws TException { + super(client630, protocolFactory631, transport632, resultHandler634, false); this.req = req; } @@ -5561,17 +5610,17 @@ public ExecResp getResult() throws TException { } } - public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler632) throws TException { + public void alterUser(AlterUserReq req, AsyncMethodCallback resultHandler638) throws TException { checkReady(); - alterUser_call method_call = new alterUser_call(req, resultHandler632, this, ___protocolFactory, ___transport); + alterUser_call method_call = new alterUser_call(req, resultHandler638, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class alterUser_call extends TAsyncMethodCall { private AlterUserReq req; - public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler633, TAsyncClient client629, TProtocolFactory protocolFactory630, TNonblockingTransport transport631) throws TException { - super(client629, protocolFactory630, transport631, resultHandler633, false); + public alterUser_call(AlterUserReq req, AsyncMethodCallback resultHandler639, TAsyncClient client635, TProtocolFactory protocolFactory636, TNonblockingTransport transport637) throws TException { + super(client635, protocolFactory636, transport637, resultHandler639, false); this.req = req; } @@ -5593,17 +5642,17 @@ public ExecResp getResult() throws TException { } } - public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler637) throws TException { + public void grantRole(GrantRoleReq req, AsyncMethodCallback resultHandler643) throws TException { checkReady(); - grantRole_call method_call = new grantRole_call(req, resultHandler637, this, ___protocolFactory, ___transport); + grantRole_call method_call = new grantRole_call(req, resultHandler643, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class grantRole_call extends TAsyncMethodCall { private GrantRoleReq req; - public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler638, TAsyncClient client634, TProtocolFactory protocolFactory635, TNonblockingTransport transport636) throws TException { - super(client634, protocolFactory635, transport636, resultHandler638, false); + public grantRole_call(GrantRoleReq req, AsyncMethodCallback resultHandler644, TAsyncClient client640, TProtocolFactory protocolFactory641, TNonblockingTransport transport642) throws TException { + super(client640, protocolFactory641, transport642, resultHandler644, false); this.req = req; } @@ -5625,17 +5674,17 @@ public ExecResp getResult() throws TException { } } - public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler642) throws TException { + public void revokeRole(RevokeRoleReq req, AsyncMethodCallback resultHandler648) throws TException { checkReady(); - revokeRole_call method_call = new revokeRole_call(req, resultHandler642, this, ___protocolFactory, ___transport); + revokeRole_call method_call = new revokeRole_call(req, resultHandler648, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class revokeRole_call extends TAsyncMethodCall { private RevokeRoleReq req; - public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler643, TAsyncClient client639, TProtocolFactory protocolFactory640, TNonblockingTransport transport641) throws TException { - super(client639, protocolFactory640, transport641, resultHandler643, false); + public revokeRole_call(RevokeRoleReq req, AsyncMethodCallback resultHandler649, TAsyncClient client645, TProtocolFactory protocolFactory646, TNonblockingTransport transport647) throws TException { + super(client645, protocolFactory646, transport647, resultHandler649, false); this.req = req; } @@ -5657,17 +5706,17 @@ public ExecResp getResult() throws TException { } } - public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler647) throws TException { + public void listUsers(ListUsersReq req, AsyncMethodCallback resultHandler653) throws TException { checkReady(); - listUsers_call method_call = new listUsers_call(req, resultHandler647, this, ___protocolFactory, ___transport); + listUsers_call method_call = new listUsers_call(req, resultHandler653, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listUsers_call extends TAsyncMethodCall { private ListUsersReq req; - public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler648, TAsyncClient client644, TProtocolFactory protocolFactory645, TNonblockingTransport transport646) throws TException { - super(client644, protocolFactory645, transport646, resultHandler648, false); + public listUsers_call(ListUsersReq req, AsyncMethodCallback resultHandler654, TAsyncClient client650, TProtocolFactory protocolFactory651, TNonblockingTransport transport652) throws TException { + super(client650, protocolFactory651, transport652, resultHandler654, false); this.req = req; } @@ -5689,17 +5738,17 @@ public ListUsersResp getResult() throws TException { } } - public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler652) throws TException { + public void listRoles(ListRolesReq req, AsyncMethodCallback resultHandler658) throws TException { checkReady(); - listRoles_call method_call = new listRoles_call(req, resultHandler652, this, ___protocolFactory, ___transport); + listRoles_call method_call = new listRoles_call(req, resultHandler658, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listRoles_call extends TAsyncMethodCall { private ListRolesReq req; - public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler653, TAsyncClient client649, TProtocolFactory protocolFactory650, TNonblockingTransport transport651) throws TException { - super(client649, protocolFactory650, transport651, resultHandler653, false); + public listRoles_call(ListRolesReq req, AsyncMethodCallback resultHandler659, TAsyncClient client655, TProtocolFactory protocolFactory656, TNonblockingTransport transport657) throws TException { + super(client655, protocolFactory656, transport657, resultHandler659, false); this.req = req; } @@ -5721,17 +5770,17 @@ public ListRolesResp getResult() throws TException { } } - public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler657) throws TException { + public void getUserRoles(GetUserRolesReq req, AsyncMethodCallback resultHandler663) throws TException { checkReady(); - getUserRoles_call method_call = new getUserRoles_call(req, resultHandler657, this, ___protocolFactory, ___transport); + getUserRoles_call method_call = new getUserRoles_call(req, resultHandler663, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUserRoles_call extends TAsyncMethodCall { private GetUserRolesReq req; - public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler658, TAsyncClient client654, TProtocolFactory protocolFactory655, TNonblockingTransport transport656) throws TException { - super(client654, protocolFactory655, transport656, resultHandler658, false); + public getUserRoles_call(GetUserRolesReq req, AsyncMethodCallback resultHandler664, TAsyncClient client660, TProtocolFactory protocolFactory661, TNonblockingTransport transport662) throws TException { + super(client660, protocolFactory661, transport662, resultHandler664, false); this.req = req; } @@ -5753,17 +5802,17 @@ public ListRolesResp getResult() throws TException { } } - public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler662) throws TException { + public void changePassword(ChangePasswordReq req, AsyncMethodCallback resultHandler668) throws TException { checkReady(); - changePassword_call method_call = new changePassword_call(req, resultHandler662, this, ___protocolFactory, ___transport); + changePassword_call method_call = new changePassword_call(req, resultHandler668, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class changePassword_call extends TAsyncMethodCall { private ChangePasswordReq req; - public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler663, TAsyncClient client659, TProtocolFactory protocolFactory660, TNonblockingTransport transport661) throws TException { - super(client659, protocolFactory660, transport661, resultHandler663, false); + public changePassword_call(ChangePasswordReq req, AsyncMethodCallback resultHandler669, TAsyncClient client665, TProtocolFactory protocolFactory666, TNonblockingTransport transport667) throws TException { + super(client665, protocolFactory666, transport667, resultHandler669, false); this.req = req; } @@ -5785,17 +5834,17 @@ public ExecResp getResult() throws TException { } } - public void heartBeat(HBReq req, AsyncMethodCallback resultHandler667) throws TException { + public void heartBeat(HBReq req, AsyncMethodCallback resultHandler673) throws TException { checkReady(); - heartBeat_call method_call = new heartBeat_call(req, resultHandler667, this, ___protocolFactory, ___transport); + heartBeat_call method_call = new heartBeat_call(req, resultHandler673, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class heartBeat_call extends TAsyncMethodCall { private HBReq req; - public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler668, TAsyncClient client664, TProtocolFactory protocolFactory665, TNonblockingTransport transport666) throws TException { - super(client664, protocolFactory665, transport666, resultHandler668, false); + public heartBeat_call(HBReq req, AsyncMethodCallback resultHandler674, TAsyncClient client670, TProtocolFactory protocolFactory671, TNonblockingTransport transport672) throws TException { + super(client670, protocolFactory671, transport672, resultHandler674, false); this.req = req; } @@ -5817,17 +5866,49 @@ public HBResp getResult() throws TException { } } - public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler672) throws TException { + public void agentHeartbeat(AgentHBReq req, AsyncMethodCallback resultHandler678) throws TException { checkReady(); - regConfig_call method_call = new regConfig_call(req, resultHandler672, this, ___protocolFactory, ___transport); + agentHeartbeat_call method_call = new agentHeartbeat_call(req, resultHandler678, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class agentHeartbeat_call extends TAsyncMethodCall { + private AgentHBReq req; + public agentHeartbeat_call(AgentHBReq req, AsyncMethodCallback resultHandler679, TAsyncClient client675, TProtocolFactory protocolFactory676, TNonblockingTransport transport677) throws TException { + super(client675, protocolFactory676, transport677, resultHandler679, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("agentHeartbeat", TMessageType.CALL, 0)); + agentHeartbeat_args args = new agentHeartbeat_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public AgentHBResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_agentHeartbeat(); + } + } + + public void regConfig(RegConfigReq req, AsyncMethodCallback resultHandler683) throws TException { + checkReady(); + regConfig_call method_call = new regConfig_call(req, resultHandler683, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class regConfig_call extends TAsyncMethodCall { private RegConfigReq req; - public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler673, TAsyncClient client669, TProtocolFactory protocolFactory670, TNonblockingTransport transport671) throws TException { - super(client669, protocolFactory670, transport671, resultHandler673, false); + public regConfig_call(RegConfigReq req, AsyncMethodCallback resultHandler684, TAsyncClient client680, TProtocolFactory protocolFactory681, TNonblockingTransport transport682) throws TException { + super(client680, protocolFactory681, transport682, resultHandler684, false); this.req = req; } @@ -5849,17 +5930,17 @@ public ExecResp getResult() throws TException { } } - public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler677) throws TException { + public void getConfig(GetConfigReq req, AsyncMethodCallback resultHandler688) throws TException { checkReady(); - getConfig_call method_call = new getConfig_call(req, resultHandler677, this, ___protocolFactory, ___transport); + getConfig_call method_call = new getConfig_call(req, resultHandler688, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getConfig_call extends TAsyncMethodCall { private GetConfigReq req; - public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler678, TAsyncClient client674, TProtocolFactory protocolFactory675, TNonblockingTransport transport676) throws TException { - super(client674, protocolFactory675, transport676, resultHandler678, false); + public getConfig_call(GetConfigReq req, AsyncMethodCallback resultHandler689, TAsyncClient client685, TProtocolFactory protocolFactory686, TNonblockingTransport transport687) throws TException { + super(client685, protocolFactory686, transport687, resultHandler689, false); this.req = req; } @@ -5881,17 +5962,17 @@ public GetConfigResp getResult() throws TException { } } - public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler682) throws TException { + public void setConfig(SetConfigReq req, AsyncMethodCallback resultHandler693) throws TException { checkReady(); - setConfig_call method_call = new setConfig_call(req, resultHandler682, this, ___protocolFactory, ___transport); + setConfig_call method_call = new setConfig_call(req, resultHandler693, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class setConfig_call extends TAsyncMethodCall { private SetConfigReq req; - public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler683, TAsyncClient client679, TProtocolFactory protocolFactory680, TNonblockingTransport transport681) throws TException { - super(client679, protocolFactory680, transport681, resultHandler683, false); + public setConfig_call(SetConfigReq req, AsyncMethodCallback resultHandler694, TAsyncClient client690, TProtocolFactory protocolFactory691, TNonblockingTransport transport692) throws TException { + super(client690, protocolFactory691, transport692, resultHandler694, false); this.req = req; } @@ -5913,17 +5994,17 @@ public ExecResp getResult() throws TException { } } - public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler687) throws TException { + public void listConfigs(ListConfigsReq req, AsyncMethodCallback resultHandler698) throws TException { checkReady(); - listConfigs_call method_call = new listConfigs_call(req, resultHandler687, this, ___protocolFactory, ___transport); + listConfigs_call method_call = new listConfigs_call(req, resultHandler698, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listConfigs_call extends TAsyncMethodCall { private ListConfigsReq req; - public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler688, TAsyncClient client684, TProtocolFactory protocolFactory685, TNonblockingTransport transport686) throws TException { - super(client684, protocolFactory685, transport686, resultHandler688, false); + public listConfigs_call(ListConfigsReq req, AsyncMethodCallback resultHandler699, TAsyncClient client695, TProtocolFactory protocolFactory696, TNonblockingTransport transport697) throws TException { + super(client695, protocolFactory696, transport697, resultHandler699, false); this.req = req; } @@ -5945,17 +6026,17 @@ public ListConfigsResp getResult() throws TException { } } - public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler692) throws TException { + public void createSnapshot(CreateSnapshotReq req, AsyncMethodCallback resultHandler703) throws TException { checkReady(); - createSnapshot_call method_call = new createSnapshot_call(req, resultHandler692, this, ___protocolFactory, ___transport); + createSnapshot_call method_call = new createSnapshot_call(req, resultHandler703, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSnapshot_call extends TAsyncMethodCall { private CreateSnapshotReq req; - public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler693, TAsyncClient client689, TProtocolFactory protocolFactory690, TNonblockingTransport transport691) throws TException { - super(client689, protocolFactory690, transport691, resultHandler693, false); + public createSnapshot_call(CreateSnapshotReq req, AsyncMethodCallback resultHandler704, TAsyncClient client700, TProtocolFactory protocolFactory701, TNonblockingTransport transport702) throws TException { + super(client700, protocolFactory701, transport702, resultHandler704, false); this.req = req; } @@ -5977,17 +6058,17 @@ public ExecResp getResult() throws TException { } } - public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler697) throws TException { + public void dropSnapshot(DropSnapshotReq req, AsyncMethodCallback resultHandler708) throws TException { checkReady(); - dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler697, this, ___protocolFactory, ___transport); + dropSnapshot_call method_call = new dropSnapshot_call(req, resultHandler708, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropSnapshot_call extends TAsyncMethodCall { private DropSnapshotReq req; - public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler698, TAsyncClient client694, TProtocolFactory protocolFactory695, TNonblockingTransport transport696) throws TException { - super(client694, protocolFactory695, transport696, resultHandler698, false); + public dropSnapshot_call(DropSnapshotReq req, AsyncMethodCallback resultHandler709, TAsyncClient client705, TProtocolFactory protocolFactory706, TNonblockingTransport transport707) throws TException { + super(client705, protocolFactory706, transport707, resultHandler709, false); this.req = req; } @@ -6009,17 +6090,17 @@ public ExecResp getResult() throws TException { } } - public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler702) throws TException { + public void listSnapshots(ListSnapshotsReq req, AsyncMethodCallback resultHandler713) throws TException { checkReady(); - listSnapshots_call method_call = new listSnapshots_call(req, resultHandler702, this, ___protocolFactory, ___transport); + listSnapshots_call method_call = new listSnapshots_call(req, resultHandler713, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSnapshots_call extends TAsyncMethodCall { private ListSnapshotsReq req; - public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler703, TAsyncClient client699, TProtocolFactory protocolFactory700, TNonblockingTransport transport701) throws TException { - super(client699, protocolFactory700, transport701, resultHandler703, false); + public listSnapshots_call(ListSnapshotsReq req, AsyncMethodCallback resultHandler714, TAsyncClient client710, TProtocolFactory protocolFactory711, TNonblockingTransport transport712) throws TException { + super(client710, protocolFactory711, transport712, resultHandler714, false); this.req = req; } @@ -6041,17 +6122,17 @@ public ListSnapshotsResp getResult() throws TException { } } - public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler707) throws TException { + public void runAdminJob(AdminJobReq req, AsyncMethodCallback resultHandler718) throws TException { checkReady(); - runAdminJob_call method_call = new runAdminJob_call(req, resultHandler707, this, ___protocolFactory, ___transport); + runAdminJob_call method_call = new runAdminJob_call(req, resultHandler718, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class runAdminJob_call extends TAsyncMethodCall { private AdminJobReq req; - public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler708, TAsyncClient client704, TProtocolFactory protocolFactory705, TNonblockingTransport transport706) throws TException { - super(client704, protocolFactory705, transport706, resultHandler708, false); + public runAdminJob_call(AdminJobReq req, AsyncMethodCallback resultHandler719, TAsyncClient client715, TProtocolFactory protocolFactory716, TNonblockingTransport transport717) throws TException { + super(client715, protocolFactory716, transport717, resultHandler719, false); this.req = req; } @@ -6073,17 +6154,17 @@ public AdminJobResp getResult() throws TException { } } - public void mergeZone(MergeZoneReq req, AsyncMethodCallback resultHandler712) throws TException { + public void mergeZone(MergeZoneReq req, AsyncMethodCallback resultHandler723) throws TException { checkReady(); - mergeZone_call method_call = new mergeZone_call(req, resultHandler712, this, ___protocolFactory, ___transport); + mergeZone_call method_call = new mergeZone_call(req, resultHandler723, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class mergeZone_call extends TAsyncMethodCall { private MergeZoneReq req; - public mergeZone_call(MergeZoneReq req, AsyncMethodCallback resultHandler713, TAsyncClient client709, TProtocolFactory protocolFactory710, TNonblockingTransport transport711) throws TException { - super(client709, protocolFactory710, transport711, resultHandler713, false); + public mergeZone_call(MergeZoneReq req, AsyncMethodCallback resultHandler724, TAsyncClient client720, TProtocolFactory protocolFactory721, TNonblockingTransport transport722) throws TException { + super(client720, protocolFactory721, transport722, resultHandler724, false); this.req = req; } @@ -6105,17 +6186,17 @@ public ExecResp getResult() throws TException { } } - public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler717) throws TException { + public void dropZone(DropZoneReq req, AsyncMethodCallback resultHandler728) throws TException { checkReady(); - dropZone_call method_call = new dropZone_call(req, resultHandler717, this, ___protocolFactory, ___transport); + dropZone_call method_call = new dropZone_call(req, resultHandler728, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropZone_call extends TAsyncMethodCall { private DropZoneReq req; - public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler718, TAsyncClient client714, TProtocolFactory protocolFactory715, TNonblockingTransport transport716) throws TException { - super(client714, protocolFactory715, transport716, resultHandler718, false); + public dropZone_call(DropZoneReq req, AsyncMethodCallback resultHandler729, TAsyncClient client725, TProtocolFactory protocolFactory726, TNonblockingTransport transport727) throws TException { + super(client725, protocolFactory726, transport727, resultHandler729, false); this.req = req; } @@ -6137,17 +6218,17 @@ public ExecResp getResult() throws TException { } } - public void splitZone(SplitZoneReq req, AsyncMethodCallback resultHandler722) throws TException { + public void splitZone(SplitZoneReq req, AsyncMethodCallback resultHandler733) throws TException { checkReady(); - splitZone_call method_call = new splitZone_call(req, resultHandler722, this, ___protocolFactory, ___transport); + splitZone_call method_call = new splitZone_call(req, resultHandler733, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class splitZone_call extends TAsyncMethodCall { private SplitZoneReq req; - public splitZone_call(SplitZoneReq req, AsyncMethodCallback resultHandler723, TAsyncClient client719, TProtocolFactory protocolFactory720, TNonblockingTransport transport721) throws TException { - super(client719, protocolFactory720, transport721, resultHandler723, false); + public splitZone_call(SplitZoneReq req, AsyncMethodCallback resultHandler734, TAsyncClient client730, TProtocolFactory protocolFactory731, TNonblockingTransport transport732) throws TException { + super(client730, protocolFactory731, transport732, resultHandler734, false); this.req = req; } @@ -6169,17 +6250,17 @@ public ExecResp getResult() throws TException { } } - public void renameZone(RenameZoneReq req, AsyncMethodCallback resultHandler727) throws TException { + public void renameZone(RenameZoneReq req, AsyncMethodCallback resultHandler738) throws TException { checkReady(); - renameZone_call method_call = new renameZone_call(req, resultHandler727, this, ___protocolFactory, ___transport); + renameZone_call method_call = new renameZone_call(req, resultHandler738, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class renameZone_call extends TAsyncMethodCall { private RenameZoneReq req; - public renameZone_call(RenameZoneReq req, AsyncMethodCallback resultHandler728, TAsyncClient client724, TProtocolFactory protocolFactory725, TNonblockingTransport transport726) throws TException { - super(client724, protocolFactory725, transport726, resultHandler728, false); + public renameZone_call(RenameZoneReq req, AsyncMethodCallback resultHandler739, TAsyncClient client735, TProtocolFactory protocolFactory736, TNonblockingTransport transport737) throws TException { + super(client735, protocolFactory736, transport737, resultHandler739, false); this.req = req; } @@ -6201,17 +6282,17 @@ public ExecResp getResult() throws TException { } } - public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler732) throws TException { + public void getZone(GetZoneReq req, AsyncMethodCallback resultHandler743) throws TException { checkReady(); - getZone_call method_call = new getZone_call(req, resultHandler732, this, ___protocolFactory, ___transport); + getZone_call method_call = new getZone_call(req, resultHandler743, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getZone_call extends TAsyncMethodCall { private GetZoneReq req; - public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler733, TAsyncClient client729, TProtocolFactory protocolFactory730, TNonblockingTransport transport731) throws TException { - super(client729, protocolFactory730, transport731, resultHandler733, false); + public getZone_call(GetZoneReq req, AsyncMethodCallback resultHandler744, TAsyncClient client740, TProtocolFactory protocolFactory741, TNonblockingTransport transport742) throws TException { + super(client740, protocolFactory741, transport742, resultHandler744, false); this.req = req; } @@ -6233,17 +6314,17 @@ public GetZoneResp getResult() throws TException { } } - public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler737) throws TException { + public void listZones(ListZonesReq req, AsyncMethodCallback resultHandler748) throws TException { checkReady(); - listZones_call method_call = new listZones_call(req, resultHandler737, this, ___protocolFactory, ___transport); + listZones_call method_call = new listZones_call(req, resultHandler748, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listZones_call extends TAsyncMethodCall { private ListZonesReq req; - public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler738, TAsyncClient client734, TProtocolFactory protocolFactory735, TNonblockingTransport transport736) throws TException { - super(client734, protocolFactory735, transport736, resultHandler738, false); + public listZones_call(ListZonesReq req, AsyncMethodCallback resultHandler749, TAsyncClient client745, TProtocolFactory protocolFactory746, TNonblockingTransport transport747) throws TException { + super(client745, protocolFactory746, transport747, resultHandler749, false); this.req = req; } @@ -6265,81 +6346,17 @@ public ListZonesResp getResult() throws TException { } } - public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler742) throws TException { - checkReady(); - createBackup_call method_call = new createBackup_call(req, resultHandler742, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class createBackup_call extends TAsyncMethodCall { - private CreateBackupReq req; - public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler743, TAsyncClient client739, TProtocolFactory protocolFactory740, TNonblockingTransport transport741) throws TException { - super(client739, protocolFactory740, transport741, resultHandler743, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("createBackup", TMessageType.CALL, 0)); - createBackup_args args = new createBackup_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public CreateBackupResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_createBackup(); - } - } - - public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler747) throws TException { - checkReady(); - restoreMeta_call method_call = new restoreMeta_call(req, resultHandler747, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class restoreMeta_call extends TAsyncMethodCall { - private RestoreMetaReq req; - public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler748, TAsyncClient client744, TProtocolFactory protocolFactory745, TNonblockingTransport transport746) throws TException { - super(client744, protocolFactory745, transport746, resultHandler748, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("restoreMeta", TMessageType.CALL, 0)); - restoreMeta_args args = new restoreMeta_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_restoreMeta(); - } - } - - public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler752) throws TException { + public void addListener(AddListenerReq req, AsyncMethodCallback resultHandler753) throws TException { checkReady(); - addListener_call method_call = new addListener_call(req, resultHandler752, this, ___protocolFactory, ___transport); + addListener_call method_call = new addListener_call(req, resultHandler753, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addListener_call extends TAsyncMethodCall { private AddListenerReq req; - public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler753, TAsyncClient client749, TProtocolFactory protocolFactory750, TNonblockingTransport transport751) throws TException { - super(client749, protocolFactory750, transport751, resultHandler753, false); + public addListener_call(AddListenerReq req, AsyncMethodCallback resultHandler754, TAsyncClient client750, TProtocolFactory protocolFactory751, TNonblockingTransport transport752) throws TException { + super(client750, protocolFactory751, transport752, resultHandler754, false); this.req = req; } @@ -6361,17 +6378,17 @@ public ExecResp getResult() throws TException { } } - public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler757) throws TException { + public void removeListener(RemoveListenerReq req, AsyncMethodCallback resultHandler758) throws TException { checkReady(); - removeListener_call method_call = new removeListener_call(req, resultHandler757, this, ___protocolFactory, ___transport); + removeListener_call method_call = new removeListener_call(req, resultHandler758, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeListener_call extends TAsyncMethodCall { private RemoveListenerReq req; - public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler758, TAsyncClient client754, TProtocolFactory protocolFactory755, TNonblockingTransport transport756) throws TException { - super(client754, protocolFactory755, transport756, resultHandler758, false); + public removeListener_call(RemoveListenerReq req, AsyncMethodCallback resultHandler759, TAsyncClient client755, TProtocolFactory protocolFactory756, TNonblockingTransport transport757) throws TException { + super(client755, protocolFactory756, transport757, resultHandler759, false); this.req = req; } @@ -6393,17 +6410,17 @@ public ExecResp getResult() throws TException { } } - public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler762) throws TException { + public void listListener(ListListenerReq req, AsyncMethodCallback resultHandler763) throws TException { checkReady(); - listListener_call method_call = new listListener_call(req, resultHandler762, this, ___protocolFactory, ___transport); + listListener_call method_call = new listListener_call(req, resultHandler763, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listListener_call extends TAsyncMethodCall { private ListListenerReq req; - public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler763, TAsyncClient client759, TProtocolFactory protocolFactory760, TNonblockingTransport transport761) throws TException { - super(client759, protocolFactory760, transport761, resultHandler763, false); + public listListener_call(ListListenerReq req, AsyncMethodCallback resultHandler764, TAsyncClient client760, TProtocolFactory protocolFactory761, TNonblockingTransport transport762) throws TException { + super(client760, protocolFactory761, transport762, resultHandler764, false); this.req = req; } @@ -6425,17 +6442,17 @@ public ListListenerResp getResult() throws TException { } } - public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler767) throws TException { + public void getStats(GetStatsReq req, AsyncMethodCallback resultHandler768) throws TException { checkReady(); - getStats_call method_call = new getStats_call(req, resultHandler767, this, ___protocolFactory, ___transport); + getStats_call method_call = new getStats_call(req, resultHandler768, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getStats_call extends TAsyncMethodCall { private GetStatsReq req; - public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler768, TAsyncClient client764, TProtocolFactory protocolFactory765, TNonblockingTransport transport766) throws TException { - super(client764, protocolFactory765, transport766, resultHandler768, false); + public getStats_call(GetStatsReq req, AsyncMethodCallback resultHandler769, TAsyncClient client765, TProtocolFactory protocolFactory766, TNonblockingTransport transport767) throws TException { + super(client765, protocolFactory766, transport767, resultHandler769, false); this.req = req; } @@ -6457,17 +6474,17 @@ public GetStatsResp getResult() throws TException { } } - public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler772) throws TException { + public void signInFTService(SignInFTServiceReq req, AsyncMethodCallback resultHandler773) throws TException { checkReady(); - signInFTService_call method_call = new signInFTService_call(req, resultHandler772, this, ___protocolFactory, ___transport); + signInFTService_call method_call = new signInFTService_call(req, resultHandler773, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signInFTService_call extends TAsyncMethodCall { private SignInFTServiceReq req; - public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler773, TAsyncClient client769, TProtocolFactory protocolFactory770, TNonblockingTransport transport771) throws TException { - super(client769, protocolFactory770, transport771, resultHandler773, false); + public signInFTService_call(SignInFTServiceReq req, AsyncMethodCallback resultHandler774, TAsyncClient client770, TProtocolFactory protocolFactory771, TNonblockingTransport transport772) throws TException { + super(client770, protocolFactory771, transport772, resultHandler774, false); this.req = req; } @@ -6489,17 +6506,17 @@ public ExecResp getResult() throws TException { } } - public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler777) throws TException { + public void signOutFTService(SignOutFTServiceReq req, AsyncMethodCallback resultHandler778) throws TException { checkReady(); - signOutFTService_call method_call = new signOutFTService_call(req, resultHandler777, this, ___protocolFactory, ___transport); + signOutFTService_call method_call = new signOutFTService_call(req, resultHandler778, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class signOutFTService_call extends TAsyncMethodCall { private SignOutFTServiceReq req; - public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler778, TAsyncClient client774, TProtocolFactory protocolFactory775, TNonblockingTransport transport776) throws TException { - super(client774, protocolFactory775, transport776, resultHandler778, false); + public signOutFTService_call(SignOutFTServiceReq req, AsyncMethodCallback resultHandler779, TAsyncClient client775, TProtocolFactory protocolFactory776, TNonblockingTransport transport777) throws TException { + super(client775, protocolFactory776, transport777, resultHandler779, false); this.req = req; } @@ -6521,17 +6538,17 @@ public ExecResp getResult() throws TException { } } - public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler782) throws TException { + public void listFTClients(ListFTClientsReq req, AsyncMethodCallback resultHandler783) throws TException { checkReady(); - listFTClients_call method_call = new listFTClients_call(req, resultHandler782, this, ___protocolFactory, ___transport); + listFTClients_call method_call = new listFTClients_call(req, resultHandler783, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTClients_call extends TAsyncMethodCall { private ListFTClientsReq req; - public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler783, TAsyncClient client779, TProtocolFactory protocolFactory780, TNonblockingTransport transport781) throws TException { - super(client779, protocolFactory780, transport781, resultHandler783, false); + public listFTClients_call(ListFTClientsReq req, AsyncMethodCallback resultHandler784, TAsyncClient client780, TProtocolFactory protocolFactory781, TNonblockingTransport transport782) throws TException { + super(client780, protocolFactory781, transport782, resultHandler784, false); this.req = req; } @@ -6553,17 +6570,17 @@ public ListFTClientsResp getResult() throws TException { } } - public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler787) throws TException { + public void createFTIndex(CreateFTIndexReq req, AsyncMethodCallback resultHandler788) throws TException { checkReady(); - createFTIndex_call method_call = new createFTIndex_call(req, resultHandler787, this, ___protocolFactory, ___transport); + createFTIndex_call method_call = new createFTIndex_call(req, resultHandler788, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createFTIndex_call extends TAsyncMethodCall { private CreateFTIndexReq req; - public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler788, TAsyncClient client784, TProtocolFactory protocolFactory785, TNonblockingTransport transport786) throws TException { - super(client784, protocolFactory785, transport786, resultHandler788, false); + public createFTIndex_call(CreateFTIndexReq req, AsyncMethodCallback resultHandler789, TAsyncClient client785, TProtocolFactory protocolFactory786, TNonblockingTransport transport787) throws TException { + super(client785, protocolFactory786, transport787, resultHandler789, false); this.req = req; } @@ -6585,17 +6602,17 @@ public ExecResp getResult() throws TException { } } - public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler792) throws TException { + public void dropFTIndex(DropFTIndexReq req, AsyncMethodCallback resultHandler793) throws TException { checkReady(); - dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler792, this, ___protocolFactory, ___transport); + dropFTIndex_call method_call = new dropFTIndex_call(req, resultHandler793, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropFTIndex_call extends TAsyncMethodCall { private DropFTIndexReq req; - public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler793, TAsyncClient client789, TProtocolFactory protocolFactory790, TNonblockingTransport transport791) throws TException { - super(client789, protocolFactory790, transport791, resultHandler793, false); + public dropFTIndex_call(DropFTIndexReq req, AsyncMethodCallback resultHandler794, TAsyncClient client790, TProtocolFactory protocolFactory791, TNonblockingTransport transport792) throws TException { + super(client790, protocolFactory791, transport792, resultHandler794, false); this.req = req; } @@ -6617,17 +6634,17 @@ public ExecResp getResult() throws TException { } } - public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler797) throws TException { + public void listFTIndexes(ListFTIndexesReq req, AsyncMethodCallback resultHandler798) throws TException { checkReady(); - listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler797, this, ___protocolFactory, ___transport); + listFTIndexes_call method_call = new listFTIndexes_call(req, resultHandler798, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listFTIndexes_call extends TAsyncMethodCall { private ListFTIndexesReq req; - public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler798, TAsyncClient client794, TProtocolFactory protocolFactory795, TNonblockingTransport transport796) throws TException { - super(client794, protocolFactory795, transport796, resultHandler798, false); + public listFTIndexes_call(ListFTIndexesReq req, AsyncMethodCallback resultHandler799, TAsyncClient client795, TProtocolFactory protocolFactory796, TNonblockingTransport transport797) throws TException { + super(client795, protocolFactory796, transport797, resultHandler799, false); this.req = req; } @@ -6649,17 +6666,17 @@ public ListFTIndexesResp getResult() throws TException { } } - public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler802) throws TException { + public void createSession(CreateSessionReq req, AsyncMethodCallback resultHandler803) throws TException { checkReady(); - createSession_call method_call = new createSession_call(req, resultHandler802, this, ___protocolFactory, ___transport); + createSession_call method_call = new createSession_call(req, resultHandler803, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createSession_call extends TAsyncMethodCall { private CreateSessionReq req; - public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler803, TAsyncClient client799, TProtocolFactory protocolFactory800, TNonblockingTransport transport801) throws TException { - super(client799, protocolFactory800, transport801, resultHandler803, false); + public createSession_call(CreateSessionReq req, AsyncMethodCallback resultHandler804, TAsyncClient client800, TProtocolFactory protocolFactory801, TNonblockingTransport transport802) throws TException { + super(client800, protocolFactory801, transport802, resultHandler804, false); this.req = req; } @@ -6681,17 +6698,17 @@ public CreateSessionResp getResult() throws TException { } } - public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler807) throws TException { + public void updateSessions(UpdateSessionsReq req, AsyncMethodCallback resultHandler808) throws TException { checkReady(); - updateSessions_call method_call = new updateSessions_call(req, resultHandler807, this, ___protocolFactory, ___transport); + updateSessions_call method_call = new updateSessions_call(req, resultHandler808, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateSessions_call extends TAsyncMethodCall { private UpdateSessionsReq req; - public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler808, TAsyncClient client804, TProtocolFactory protocolFactory805, TNonblockingTransport transport806) throws TException { - super(client804, protocolFactory805, transport806, resultHandler808, false); + public updateSessions_call(UpdateSessionsReq req, AsyncMethodCallback resultHandler809, TAsyncClient client805, TProtocolFactory protocolFactory806, TNonblockingTransport transport807) throws TException { + super(client805, protocolFactory806, transport807, resultHandler809, false); this.req = req; } @@ -6713,17 +6730,17 @@ public UpdateSessionsResp getResult() throws TException { } } - public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler812) throws TException { + public void listSessions(ListSessionsReq req, AsyncMethodCallback resultHandler813) throws TException { checkReady(); - listSessions_call method_call = new listSessions_call(req, resultHandler812, this, ___protocolFactory, ___transport); + listSessions_call method_call = new listSessions_call(req, resultHandler813, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listSessions_call extends TAsyncMethodCall { private ListSessionsReq req; - public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler813, TAsyncClient client809, TProtocolFactory protocolFactory810, TNonblockingTransport transport811) throws TException { - super(client809, protocolFactory810, transport811, resultHandler813, false); + public listSessions_call(ListSessionsReq req, AsyncMethodCallback resultHandler814, TAsyncClient client810, TProtocolFactory protocolFactory811, TNonblockingTransport transport812) throws TException { + super(client810, protocolFactory811, transport812, resultHandler814, false); this.req = req; } @@ -6745,17 +6762,17 @@ public ListSessionsResp getResult() throws TException { } } - public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler817) throws TException { + public void getSession(GetSessionReq req, AsyncMethodCallback resultHandler818) throws TException { checkReady(); - getSession_call method_call = new getSession_call(req, resultHandler817, this, ___protocolFactory, ___transport); + getSession_call method_call = new getSession_call(req, resultHandler818, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getSession_call extends TAsyncMethodCall { private GetSessionReq req; - public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler818, TAsyncClient client814, TProtocolFactory protocolFactory815, TNonblockingTransport transport816) throws TException { - super(client814, protocolFactory815, transport816, resultHandler818, false); + public getSession_call(GetSessionReq req, AsyncMethodCallback resultHandler819, TAsyncClient client815, TProtocolFactory protocolFactory816, TNonblockingTransport transport817) throws TException { + super(client815, protocolFactory816, transport817, resultHandler819, false); this.req = req; } @@ -6777,17 +6794,17 @@ public GetSessionResp getResult() throws TException { } } - public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler822) throws TException { + public void removeSession(RemoveSessionReq req, AsyncMethodCallback resultHandler823) throws TException { checkReady(); - removeSession_call method_call = new removeSession_call(req, resultHandler822, this, ___protocolFactory, ___transport); + removeSession_call method_call = new removeSession_call(req, resultHandler823, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removeSession_call extends TAsyncMethodCall { private RemoveSessionReq req; - public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler823, TAsyncClient client819, TProtocolFactory protocolFactory820, TNonblockingTransport transport821) throws TException { - super(client819, protocolFactory820, transport821, resultHandler823, false); + public removeSession_call(RemoveSessionReq req, AsyncMethodCallback resultHandler824, TAsyncClient client820, TProtocolFactory protocolFactory821, TNonblockingTransport transport822) throws TException { + super(client820, protocolFactory821, transport822, resultHandler824, false); this.req = req; } @@ -6809,17 +6826,17 @@ public ExecResp getResult() throws TException { } } - public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler827) throws TException { + public void killQuery(KillQueryReq req, AsyncMethodCallback resultHandler828) throws TException { checkReady(); - killQuery_call method_call = new killQuery_call(req, resultHandler827, this, ___protocolFactory, ___transport); + killQuery_call method_call = new killQuery_call(req, resultHandler828, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class killQuery_call extends TAsyncMethodCall { private KillQueryReq req; - public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler828, TAsyncClient client824, TProtocolFactory protocolFactory825, TNonblockingTransport transport826) throws TException { - super(client824, protocolFactory825, transport826, resultHandler828, false); + public killQuery_call(KillQueryReq req, AsyncMethodCallback resultHandler829, TAsyncClient client825, TProtocolFactory protocolFactory826, TNonblockingTransport transport827) throws TException { + super(client825, protocolFactory826, transport827, resultHandler829, false); this.req = req; } @@ -6841,17 +6858,17 @@ public ExecResp getResult() throws TException { } } - public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler832) throws TException { + public void reportTaskFinish(ReportTaskReq req, AsyncMethodCallback resultHandler833) throws TException { checkReady(); - reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler832, this, ___protocolFactory, ___transport); + reportTaskFinish_call method_call = new reportTaskFinish_call(req, resultHandler833, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class reportTaskFinish_call extends TAsyncMethodCall { private ReportTaskReq req; - public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler833, TAsyncClient client829, TProtocolFactory protocolFactory830, TNonblockingTransport transport831) throws TException { - super(client829, protocolFactory830, transport831, resultHandler833, false); + public reportTaskFinish_call(ReportTaskReq req, AsyncMethodCallback resultHandler834, TAsyncClient client830, TProtocolFactory protocolFactory831, TNonblockingTransport transport832) throws TException { + super(client830, protocolFactory831, transport832, resultHandler834, false); this.req = req; } @@ -6873,17 +6890,81 @@ public ExecResp getResult() throws TException { } } - public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler837) throws TException { + public void createBackup(CreateBackupReq req, AsyncMethodCallback resultHandler838) throws TException { checkReady(); - listCluster_call method_call = new listCluster_call(req, resultHandler837, this, ___protocolFactory, ___transport); + createBackup_call method_call = new createBackup_call(req, resultHandler838, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class createBackup_call extends TAsyncMethodCall { + private CreateBackupReq req; + public createBackup_call(CreateBackupReq req, AsyncMethodCallback resultHandler839, TAsyncClient client835, TProtocolFactory protocolFactory836, TNonblockingTransport transport837) throws TException { + super(client835, protocolFactory836, transport837, resultHandler839, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("createBackup", TMessageType.CALL, 0)); + createBackup_args args = new createBackup_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public CreateBackupResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_createBackup(); + } + } + + public void restoreMeta(RestoreMetaReq req, AsyncMethodCallback resultHandler843) throws TException { + checkReady(); + restoreMeta_call method_call = new restoreMeta_call(req, resultHandler843, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class restoreMeta_call extends TAsyncMethodCall { + private RestoreMetaReq req; + public restoreMeta_call(RestoreMetaReq req, AsyncMethodCallback resultHandler844, TAsyncClient client840, TProtocolFactory protocolFactory841, TNonblockingTransport transport842) throws TException { + super(client840, protocolFactory841, transport842, resultHandler844, false); + this.req = req; + } + + public void write_args(TProtocol prot) throws TException { + prot.writeMessageBegin(new TMessage("restoreMeta", TMessageType.CALL, 0)); + restoreMeta_args args = new restoreMeta_args(); + args.setReq(req); + args.write(prot); + prot.writeMessageEnd(); + } + + public ExecResp getResult() throws TException { + if (getState() != State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); + TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_restoreMeta(); + } + } + + public void listCluster(ListClusterInfoReq req, AsyncMethodCallback resultHandler848) throws TException { + checkReady(); + listCluster_call method_call = new listCluster_call(req, resultHandler848, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class listCluster_call extends TAsyncMethodCall { private ListClusterInfoReq req; - public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler838, TAsyncClient client834, TProtocolFactory protocolFactory835, TNonblockingTransport transport836) throws TException { - super(client834, protocolFactory835, transport836, resultHandler838, false); + public listCluster_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler849, TAsyncClient client845, TProtocolFactory protocolFactory846, TNonblockingTransport transport847) throws TException { + super(client845, protocolFactory846, transport847, resultHandler849, false); this.req = req; } @@ -6905,17 +6986,17 @@ public ListClusterInfoResp getResult() throws TException { } } - public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler842) throws TException { + public void getMetaDirInfo(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler853) throws TException { checkReady(); - getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler842, this, ___protocolFactory, ___transport); + getMetaDirInfo_call method_call = new getMetaDirInfo_call(req, resultHandler853, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getMetaDirInfo_call extends TAsyncMethodCall { private GetMetaDirInfoReq req; - public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler843, TAsyncClient client839, TProtocolFactory protocolFactory840, TNonblockingTransport transport841) throws TException { - super(client839, protocolFactory840, transport841, resultHandler843, false); + public getMetaDirInfo_call(GetMetaDirInfoReq req, AsyncMethodCallback resultHandler854, TAsyncClient client850, TProtocolFactory protocolFactory851, TNonblockingTransport transport852) throws TException { + super(client850, protocolFactory851, transport852, resultHandler854, false); this.req = req; } @@ -6937,17 +7018,17 @@ public GetMetaDirInfoResp getResult() throws TException { } } - public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler847) throws TException { + public void verifyClientVersion(VerifyClientVersionReq req, AsyncMethodCallback resultHandler858) throws TException { checkReady(); - verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler847, this, ___protocolFactory, ___transport); + verifyClientVersion_call method_call = new verifyClientVersion_call(req, resultHandler858, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class verifyClientVersion_call extends TAsyncMethodCall { private VerifyClientVersionReq req; - public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler848, TAsyncClient client844, TProtocolFactory protocolFactory845, TNonblockingTransport transport846) throws TException { - super(client844, protocolFactory845, transport846, resultHandler848, false); + public verifyClientVersion_call(VerifyClientVersionReq req, AsyncMethodCallback resultHandler859, TAsyncClient client855, TProtocolFactory protocolFactory856, TNonblockingTransport transport857) throws TException { + super(client855, protocolFactory856, transport857, resultHandler859, false); this.req = req; } @@ -7026,6 +7107,7 @@ public Processor(Iface iface) processMap_.put("getUserRoles", new getUserRoles()); processMap_.put("changePassword", new changePassword()); processMap_.put("heartBeat", new heartBeat()); + processMap_.put("agentHeartbeat", new agentHeartbeat()); processMap_.put("regConfig", new regConfig()); processMap_.put("getConfig", new getConfig()); processMap_.put("setConfig", new setConfig()); @@ -7040,8 +7122,6 @@ public Processor(Iface iface) processMap_.put("renameZone", new renameZone()); processMap_.put("getZone", new getZone()); processMap_.put("listZones", new listZones()); - processMap_.put("createBackup", new createBackup()); - processMap_.put("restoreMeta", new restoreMeta()); processMap_.put("addListener", new addListener()); processMap_.put("removeListener", new removeListener()); processMap_.put("listListener", new listListener()); @@ -7059,6 +7139,8 @@ public Processor(Iface iface) processMap_.put("removeSession", new removeSession()); processMap_.put("killQuery", new killQuery()); processMap_.put("reportTaskFinish", new reportTaskFinish()); + processMap_.put("createBackup", new createBackup()); + processMap_.put("restoreMeta", new restoreMeta()); processMap_.put("listCluster", new listCluster()); processMap_.put("getMetaDirInfo", new getMetaDirInfo()); processMap_.put("verifyClientVersion", new verifyClientVersion()); @@ -8123,6 +8205,27 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class agentHeartbeat implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.agentHeartbeat", server_ctx); + agentHeartbeat_args args = new agentHeartbeat_args(); + event_handler_.preRead(handler_ctx, "MetaService.agentHeartbeat"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.agentHeartbeat", args); + agentHeartbeat_result result = new agentHeartbeat_result(); + result.success = iface_.agentHeartbeat(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.agentHeartbeat", result); + oprot.writeMessageBegin(new TMessage("agentHeartbeat", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.agentHeartbeat", result); + } + + } + private class regConfig implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -8417,48 +8520,6 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class createBackup implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.createBackup", server_ctx); - createBackup_args args = new createBackup_args(); - event_handler_.preRead(handler_ctx, "MetaService.createBackup"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.createBackup", args); - createBackup_result result = new createBackup_result(); - result.success = iface_.createBackup(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.createBackup", result); - oprot.writeMessageBegin(new TMessage("createBackup", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.createBackup", result); - } - - } - - private class restoreMeta implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("MetaService.restoreMeta", server_ctx); - restoreMeta_args args = new restoreMeta_args(); - event_handler_.preRead(handler_ctx, "MetaService.restoreMeta"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "MetaService.restoreMeta", args); - restoreMeta_result result = new restoreMeta_result(); - result.success = iface_.restoreMeta(args.req); - event_handler_.preWrite(handler_ctx, "MetaService.restoreMeta", result); - oprot.writeMessageBegin(new TMessage("restoreMeta", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "MetaService.restoreMeta", result); - } - - } - private class addListener implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -8816,6 +8877,48 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } + private class createBackup implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.createBackup", server_ctx); + createBackup_args args = new createBackup_args(); + event_handler_.preRead(handler_ctx, "MetaService.createBackup"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.createBackup", args); + createBackup_result result = new createBackup_result(); + result.success = iface_.createBackup(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.createBackup", result); + oprot.writeMessageBegin(new TMessage("createBackup", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.createBackup", result); + } + + } + + private class restoreMeta implements ProcessFunction { + public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException + { + Object handler_ctx = event_handler_.getContext("MetaService.restoreMeta", server_ctx); + restoreMeta_args args = new restoreMeta_args(); + event_handler_.preRead(handler_ctx, "MetaService.restoreMeta"); + args.read(iprot); + iprot.readMessageEnd(); + event_handler_.postRead(handler_ctx, "MetaService.restoreMeta", args); + restoreMeta_result result = new restoreMeta_result(); + result.success = iface_.restoreMeta(args.req); + event_handler_.preWrite(handler_ctx, "MetaService.restoreMeta", result); + oprot.writeMessageBegin(new TMessage("restoreMeta", TMessageType.REPLY, seqid)); + result.write(oprot); + oprot.writeMessageEnd(); + oprot.getTransport().flush(); + event_handler_.postWrite(handler_ctx, "MetaService.restoreMeta", result); + } + + } + private class listCluster implements ProcessFunction { public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException { @@ -9030,7 +9133,442 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateSpaceReq(); + this.req = new CreateSpaceReq(); + this.req.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (this.req != null) { + oprot.writeFieldBegin(REQ_FIELD_DESC); + this.req.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("createSpace_args"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("req"); + sb.append(space); + sb.append(":").append(space); + if (this.getReq() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class createSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSpace_result"); + private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); + + public ExecResp success; + public static final int SUCCESS = 0; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, ExecResp.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(createSpace_result.class, metaDataMap); + } + + public createSpace_result() { + } + + public createSpace_result( + ExecResp success) { + this(); + this.success = success; + } + + /** + * Performs a deep copy on other. + */ + public createSpace_result(createSpace_result other) { + if (other.isSetSuccess()) { + this.success = TBaseHelper.deepCopy(other.success); + } + } + + public createSpace_result deepCopy() { + return new createSpace_result(this); + } + + public ExecResp getSuccess() { + return this.success; + } + + public createSpace_result setSuccess(ExecResp success) { + this.success = success; + return this; + } + + public void unsetSuccess() { + this.success = null; + } + + // Returns true if field success is set (has been assigned a value) and false otherwise + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean __value) { + if (!__value) { + this.success = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case SUCCESS: + if (__value == null) { + unsetSuccess(); + } else { + setSuccess((ExecResp)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case SUCCESS: + return getSuccess(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof createSpace_result)) + return false; + createSpace_result that = (createSpace_result)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {success}); + } + + @Override + public int compareTo(createSpace_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case SUCCESS: + if (__field.type == TType.STRUCT) { + this.success = new ExecResp(); + this.success.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + default: + TProtocolUtil.skip(iprot, __field.type); + break; + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + + + // check for required fields of primitive type, which can't be checked in the validate method + validate(); + } + + public void write(TProtocol oprot) throws TException { + oprot.writeStructBegin(STRUCT_DESC); + + if (this.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + this.success.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + @Override + public String toString() { + return toString(1, true); + } + + @Override + public String toString(int indent, boolean prettyPrint) { + String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; + String newLine = prettyPrint ? "\n" : ""; + String space = prettyPrint ? " " : ""; + StringBuilder sb = new StringBuilder("createSpace_result"); + sb.append(space); + sb.append("("); + sb.append(newLine); + boolean first = true; + + sb.append(indentStr); + sb.append("success"); + sb.append(space); + sb.append(":").append(space); + if (this.getSuccess() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); + } + first = false; + sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); + sb.append(")"); + return sb.toString(); + } + + public void validate() throws TException { + // check for required fields + } + + } + + public static class dropSpace_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropSpace_args"); + private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); + + public DropSpaceReq req; + public static final int REQ = 1; + + // isset id assignments + + public static final Map metaDataMap; + + static { + Map tmpMetaDataMap = new HashMap(); + tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, DropSpaceReq.class))); + metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); + } + + static { + FieldMetaData.addStructMetaDataMap(dropSpace_args.class, metaDataMap); + } + + public dropSpace_args() { + } + + public dropSpace_args( + DropSpaceReq req) { + this(); + this.req = req; + } + + /** + * Performs a deep copy on other. + */ + public dropSpace_args(dropSpace_args other) { + if (other.isSetReq()) { + this.req = TBaseHelper.deepCopy(other.req); + } + } + + public dropSpace_args deepCopy() { + return new dropSpace_args(this); + } + + public DropSpaceReq getReq() { + return this.req; + } + + public dropSpace_args setReq(DropSpaceReq req) { + this.req = req; + return this; + } + + public void unsetReq() { + this.req = null; + } + + // Returns true if field req is set (has been assigned a value) and false otherwise + public boolean isSetReq() { + return this.req != null; + } + + public void setReqIsSet(boolean __value) { + if (!__value) { + this.req = null; + } + } + + public void setFieldValue(int fieldID, Object __value) { + switch (fieldID) { + case REQ: + if (__value == null) { + unsetReq(); + } else { + setReq((DropSpaceReq)__value); + } + break; + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + public Object getFieldValue(int fieldID) { + switch (fieldID) { + case REQ: + return getReq(); + + default: + throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); + } + } + + @Override + public boolean equals(Object _that) { + if (_that == null) + return false; + if (this == _that) + return true; + if (!(_that instanceof dropSpace_args)) + return false; + dropSpace_args that = (dropSpace_args)_that; + + if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } + + return true; + } + + @Override + public int hashCode() { + return Arrays.deepHashCode(new Object[] {req}); + } + + @Override + public int compareTo(dropSpace_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + + public void read(TProtocol iprot) throws TException { + TField __field; + iprot.readStructBegin(metaDataMap); + while (true) + { + __field = iprot.readFieldBegin(); + if (__field.type == TType.STOP) { + break; + } + switch (__field.id) + { + case REQ: + if (__field.type == TType.STRUCT) { + this.req = new DropSpaceReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -9072,7 +9610,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpace_args"); + StringBuilder sb = new StringBuilder("dropSpace_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9099,8 +9637,8 @@ public void validate() throws TException { } - public static class createSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSpace_result"); + public static class dropSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropSpace_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -9118,13 +9656,13 @@ public static class createSpace_result implements TBase, java.io.Serializable, C } static { - FieldMetaData.addStructMetaDataMap(createSpace_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropSpace_result.class, metaDataMap); } - public createSpace_result() { + public dropSpace_result() { } - public createSpace_result( + public dropSpace_result( ExecResp success) { this(); this.success = success; @@ -9133,21 +9671,21 @@ public createSpace_result( /** * Performs a deep copy on other. */ - public createSpace_result(createSpace_result other) { + public dropSpace_result(dropSpace_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createSpace_result deepCopy() { - return new createSpace_result(this); + public dropSpace_result deepCopy() { + return new dropSpace_result(this); } public ExecResp getSuccess() { return this.success; } - public createSpace_result setSuccess(ExecResp success) { + public dropSpace_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -9198,9 +9736,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSpace_result)) + if (!(_that instanceof dropSpace_result)) return false; - createSpace_result that = (createSpace_result)_that; + dropSpace_result that = (dropSpace_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -9213,7 +9751,7 @@ public int hashCode() { } @Override - public int compareTo(createSpace_result other) { + public int compareTo(dropSpace_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -9289,7 +9827,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpace_result"); + StringBuilder sb = new StringBuilder("dropSpace_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9316,11 +9854,11 @@ public void validate() throws TException { } - public static class dropSpace_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropSpace_args"); + public static class getSpace_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getSpace_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropSpaceReq req; + public GetSpaceReq req; public static final int REQ = 1; // isset id assignments @@ -9330,19 +9868,19 @@ public static class dropSpace_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropSpaceReq.class))); + new StructMetaData(TType.STRUCT, GetSpaceReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropSpace_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getSpace_args.class, metaDataMap); } - public dropSpace_args() { + public getSpace_args() { } - public dropSpace_args( - DropSpaceReq req) { + public getSpace_args( + GetSpaceReq req) { this(); this.req = req; } @@ -9350,21 +9888,21 @@ public dropSpace_args( /** * Performs a deep copy on other. */ - public dropSpace_args(dropSpace_args other) { + public getSpace_args(getSpace_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropSpace_args deepCopy() { - return new dropSpace_args(this); + public getSpace_args deepCopy() { + return new getSpace_args(this); } - public DropSpaceReq getReq() { + public GetSpaceReq getReq() { return this.req; } - public dropSpace_args setReq(DropSpaceReq req) { + public getSpace_args setReq(GetSpaceReq req) { this.req = req; return this; } @@ -9390,7 +9928,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropSpaceReq)__value); + setReq((GetSpaceReq)__value); } break; @@ -9415,9 +9953,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropSpace_args)) + if (!(_that instanceof getSpace_args)) return false; - dropSpace_args that = (dropSpace_args)_that; + getSpace_args that = (getSpace_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -9430,7 +9968,7 @@ public int hashCode() { } @Override - public int compareTo(dropSpace_args other) { + public int compareTo(getSpace_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -9465,7 +10003,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropSpaceReq(); + this.req = new GetSpaceReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -9507,7 +10045,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropSpace_args"); + StringBuilder sb = new StringBuilder("getSpace_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9534,11 +10072,11 @@ public void validate() throws TException { } - public static class dropSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropSpace_result"); + public static class getSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getSpace_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetSpaceResp success; public static final int SUCCESS = 0; // isset id assignments @@ -9548,19 +10086,19 @@ public static class dropSpace_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetSpaceResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropSpace_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getSpace_result.class, metaDataMap); } - public dropSpace_result() { + public getSpace_result() { } - public dropSpace_result( - ExecResp success) { + public getSpace_result( + GetSpaceResp success) { this(); this.success = success; } @@ -9568,21 +10106,21 @@ public dropSpace_result( /** * Performs a deep copy on other. */ - public dropSpace_result(dropSpace_result other) { + public getSpace_result(getSpace_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropSpace_result deepCopy() { - return new dropSpace_result(this); + public getSpace_result deepCopy() { + return new getSpace_result(this); } - public ExecResp getSuccess() { + public GetSpaceResp getSuccess() { return this.success; } - public dropSpace_result setSuccess(ExecResp success) { + public getSpace_result setSuccess(GetSpaceResp success) { this.success = success; return this; } @@ -9608,7 +10146,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetSpaceResp)__value); } break; @@ -9633,9 +10171,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropSpace_result)) + if (!(_that instanceof getSpace_result)) return false; - dropSpace_result that = (dropSpace_result)_that; + getSpace_result that = (getSpace_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -9648,7 +10186,7 @@ public int hashCode() { } @Override - public int compareTo(dropSpace_result other) { + public int compareTo(getSpace_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -9683,7 +10221,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetSpaceResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -9724,7 +10262,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropSpace_result"); + StringBuilder sb = new StringBuilder("getSpace_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9751,11 +10289,11 @@ public void validate() throws TException { } - public static class getSpace_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getSpace_args"); + public static class listSpaces_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSpaces_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetSpaceReq req; + public ListSpacesReq req; public static final int REQ = 1; // isset id assignments @@ -9765,19 +10303,19 @@ public static class getSpace_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetSpaceReq.class))); + new StructMetaData(TType.STRUCT, ListSpacesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getSpace_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSpaces_args.class, metaDataMap); } - public getSpace_args() { + public listSpaces_args() { } - public getSpace_args( - GetSpaceReq req) { + public listSpaces_args( + ListSpacesReq req) { this(); this.req = req; } @@ -9785,21 +10323,21 @@ public getSpace_args( /** * Performs a deep copy on other. */ - public getSpace_args(getSpace_args other) { + public listSpaces_args(listSpaces_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getSpace_args deepCopy() { - return new getSpace_args(this); + public listSpaces_args deepCopy() { + return new listSpaces_args(this); } - public GetSpaceReq getReq() { + public ListSpacesReq getReq() { return this.req; } - public getSpace_args setReq(GetSpaceReq req) { + public listSpaces_args setReq(ListSpacesReq req) { this.req = req; return this; } @@ -9825,7 +10363,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetSpaceReq)__value); + setReq((ListSpacesReq)__value); } break; @@ -9850,9 +10388,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getSpace_args)) + if (!(_that instanceof listSpaces_args)) return false; - getSpace_args that = (getSpace_args)_that; + listSpaces_args that = (listSpaces_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -9865,7 +10403,7 @@ public int hashCode() { } @Override - public int compareTo(getSpace_args other) { + public int compareTo(listSpaces_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -9900,7 +10438,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetSpaceReq(); + this.req = new ListSpacesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -9942,7 +10480,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getSpace_args"); + StringBuilder sb = new StringBuilder("listSpaces_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -9969,11 +10507,11 @@ public void validate() throws TException { } - public static class getSpace_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getSpace_result"); + public static class listSpaces_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSpaces_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetSpaceResp success; + public ListSpacesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -9983,19 +10521,19 @@ public static class getSpace_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetSpaceResp.class))); + new StructMetaData(TType.STRUCT, ListSpacesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getSpace_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSpaces_result.class, metaDataMap); } - public getSpace_result() { + public listSpaces_result() { } - public getSpace_result( - GetSpaceResp success) { + public listSpaces_result( + ListSpacesResp success) { this(); this.success = success; } @@ -10003,21 +10541,21 @@ public getSpace_result( /** * Performs a deep copy on other. */ - public getSpace_result(getSpace_result other) { + public listSpaces_result(listSpaces_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getSpace_result deepCopy() { - return new getSpace_result(this); + public listSpaces_result deepCopy() { + return new listSpaces_result(this); } - public GetSpaceResp getSuccess() { + public ListSpacesResp getSuccess() { return this.success; } - public getSpace_result setSuccess(GetSpaceResp success) { + public listSpaces_result setSuccess(ListSpacesResp success) { this.success = success; return this; } @@ -10043,7 +10581,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetSpaceResp)__value); + setSuccess((ListSpacesResp)__value); } break; @@ -10068,9 +10606,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getSpace_result)) + if (!(_that instanceof listSpaces_result)) return false; - getSpace_result that = (getSpace_result)_that; + listSpaces_result that = (listSpaces_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -10083,7 +10621,7 @@ public int hashCode() { } @Override - public int compareTo(getSpace_result other) { + public int compareTo(listSpaces_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10118,7 +10656,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetSpaceResp(); + this.success = new ListSpacesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10159,7 +10697,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getSpace_result"); + StringBuilder sb = new StringBuilder("listSpaces_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10186,11 +10724,11 @@ public void validate() throws TException { } - public static class listSpaces_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSpaces_args"); + public static class createSpaceAs_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListSpacesReq req; + public CreateSpaceAsReq req; public static final int REQ = 1; // isset id assignments @@ -10200,19 +10738,19 @@ public static class listSpaces_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSpacesReq.class))); + new StructMetaData(TType.STRUCT, CreateSpaceAsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSpaces_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSpaceAs_args.class, metaDataMap); } - public listSpaces_args() { + public createSpaceAs_args() { } - public listSpaces_args( - ListSpacesReq req) { + public createSpaceAs_args( + CreateSpaceAsReq req) { this(); this.req = req; } @@ -10220,21 +10758,21 @@ public listSpaces_args( /** * Performs a deep copy on other. */ - public listSpaces_args(listSpaces_args other) { + public createSpaceAs_args(createSpaceAs_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listSpaces_args deepCopy() { - return new listSpaces_args(this); + public createSpaceAs_args deepCopy() { + return new createSpaceAs_args(this); } - public ListSpacesReq getReq() { + public CreateSpaceAsReq getReq() { return this.req; } - public listSpaces_args setReq(ListSpacesReq req) { + public createSpaceAs_args setReq(CreateSpaceAsReq req) { this.req = req; return this; } @@ -10260,7 +10798,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListSpacesReq)__value); + setReq((CreateSpaceAsReq)__value); } break; @@ -10285,9 +10823,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSpaces_args)) + if (!(_that instanceof createSpaceAs_args)) return false; - listSpaces_args that = (listSpaces_args)_that; + createSpaceAs_args that = (createSpaceAs_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -10300,7 +10838,7 @@ public int hashCode() { } @Override - public int compareTo(listSpaces_args other) { + public int compareTo(createSpaceAs_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10335,7 +10873,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListSpacesReq(); + this.req = new CreateSpaceAsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10377,7 +10915,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSpaces_args"); + StringBuilder sb = new StringBuilder("createSpaceAs_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10404,11 +10942,11 @@ public void validate() throws TException { } - public static class listSpaces_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSpaces_result"); + public static class createSpaceAs_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListSpacesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -10418,19 +10956,19 @@ public static class listSpaces_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSpacesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSpaces_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSpaceAs_result.class, metaDataMap); } - public listSpaces_result() { + public createSpaceAs_result() { } - public listSpaces_result( - ListSpacesResp success) { + public createSpaceAs_result( + ExecResp success) { this(); this.success = success; } @@ -10438,21 +10976,21 @@ public listSpaces_result( /** * Performs a deep copy on other. */ - public listSpaces_result(listSpaces_result other) { + public createSpaceAs_result(createSpaceAs_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listSpaces_result deepCopy() { - return new listSpaces_result(this); + public createSpaceAs_result deepCopy() { + return new createSpaceAs_result(this); } - public ListSpacesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listSpaces_result setSuccess(ListSpacesResp success) { + public createSpaceAs_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -10478,7 +11016,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListSpacesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -10503,9 +11041,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSpaces_result)) + if (!(_that instanceof createSpaceAs_result)) return false; - listSpaces_result that = (listSpaces_result)_that; + createSpaceAs_result that = (createSpaceAs_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -10518,7 +11056,7 @@ public int hashCode() { } @Override - public int compareTo(listSpaces_result other) { + public int compareTo(createSpaceAs_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10553,7 +11091,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListSpacesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10594,7 +11132,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSpaces_result"); + StringBuilder sb = new StringBuilder("createSpaceAs_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10621,11 +11159,11 @@ public void validate() throws TException { } - public static class createSpaceAs_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_args"); + public static class createTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateSpaceAsReq req; + public CreateTagReq req; public static final int REQ = 1; // isset id assignments @@ -10635,19 +11173,19 @@ public static class createSpaceAs_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateSpaceAsReq.class))); + new StructMetaData(TType.STRUCT, CreateTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSpaceAs_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createTag_args.class, metaDataMap); } - public createSpaceAs_args() { + public createTag_args() { } - public createSpaceAs_args( - CreateSpaceAsReq req) { + public createTag_args( + CreateTagReq req) { this(); this.req = req; } @@ -10655,21 +11193,21 @@ public createSpaceAs_args( /** * Performs a deep copy on other. */ - public createSpaceAs_args(createSpaceAs_args other) { + public createTag_args(createTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createSpaceAs_args deepCopy() { - return new createSpaceAs_args(this); + public createTag_args deepCopy() { + return new createTag_args(this); } - public CreateSpaceAsReq getReq() { + public CreateTagReq getReq() { return this.req; } - public createSpaceAs_args setReq(CreateSpaceAsReq req) { + public createTag_args setReq(CreateTagReq req) { this.req = req; return this; } @@ -10695,7 +11233,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateSpaceAsReq)__value); + setReq((CreateTagReq)__value); } break; @@ -10720,9 +11258,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSpaceAs_args)) + if (!(_that instanceof createTag_args)) return false; - createSpaceAs_args that = (createSpaceAs_args)_that; + createTag_args that = (createTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -10735,7 +11273,7 @@ public int hashCode() { } @Override - public int compareTo(createSpaceAs_args other) { + public int compareTo(createTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -10770,7 +11308,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateSpaceAsReq(); + this.req = new CreateTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -10812,7 +11350,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpaceAs_args"); + StringBuilder sb = new StringBuilder("createTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -10839,8 +11377,8 @@ public void validate() throws TException { } - public static class createSpaceAs_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSpaceAs_result"); + public static class createTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -10858,13 +11396,13 @@ public static class createSpaceAs_result implements TBase, java.io.Serializable, } static { - FieldMetaData.addStructMetaDataMap(createSpaceAs_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createTag_result.class, metaDataMap); } - public createSpaceAs_result() { + public createTag_result() { } - public createSpaceAs_result( + public createTag_result( ExecResp success) { this(); this.success = success; @@ -10873,21 +11411,21 @@ public createSpaceAs_result( /** * Performs a deep copy on other. */ - public createSpaceAs_result(createSpaceAs_result other) { + public createTag_result(createTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createSpaceAs_result deepCopy() { - return new createSpaceAs_result(this); + public createTag_result deepCopy() { + return new createTag_result(this); } public ExecResp getSuccess() { return this.success; } - public createSpaceAs_result setSuccess(ExecResp success) { + public createTag_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -10938,9 +11476,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSpaceAs_result)) + if (!(_that instanceof createTag_result)) return false; - createSpaceAs_result that = (createSpaceAs_result)_that; + createTag_result that = (createTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -10953,7 +11491,7 @@ public int hashCode() { } @Override - public int compareTo(createSpaceAs_result other) { + public int compareTo(createTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11029,7 +11567,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSpaceAs_result"); + StringBuilder sb = new StringBuilder("createTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11056,11 +11594,11 @@ public void validate() throws TException { } - public static class createTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTag_args"); + public static class alterTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateTagReq req; + public AlterTagReq req; public static final int REQ = 1; // isset id assignments @@ -11070,19 +11608,19 @@ public static class createTag_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateTagReq.class))); + new StructMetaData(TType.STRUCT, AlterTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterTag_args.class, metaDataMap); } - public createTag_args() { + public alterTag_args() { } - public createTag_args( - CreateTagReq req) { + public alterTag_args( + AlterTagReq req) { this(); this.req = req; } @@ -11090,21 +11628,21 @@ public createTag_args( /** * Performs a deep copy on other. */ - public createTag_args(createTag_args other) { + public alterTag_args(alterTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createTag_args deepCopy() { - return new createTag_args(this); + public alterTag_args deepCopy() { + return new alterTag_args(this); } - public CreateTagReq getReq() { + public AlterTagReq getReq() { return this.req; } - public createTag_args setReq(CreateTagReq req) { + public alterTag_args setReq(AlterTagReq req) { this.req = req; return this; } @@ -11130,7 +11668,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateTagReq)__value); + setReq((AlterTagReq)__value); } break; @@ -11155,9 +11693,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTag_args)) + if (!(_that instanceof alterTag_args)) return false; - createTag_args that = (createTag_args)_that; + alterTag_args that = (alterTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -11170,7 +11708,7 @@ public int hashCode() { } @Override - public int compareTo(createTag_args other) { + public int compareTo(alterTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11205,7 +11743,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateTagReq(); + this.req = new AlterTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11247,7 +11785,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTag_args"); + StringBuilder sb = new StringBuilder("alterTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11274,8 +11812,8 @@ public void validate() throws TException { } - public static class createTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTag_result"); + public static class alterTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -11293,13 +11831,13 @@ public static class createTag_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(createTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterTag_result.class, metaDataMap); } - public createTag_result() { + public alterTag_result() { } - public createTag_result( + public alterTag_result( ExecResp success) { this(); this.success = success; @@ -11308,21 +11846,21 @@ public createTag_result( /** * Performs a deep copy on other. */ - public createTag_result(createTag_result other) { + public alterTag_result(alterTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createTag_result deepCopy() { - return new createTag_result(this); + public alterTag_result deepCopy() { + return new alterTag_result(this); } public ExecResp getSuccess() { return this.success; } - public createTag_result setSuccess(ExecResp success) { + public alterTag_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -11373,9 +11911,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTag_result)) + if (!(_that instanceof alterTag_result)) return false; - createTag_result that = (createTag_result)_that; + alterTag_result that = (alterTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -11388,7 +11926,7 @@ public int hashCode() { } @Override - public int compareTo(createTag_result other) { + public int compareTo(alterTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11464,7 +12002,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTag_result"); + StringBuilder sb = new StringBuilder("alterTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11491,11 +12029,11 @@ public void validate() throws TException { } - public static class alterTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterTag_args"); + public static class dropTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AlterTagReq req; + public DropTagReq req; public static final int REQ = 1; // isset id assignments @@ -11505,19 +12043,19 @@ public static class alterTag_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AlterTagReq.class))); + new StructMetaData(TType.STRUCT, DropTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTag_args.class, metaDataMap); } - public alterTag_args() { + public dropTag_args() { } - public alterTag_args( - AlterTagReq req) { + public dropTag_args( + DropTagReq req) { this(); this.req = req; } @@ -11525,21 +12063,21 @@ public alterTag_args( /** * Performs a deep copy on other. */ - public alterTag_args(alterTag_args other) { + public dropTag_args(dropTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public alterTag_args deepCopy() { - return new alterTag_args(this); + public dropTag_args deepCopy() { + return new dropTag_args(this); } - public AlterTagReq getReq() { + public DropTagReq getReq() { return this.req; } - public alterTag_args setReq(AlterTagReq req) { + public dropTag_args setReq(DropTagReq req) { this.req = req; return this; } @@ -11565,7 +12103,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AlterTagReq)__value); + setReq((DropTagReq)__value); } break; @@ -11590,9 +12128,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterTag_args)) + if (!(_that instanceof dropTag_args)) return false; - alterTag_args that = (alterTag_args)_that; + dropTag_args that = (dropTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -11605,7 +12143,7 @@ public int hashCode() { } @Override - public int compareTo(alterTag_args other) { + public int compareTo(dropTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11640,7 +12178,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AlterTagReq(); + this.req = new DropTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -11682,7 +12220,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterTag_args"); + StringBuilder sb = new StringBuilder("dropTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11709,8 +12247,8 @@ public void validate() throws TException { } - public static class alterTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterTag_result"); + public static class dropTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -11728,13 +12266,13 @@ public static class alterTag_result implements TBase, java.io.Serializable, Clon } static { - FieldMetaData.addStructMetaDataMap(alterTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTag_result.class, metaDataMap); } - public alterTag_result() { + public dropTag_result() { } - public alterTag_result( + public dropTag_result( ExecResp success) { this(); this.success = success; @@ -11743,21 +12281,21 @@ public alterTag_result( /** * Performs a deep copy on other. */ - public alterTag_result(alterTag_result other) { + public dropTag_result(dropTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public alterTag_result deepCopy() { - return new alterTag_result(this); + public dropTag_result deepCopy() { + return new dropTag_result(this); } public ExecResp getSuccess() { return this.success; } - public alterTag_result setSuccess(ExecResp success) { + public dropTag_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -11808,9 +12346,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterTag_result)) + if (!(_that instanceof dropTag_result)) return false; - alterTag_result that = (alterTag_result)_that; + dropTag_result that = (dropTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -11823,7 +12361,7 @@ public int hashCode() { } @Override - public int compareTo(alterTag_result other) { + public int compareTo(dropTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -11899,7 +12437,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterTag_result"); + StringBuilder sb = new StringBuilder("dropTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -11926,11 +12464,11 @@ public void validate() throws TException { } - public static class dropTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTag_args"); + public static class getTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTag_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropTagReq req; + public GetTagReq req; public static final int REQ = 1; // isset id assignments @@ -11940,19 +12478,19 @@ public static class dropTag_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropTagReq.class))); + new StructMetaData(TType.STRUCT, GetTagReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTag_args.class, metaDataMap); } - public dropTag_args() { + public getTag_args() { } - public dropTag_args( - DropTagReq req) { + public getTag_args( + GetTagReq req) { this(); this.req = req; } @@ -11960,21 +12498,21 @@ public dropTag_args( /** * Performs a deep copy on other. */ - public dropTag_args(dropTag_args other) { + public getTag_args(getTag_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropTag_args deepCopy() { - return new dropTag_args(this); + public getTag_args deepCopy() { + return new getTag_args(this); } - public DropTagReq getReq() { + public GetTagReq getReq() { return this.req; } - public dropTag_args setReq(DropTagReq req) { + public getTag_args setReq(GetTagReq req) { this.req = req; return this; } @@ -12000,7 +12538,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropTagReq)__value); + setReq((GetTagReq)__value); } break; @@ -12025,9 +12563,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTag_args)) + if (!(_that instanceof getTag_args)) return false; - dropTag_args that = (dropTag_args)_that; + getTag_args that = (getTag_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -12040,7 +12578,7 @@ public int hashCode() { } @Override - public int compareTo(dropTag_args other) { + public int compareTo(getTag_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12075,7 +12613,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropTagReq(); + this.req = new GetTagReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12117,7 +12655,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTag_args"); + StringBuilder sb = new StringBuilder("getTag_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12144,11 +12682,11 @@ public void validate() throws TException { } - public static class dropTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTag_result"); + public static class getTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTag_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetTagResp success; public static final int SUCCESS = 0; // isset id assignments @@ -12158,19 +12696,19 @@ public static class dropTag_result implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetTagResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTag_result.class, metaDataMap); } - public dropTag_result() { + public getTag_result() { } - public dropTag_result( - ExecResp success) { + public getTag_result( + GetTagResp success) { this(); this.success = success; } @@ -12178,21 +12716,21 @@ public dropTag_result( /** * Performs a deep copy on other. */ - public dropTag_result(dropTag_result other) { + public getTag_result(getTag_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropTag_result deepCopy() { - return new dropTag_result(this); + public getTag_result deepCopy() { + return new getTag_result(this); } - public ExecResp getSuccess() { + public GetTagResp getSuccess() { return this.success; } - public dropTag_result setSuccess(ExecResp success) { + public getTag_result setSuccess(GetTagResp success) { this.success = success; return this; } @@ -12218,7 +12756,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetTagResp)__value); } break; @@ -12243,9 +12781,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTag_result)) + if (!(_that instanceof getTag_result)) return false; - dropTag_result that = (dropTag_result)_that; + getTag_result that = (getTag_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -12258,7 +12796,7 @@ public int hashCode() { } @Override - public int compareTo(dropTag_result other) { + public int compareTo(getTag_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12293,7 +12831,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetTagResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12334,7 +12872,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTag_result"); + StringBuilder sb = new StringBuilder("getTag_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12361,11 +12899,11 @@ public void validate() throws TException { } - public static class getTag_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTag_args"); + public static class listTags_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTags_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetTagReq req; + public ListTagsReq req; public static final int REQ = 1; // isset id assignments @@ -12375,19 +12913,19 @@ public static class getTag_args implements TBase, java.io.Serializable, Cloneabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagReq.class))); + new StructMetaData(TType.STRUCT, ListTagsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTag_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTags_args.class, metaDataMap); } - public getTag_args() { + public listTags_args() { } - public getTag_args( - GetTagReq req) { + public listTags_args( + ListTagsReq req) { this(); this.req = req; } @@ -12395,21 +12933,21 @@ public getTag_args( /** * Performs a deep copy on other. */ - public getTag_args(getTag_args other) { + public listTags_args(listTags_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getTag_args deepCopy() { - return new getTag_args(this); + public listTags_args deepCopy() { + return new listTags_args(this); } - public GetTagReq getReq() { + public ListTagsReq getReq() { return this.req; } - public getTag_args setReq(GetTagReq req) { + public listTags_args setReq(ListTagsReq req) { this.req = req; return this; } @@ -12435,7 +12973,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetTagReq)__value); + setReq((ListTagsReq)__value); } break; @@ -12460,9 +12998,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTag_args)) + if (!(_that instanceof listTags_args)) return false; - getTag_args that = (getTag_args)_that; + listTags_args that = (listTags_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -12475,7 +13013,7 @@ public int hashCode() { } @Override - public int compareTo(getTag_args other) { + public int compareTo(listTags_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12510,7 +13048,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetTagReq(); + this.req = new ListTagsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12552,7 +13090,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTag_args"); + StringBuilder sb = new StringBuilder("listTags_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12579,11 +13117,11 @@ public void validate() throws TException { } - public static class getTag_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTag_result"); + public static class listTags_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTags_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetTagResp success; + public ListTagsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -12593,19 +13131,19 @@ public static class getTag_result implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagResp.class))); + new StructMetaData(TType.STRUCT, ListTagsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTag_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTags_result.class, metaDataMap); } - public getTag_result() { + public listTags_result() { } - public getTag_result( - GetTagResp success) { + public listTags_result( + ListTagsResp success) { this(); this.success = success; } @@ -12613,21 +13151,21 @@ public getTag_result( /** * Performs a deep copy on other. */ - public getTag_result(getTag_result other) { + public listTags_result(listTags_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getTag_result deepCopy() { - return new getTag_result(this); + public listTags_result deepCopy() { + return new listTags_result(this); } - public GetTagResp getSuccess() { + public ListTagsResp getSuccess() { return this.success; } - public getTag_result setSuccess(GetTagResp success) { + public listTags_result setSuccess(ListTagsResp success) { this.success = success; return this; } @@ -12653,7 +13191,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetTagResp)__value); + setSuccess((ListTagsResp)__value); } break; @@ -12678,9 +13216,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTag_result)) + if (!(_that instanceof listTags_result)) return false; - getTag_result that = (getTag_result)_that; + listTags_result that = (listTags_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -12693,7 +13231,7 @@ public int hashCode() { } @Override - public int compareTo(getTag_result other) { + public int compareTo(listTags_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12728,7 +13266,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetTagResp(); + this.success = new ListTagsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12769,7 +13307,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTag_result"); + StringBuilder sb = new StringBuilder("listTags_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -12796,11 +13334,11 @@ public void validate() throws TException { } - public static class listTags_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTags_args"); + public static class createEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListTagsReq req; + public CreateEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -12810,19 +13348,19 @@ public static class listTags_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagsReq.class))); + new StructMetaData(TType.STRUCT, CreateEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTags_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdge_args.class, metaDataMap); } - public listTags_args() { + public createEdge_args() { } - public listTags_args( - ListTagsReq req) { + public createEdge_args( + CreateEdgeReq req) { this(); this.req = req; } @@ -12830,21 +13368,21 @@ public listTags_args( /** * Performs a deep copy on other. */ - public listTags_args(listTags_args other) { + public createEdge_args(createEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listTags_args deepCopy() { - return new listTags_args(this); + public createEdge_args deepCopy() { + return new createEdge_args(this); } - public ListTagsReq getReq() { + public CreateEdgeReq getReq() { return this.req; } - public listTags_args setReq(ListTagsReq req) { + public createEdge_args setReq(CreateEdgeReq req) { this.req = req; return this; } @@ -12870,7 +13408,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListTagsReq)__value); + setReq((CreateEdgeReq)__value); } break; @@ -12895,9 +13433,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTags_args)) + if (!(_that instanceof createEdge_args)) return false; - listTags_args that = (listTags_args)_that; + createEdge_args that = (createEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -12910,7 +13448,7 @@ public int hashCode() { } @Override - public int compareTo(listTags_args other) { + public int compareTo(createEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -12945,7 +13483,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListTagsReq(); + this.req = new CreateEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -12987,7 +13525,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTags_args"); + StringBuilder sb = new StringBuilder("createEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13014,11 +13552,11 @@ public void validate() throws TException { } - public static class listTags_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTags_result"); + public static class createEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListTagsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -13028,19 +13566,19 @@ public static class listTags_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTags_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdge_result.class, metaDataMap); } - public listTags_result() { + public createEdge_result() { } - public listTags_result( - ListTagsResp success) { + public createEdge_result( + ExecResp success) { this(); this.success = success; } @@ -13048,21 +13586,21 @@ public listTags_result( /** * Performs a deep copy on other. */ - public listTags_result(listTags_result other) { + public createEdge_result(createEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listTags_result deepCopy() { - return new listTags_result(this); + public createEdge_result deepCopy() { + return new createEdge_result(this); } - public ListTagsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listTags_result setSuccess(ListTagsResp success) { + public createEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -13088,7 +13626,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListTagsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -13113,9 +13651,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTags_result)) + if (!(_that instanceof createEdge_result)) return false; - listTags_result that = (listTags_result)_that; + createEdge_result that = (createEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -13128,7 +13666,7 @@ public int hashCode() { } @Override - public int compareTo(listTags_result other) { + public int compareTo(createEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13163,7 +13701,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListTagsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13204,7 +13742,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTags_result"); + StringBuilder sb = new StringBuilder("createEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13231,11 +13769,11 @@ public void validate() throws TException { } - public static class createEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdge_args"); + public static class alterEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateEdgeReq req; + public AlterEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -13245,19 +13783,19 @@ public static class createEdge_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateEdgeReq.class))); + new StructMetaData(TType.STRUCT, AlterEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterEdge_args.class, metaDataMap); } - public createEdge_args() { + public alterEdge_args() { } - public createEdge_args( - CreateEdgeReq req) { + public alterEdge_args( + AlterEdgeReq req) { this(); this.req = req; } @@ -13265,21 +13803,21 @@ public createEdge_args( /** * Performs a deep copy on other. */ - public createEdge_args(createEdge_args other) { + public alterEdge_args(alterEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createEdge_args deepCopy() { - return new createEdge_args(this); + public alterEdge_args deepCopy() { + return new alterEdge_args(this); } - public CreateEdgeReq getReq() { + public AlterEdgeReq getReq() { return this.req; } - public createEdge_args setReq(CreateEdgeReq req) { + public alterEdge_args setReq(AlterEdgeReq req) { this.req = req; return this; } @@ -13305,7 +13843,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateEdgeReq)__value); + setReq((AlterEdgeReq)__value); } break; @@ -13330,9 +13868,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdge_args)) + if (!(_that instanceof alterEdge_args)) return false; - createEdge_args that = (createEdge_args)_that; + alterEdge_args that = (alterEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -13345,7 +13883,7 @@ public int hashCode() { } @Override - public int compareTo(createEdge_args other) { + public int compareTo(alterEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13380,7 +13918,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateEdgeReq(); + this.req = new AlterEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13422,7 +13960,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdge_args"); + StringBuilder sb = new StringBuilder("alterEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13449,8 +13987,8 @@ public void validate() throws TException { } - public static class createEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdge_result"); + public static class alterEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -13468,13 +14006,13 @@ public static class createEdge_result implements TBase, java.io.Serializable, Cl } static { - FieldMetaData.addStructMetaDataMap(createEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterEdge_result.class, metaDataMap); } - public createEdge_result() { + public alterEdge_result() { } - public createEdge_result( + public alterEdge_result( ExecResp success) { this(); this.success = success; @@ -13483,21 +14021,21 @@ public createEdge_result( /** * Performs a deep copy on other. */ - public createEdge_result(createEdge_result other) { + public alterEdge_result(alterEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createEdge_result deepCopy() { - return new createEdge_result(this); + public alterEdge_result deepCopy() { + return new alterEdge_result(this); } public ExecResp getSuccess() { return this.success; } - public createEdge_result setSuccess(ExecResp success) { + public alterEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -13548,9 +14086,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdge_result)) + if (!(_that instanceof alterEdge_result)) return false; - createEdge_result that = (createEdge_result)_that; + alterEdge_result that = (alterEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -13563,7 +14101,7 @@ public int hashCode() { } @Override - public int compareTo(createEdge_result other) { + public int compareTo(alterEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13639,7 +14177,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdge_result"); + StringBuilder sb = new StringBuilder("alterEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13666,11 +14204,11 @@ public void validate() throws TException { } - public static class alterEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterEdge_args"); + public static class dropEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AlterEdgeReq req; + public DropEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -13680,19 +14218,19 @@ public static class alterEdge_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AlterEdgeReq.class))); + new StructMetaData(TType.STRUCT, DropEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdge_args.class, metaDataMap); } - public alterEdge_args() { + public dropEdge_args() { } - public alterEdge_args( - AlterEdgeReq req) { + public dropEdge_args( + DropEdgeReq req) { this(); this.req = req; } @@ -13700,21 +14238,21 @@ public alterEdge_args( /** * Performs a deep copy on other. */ - public alterEdge_args(alterEdge_args other) { + public dropEdge_args(dropEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public alterEdge_args deepCopy() { - return new alterEdge_args(this); + public dropEdge_args deepCopy() { + return new dropEdge_args(this); } - public AlterEdgeReq getReq() { + public DropEdgeReq getReq() { return this.req; } - public alterEdge_args setReq(AlterEdgeReq req) { + public dropEdge_args setReq(DropEdgeReq req) { this.req = req; return this; } @@ -13740,7 +14278,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AlterEdgeReq)__value); + setReq((DropEdgeReq)__value); } break; @@ -13765,9 +14303,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterEdge_args)) + if (!(_that instanceof dropEdge_args)) return false; - alterEdge_args that = (alterEdge_args)_that; + dropEdge_args that = (dropEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -13780,7 +14318,7 @@ public int hashCode() { } @Override - public int compareTo(alterEdge_args other) { + public int compareTo(dropEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -13815,7 +14353,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AlterEdgeReq(); + this.req = new DropEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -13857,7 +14395,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterEdge_args"); + StringBuilder sb = new StringBuilder("dropEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -13884,8 +14422,8 @@ public void validate() throws TException { } - public static class alterEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterEdge_result"); + public static class dropEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -13903,13 +14441,13 @@ public static class alterEdge_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(alterEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdge_result.class, metaDataMap); } - public alterEdge_result() { + public dropEdge_result() { } - public alterEdge_result( + public dropEdge_result( ExecResp success) { this(); this.success = success; @@ -13918,21 +14456,21 @@ public alterEdge_result( /** * Performs a deep copy on other. */ - public alterEdge_result(alterEdge_result other) { + public dropEdge_result(dropEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public alterEdge_result deepCopy() { - return new alterEdge_result(this); + public dropEdge_result deepCopy() { + return new dropEdge_result(this); } public ExecResp getSuccess() { return this.success; } - public alterEdge_result setSuccess(ExecResp success) { + public dropEdge_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -13983,9 +14521,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterEdge_result)) + if (!(_that instanceof dropEdge_result)) return false; - alterEdge_result that = (alterEdge_result)_that; + dropEdge_result that = (dropEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -13998,7 +14536,7 @@ public int hashCode() { } @Override - public int compareTo(alterEdge_result other) { + public int compareTo(dropEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14074,7 +14612,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterEdge_result"); + StringBuilder sb = new StringBuilder("dropEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14101,11 +14639,11 @@ public void validate() throws TException { } - public static class dropEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdge_args"); + public static class getEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdge_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropEdgeReq req; + public GetEdgeReq req; public static final int REQ = 1; // isset id assignments @@ -14115,19 +14653,19 @@ public static class dropEdge_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropEdgeReq.class))); + new StructMetaData(TType.STRUCT, GetEdgeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdge_args.class, metaDataMap); } - public dropEdge_args() { + public getEdge_args() { } - public dropEdge_args( - DropEdgeReq req) { + public getEdge_args( + GetEdgeReq req) { this(); this.req = req; } @@ -14135,21 +14673,21 @@ public dropEdge_args( /** * Performs a deep copy on other. */ - public dropEdge_args(dropEdge_args other) { + public getEdge_args(getEdge_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropEdge_args deepCopy() { - return new dropEdge_args(this); + public getEdge_args deepCopy() { + return new getEdge_args(this); } - public DropEdgeReq getReq() { + public GetEdgeReq getReq() { return this.req; } - public dropEdge_args setReq(DropEdgeReq req) { + public getEdge_args setReq(GetEdgeReq req) { this.req = req; return this; } @@ -14175,7 +14713,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropEdgeReq)__value); + setReq((GetEdgeReq)__value); } break; @@ -14200,9 +14738,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdge_args)) + if (!(_that instanceof getEdge_args)) return false; - dropEdge_args that = (dropEdge_args)_that; + getEdge_args that = (getEdge_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -14215,7 +14753,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdge_args other) { + public int compareTo(getEdge_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14250,7 +14788,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropEdgeReq(); + this.req = new GetEdgeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14292,7 +14830,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdge_args"); + StringBuilder sb = new StringBuilder("getEdge_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14319,11 +14857,11 @@ public void validate() throws TException { } - public static class dropEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdge_result"); + public static class getEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdge_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetEdgeResp success; public static final int SUCCESS = 0; // isset id assignments @@ -14333,19 +14871,19 @@ public static class dropEdge_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetEdgeResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdge_result.class, metaDataMap); } - public dropEdge_result() { + public getEdge_result() { } - public dropEdge_result( - ExecResp success) { + public getEdge_result( + GetEdgeResp success) { this(); this.success = success; } @@ -14353,21 +14891,21 @@ public dropEdge_result( /** * Performs a deep copy on other. */ - public dropEdge_result(dropEdge_result other) { + public getEdge_result(getEdge_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropEdge_result deepCopy() { - return new dropEdge_result(this); + public getEdge_result deepCopy() { + return new getEdge_result(this); } - public ExecResp getSuccess() { + public GetEdgeResp getSuccess() { return this.success; } - public dropEdge_result setSuccess(ExecResp success) { + public getEdge_result setSuccess(GetEdgeResp success) { this.success = success; return this; } @@ -14393,7 +14931,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetEdgeResp)__value); } break; @@ -14418,9 +14956,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdge_result)) + if (!(_that instanceof getEdge_result)) return false; - dropEdge_result that = (dropEdge_result)_that; + getEdge_result that = (getEdge_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -14433,7 +14971,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdge_result other) { + public int compareTo(getEdge_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14468,7 +15006,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetEdgeResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14509,7 +15047,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdge_result"); + StringBuilder sb = new StringBuilder("getEdge_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14536,11 +15074,11 @@ public void validate() throws TException { } - public static class getEdge_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdge_args"); + public static class listEdges_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdges_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetEdgeReq req; + public ListEdgesReq req; public static final int REQ = 1; // isset id assignments @@ -14550,19 +15088,19 @@ public static class getEdge_args implements TBase, java.io.Serializable, Cloneab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeReq.class))); + new StructMetaData(TType.STRUCT, ListEdgesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdge_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdges_args.class, metaDataMap); } - public getEdge_args() { + public listEdges_args() { } - public getEdge_args( - GetEdgeReq req) { + public listEdges_args( + ListEdgesReq req) { this(); this.req = req; } @@ -14570,21 +15108,21 @@ public getEdge_args( /** * Performs a deep copy on other. */ - public getEdge_args(getEdge_args other) { + public listEdges_args(listEdges_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getEdge_args deepCopy() { - return new getEdge_args(this); + public listEdges_args deepCopy() { + return new listEdges_args(this); } - public GetEdgeReq getReq() { + public ListEdgesReq getReq() { return this.req; } - public getEdge_args setReq(GetEdgeReq req) { + public listEdges_args setReq(ListEdgesReq req) { this.req = req; return this; } @@ -14610,7 +15148,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetEdgeReq)__value); + setReq((ListEdgesReq)__value); } break; @@ -14635,9 +15173,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdge_args)) + if (!(_that instanceof listEdges_args)) return false; - getEdge_args that = (getEdge_args)_that; + listEdges_args that = (listEdges_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -14650,7 +15188,7 @@ public int hashCode() { } @Override - public int compareTo(getEdge_args other) { + public int compareTo(listEdges_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14685,7 +15223,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetEdgeReq(); + this.req = new ListEdgesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14727,7 +15265,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdge_args"); + StringBuilder sb = new StringBuilder("listEdges_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14754,11 +15292,11 @@ public void validate() throws TException { } - public static class getEdge_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdge_result"); + public static class listEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdges_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetEdgeResp success; + public ListEdgesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -14768,19 +15306,19 @@ public static class getEdge_result implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeResp.class))); + new StructMetaData(TType.STRUCT, ListEdgesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdge_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdges_result.class, metaDataMap); } - public getEdge_result() { + public listEdges_result() { } - public getEdge_result( - GetEdgeResp success) { + public listEdges_result( + ListEdgesResp success) { this(); this.success = success; } @@ -14788,21 +15326,21 @@ public getEdge_result( /** * Performs a deep copy on other. */ - public getEdge_result(getEdge_result other) { + public listEdges_result(listEdges_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getEdge_result deepCopy() { - return new getEdge_result(this); + public listEdges_result deepCopy() { + return new listEdges_result(this); } - public GetEdgeResp getSuccess() { + public ListEdgesResp getSuccess() { return this.success; } - public getEdge_result setSuccess(GetEdgeResp success) { + public listEdges_result setSuccess(ListEdgesResp success) { this.success = success; return this; } @@ -14828,7 +15366,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetEdgeResp)__value); + setSuccess((ListEdgesResp)__value); } break; @@ -14853,9 +15391,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdge_result)) + if (!(_that instanceof listEdges_result)) return false; - getEdge_result that = (getEdge_result)_that; + listEdges_result that = (listEdges_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -14868,7 +15406,7 @@ public int hashCode() { } @Override - public int compareTo(getEdge_result other) { + public int compareTo(listEdges_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -14903,7 +15441,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetEdgeResp(); + this.success = new ListEdgesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -14944,7 +15482,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdge_result"); + StringBuilder sb = new StringBuilder("listEdges_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -14971,11 +15509,11 @@ public void validate() throws TException { } - public static class listEdges_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdges_args"); + public static class addHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHosts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListEdgesReq req; + public AddHostsReq req; public static final int REQ = 1; // isset id assignments @@ -14985,19 +15523,19 @@ public static class listEdges_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgesReq.class))); + new StructMetaData(TType.STRUCT, AddHostsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdges_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHosts_args.class, metaDataMap); } - public listEdges_args() { + public addHosts_args() { } - public listEdges_args( - ListEdgesReq req) { + public addHosts_args( + AddHostsReq req) { this(); this.req = req; } @@ -15005,21 +15543,21 @@ public listEdges_args( /** * Performs a deep copy on other. */ - public listEdges_args(listEdges_args other) { + public addHosts_args(addHosts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listEdges_args deepCopy() { - return new listEdges_args(this); + public addHosts_args deepCopy() { + return new addHosts_args(this); } - public ListEdgesReq getReq() { + public AddHostsReq getReq() { return this.req; } - public listEdges_args setReq(ListEdgesReq req) { + public addHosts_args setReq(AddHostsReq req) { this.req = req; return this; } @@ -15045,7 +15583,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListEdgesReq)__value); + setReq((AddHostsReq)__value); } break; @@ -15070,9 +15608,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdges_args)) + if (!(_that instanceof addHosts_args)) return false; - listEdges_args that = (listEdges_args)_that; + addHosts_args that = (addHosts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -15085,7 +15623,7 @@ public int hashCode() { } @Override - public int compareTo(listEdges_args other) { + public int compareTo(addHosts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15120,7 +15658,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListEdgesReq(); + this.req = new AddHostsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -15162,7 +15700,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdges_args"); + StringBuilder sb = new StringBuilder("addHosts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -15189,11 +15727,11 @@ public void validate() throws TException { } - public static class listEdges_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdges_result"); + public static class addHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHosts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListEdgesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -15203,19 +15741,19 @@ public static class listEdges_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdges_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHosts_result.class, metaDataMap); } - public listEdges_result() { + public addHosts_result() { } - public listEdges_result( - ListEdgesResp success) { + public addHosts_result( + ExecResp success) { this(); this.success = success; } @@ -15223,21 +15761,21 @@ public listEdges_result( /** * Performs a deep copy on other. */ - public listEdges_result(listEdges_result other) { + public addHosts_result(addHosts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listEdges_result deepCopy() { - return new listEdges_result(this); + public addHosts_result deepCopy() { + return new addHosts_result(this); } - public ListEdgesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listEdges_result setSuccess(ListEdgesResp success) { + public addHosts_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -15263,7 +15801,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListEdgesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -15288,9 +15826,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdges_result)) + if (!(_that instanceof addHosts_result)) return false; - listEdges_result that = (listEdges_result)_that; + addHosts_result that = (addHosts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -15303,7 +15841,7 @@ public int hashCode() { } @Override - public int compareTo(listEdges_result other) { + public int compareTo(addHosts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15338,7 +15876,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListEdgesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -15379,7 +15917,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdges_result"); + StringBuilder sb = new StringBuilder("addHosts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -15406,11 +15944,11 @@ public void validate() throws TException { } - public static class addHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHosts_args"); + public static class addHostsIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddHostsReq req; + public AddHostsIntoZoneReq req; public static final int REQ = 1; // isset id assignments @@ -15420,19 +15958,19 @@ public static class addHosts_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddHostsReq.class))); + new StructMetaData(TType.STRUCT, AddHostsIntoZoneReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addHosts_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostsIntoZone_args.class, metaDataMap); } - public addHosts_args() { + public addHostsIntoZone_args() { } - public addHosts_args( - AddHostsReq req) { + public addHostsIntoZone_args( + AddHostsIntoZoneReq req) { this(); this.req = req; } @@ -15440,21 +15978,21 @@ public addHosts_args( /** * Performs a deep copy on other. */ - public addHosts_args(addHosts_args other) { + public addHostsIntoZone_args(addHostsIntoZone_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addHosts_args deepCopy() { - return new addHosts_args(this); + public addHostsIntoZone_args deepCopy() { + return new addHostsIntoZone_args(this); } - public AddHostsReq getReq() { + public AddHostsIntoZoneReq getReq() { return this.req; } - public addHosts_args setReq(AddHostsReq req) { + public addHostsIntoZone_args setReq(AddHostsIntoZoneReq req) { this.req = req; return this; } @@ -15480,7 +16018,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddHostsReq)__value); + setReq((AddHostsIntoZoneReq)__value); } break; @@ -15505,9 +16043,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHosts_args)) + if (!(_that instanceof addHostsIntoZone_args)) return false; - addHosts_args that = (addHosts_args)_that; + addHostsIntoZone_args that = (addHostsIntoZone_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -15520,7 +16058,7 @@ public int hashCode() { } @Override - public int compareTo(addHosts_args other) { + public int compareTo(addHostsIntoZone_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15555,7 +16093,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddHostsReq(); + this.req = new AddHostsIntoZoneReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -15597,7 +16135,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHosts_args"); + StringBuilder sb = new StringBuilder("addHostsIntoZone_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -15624,8 +16162,8 @@ public void validate() throws TException { } - public static class addHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHosts_result"); + public static class addHostsIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -15643,13 +16181,13 @@ public static class addHosts_result implements TBase, java.io.Serializable, Clon } static { - FieldMetaData.addStructMetaDataMap(addHosts_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addHostsIntoZone_result.class, metaDataMap); } - public addHosts_result() { + public addHostsIntoZone_result() { } - public addHosts_result( + public addHostsIntoZone_result( ExecResp success) { this(); this.success = success; @@ -15658,21 +16196,21 @@ public addHosts_result( /** * Performs a deep copy on other. */ - public addHosts_result(addHosts_result other) { + public addHostsIntoZone_result(addHostsIntoZone_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addHosts_result deepCopy() { - return new addHosts_result(this); + public addHostsIntoZone_result deepCopy() { + return new addHostsIntoZone_result(this); } public ExecResp getSuccess() { return this.success; } - public addHosts_result setSuccess(ExecResp success) { + public addHostsIntoZone_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -15723,9 +16261,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHosts_result)) + if (!(_that instanceof addHostsIntoZone_result)) return false; - addHosts_result that = (addHosts_result)_that; + addHostsIntoZone_result that = (addHostsIntoZone_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -15738,7 +16276,7 @@ public int hashCode() { } @Override - public int compareTo(addHosts_result other) { + public int compareTo(addHostsIntoZone_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15814,7 +16352,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHosts_result"); + StringBuilder sb = new StringBuilder("addHostsIntoZone_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -15841,11 +16379,11 @@ public void validate() throws TException { } - public static class addHostsIntoZone_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_args"); + public static class dropHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHosts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddHostsIntoZoneReq req; + public DropHostsReq req; public static final int REQ = 1; // isset id assignments @@ -15855,19 +16393,19 @@ public static class addHostsIntoZone_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddHostsIntoZoneReq.class))); + new StructMetaData(TType.STRUCT, DropHostsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addHostsIntoZone_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHosts_args.class, metaDataMap); } - public addHostsIntoZone_args() { + public dropHosts_args() { } - public addHostsIntoZone_args( - AddHostsIntoZoneReq req) { + public dropHosts_args( + DropHostsReq req) { this(); this.req = req; } @@ -15875,21 +16413,21 @@ public addHostsIntoZone_args( /** * Performs a deep copy on other. */ - public addHostsIntoZone_args(addHostsIntoZone_args other) { + public dropHosts_args(dropHosts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addHostsIntoZone_args deepCopy() { - return new addHostsIntoZone_args(this); + public dropHosts_args deepCopy() { + return new dropHosts_args(this); } - public AddHostsIntoZoneReq getReq() { + public DropHostsReq getReq() { return this.req; } - public addHostsIntoZone_args setReq(AddHostsIntoZoneReq req) { + public dropHosts_args setReq(DropHostsReq req) { this.req = req; return this; } @@ -15915,7 +16453,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddHostsIntoZoneReq)__value); + setReq((DropHostsReq)__value); } break; @@ -15940,9 +16478,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostsIntoZone_args)) + if (!(_that instanceof dropHosts_args)) return false; - addHostsIntoZone_args that = (addHostsIntoZone_args)_that; + dropHosts_args that = (dropHosts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -15955,7 +16493,7 @@ public int hashCode() { } @Override - public int compareTo(addHostsIntoZone_args other) { + public int compareTo(dropHosts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -15990,7 +16528,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddHostsIntoZoneReq(); + this.req = new DropHostsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -16032,7 +16570,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostsIntoZone_args"); + StringBuilder sb = new StringBuilder("dropHosts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -16059,8 +16597,8 @@ public void validate() throws TException { } - public static class addHostsIntoZone_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addHostsIntoZone_result"); + public static class dropHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropHosts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -16078,13 +16616,13 @@ public static class addHostsIntoZone_result implements TBase, java.io.Serializab } static { - FieldMetaData.addStructMetaDataMap(addHostsIntoZone_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropHosts_result.class, metaDataMap); } - public addHostsIntoZone_result() { + public dropHosts_result() { } - public addHostsIntoZone_result( + public dropHosts_result( ExecResp success) { this(); this.success = success; @@ -16093,21 +16631,21 @@ public addHostsIntoZone_result( /** * Performs a deep copy on other. */ - public addHostsIntoZone_result(addHostsIntoZone_result other) { + public dropHosts_result(dropHosts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addHostsIntoZone_result deepCopy() { - return new addHostsIntoZone_result(this); + public dropHosts_result deepCopy() { + return new dropHosts_result(this); } public ExecResp getSuccess() { return this.success; } - public addHostsIntoZone_result setSuccess(ExecResp success) { + public dropHosts_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -16158,9 +16696,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addHostsIntoZone_result)) + if (!(_that instanceof dropHosts_result)) return false; - addHostsIntoZone_result that = (addHostsIntoZone_result)_that; + dropHosts_result that = (dropHosts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -16173,7 +16711,7 @@ public int hashCode() { } @Override - public int compareTo(addHostsIntoZone_result other) { + public int compareTo(dropHosts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -16249,7 +16787,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addHostsIntoZone_result"); + StringBuilder sb = new StringBuilder("dropHosts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -16276,11 +16814,11 @@ public void validate() throws TException { } - public static class dropHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHosts_args"); + public static class listHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listHosts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropHostsReq req; + public ListHostsReq req; public static final int REQ = 1; // isset id assignments @@ -16290,19 +16828,19 @@ public static class dropHosts_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropHostsReq.class))); + new StructMetaData(TType.STRUCT, ListHostsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropHosts_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listHosts_args.class, metaDataMap); } - public dropHosts_args() { + public listHosts_args() { } - public dropHosts_args( - DropHostsReq req) { + public listHosts_args( + ListHostsReq req) { this(); this.req = req; } @@ -16310,21 +16848,21 @@ public dropHosts_args( /** * Performs a deep copy on other. */ - public dropHosts_args(dropHosts_args other) { + public listHosts_args(listHosts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropHosts_args deepCopy() { - return new dropHosts_args(this); + public listHosts_args deepCopy() { + return new listHosts_args(this); } - public DropHostsReq getReq() { + public ListHostsReq getReq() { return this.req; } - public dropHosts_args setReq(DropHostsReq req) { + public listHosts_args setReq(ListHostsReq req) { this.req = req; return this; } @@ -16350,7 +16888,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropHostsReq)__value); + setReq((ListHostsReq)__value); } break; @@ -16375,9 +16913,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropHosts_args)) + if (!(_that instanceof listHosts_args)) return false; - dropHosts_args that = (dropHosts_args)_that; + listHosts_args that = (listHosts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -16390,7 +16928,7 @@ public int hashCode() { } @Override - public int compareTo(dropHosts_args other) { + public int compareTo(listHosts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -16425,7 +16963,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropHostsReq(); + this.req = new ListHostsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -16467,7 +17005,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHosts_args"); + StringBuilder sb = new StringBuilder("listHosts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -16494,11 +17032,11 @@ public void validate() throws TException { } - public static class dropHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropHosts_result"); + public static class listHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listHosts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListHostsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -16508,19 +17046,19 @@ public static class dropHosts_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListHostsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropHosts_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listHosts_result.class, metaDataMap); } - public dropHosts_result() { + public listHosts_result() { } - public dropHosts_result( - ExecResp success) { + public listHosts_result( + ListHostsResp success) { this(); this.success = success; } @@ -16528,21 +17066,21 @@ public dropHosts_result( /** * Performs a deep copy on other. */ - public dropHosts_result(dropHosts_result other) { + public listHosts_result(listHosts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropHosts_result deepCopy() { - return new dropHosts_result(this); + public listHosts_result deepCopy() { + return new listHosts_result(this); } - public ExecResp getSuccess() { + public ListHostsResp getSuccess() { return this.success; } - public dropHosts_result setSuccess(ExecResp success) { + public listHosts_result setSuccess(ListHostsResp success) { this.success = success; return this; } @@ -16568,7 +17106,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListHostsResp)__value); } break; @@ -16593,9 +17131,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropHosts_result)) + if (!(_that instanceof listHosts_result)) return false; - dropHosts_result that = (dropHosts_result)_that; + listHosts_result that = (listHosts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -16608,7 +17146,7 @@ public int hashCode() { } @Override - public int compareTo(dropHosts_result other) { + public int compareTo(listHosts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -16643,7 +17181,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListHostsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -16684,7 +17222,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropHosts_result"); + StringBuilder sb = new StringBuilder("listHosts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -16711,11 +17249,11 @@ public void validate() throws TException { } - public static class listHosts_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listHosts_args"); + public static class getPartsAlloc_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getPartsAlloc_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListHostsReq req; + public GetPartsAllocReq req; public static final int REQ = 1; // isset id assignments @@ -16725,19 +17263,19 @@ public static class listHosts_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListHostsReq.class))); + new StructMetaData(TType.STRUCT, GetPartsAllocReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listHosts_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getPartsAlloc_args.class, metaDataMap); } - public listHosts_args() { + public getPartsAlloc_args() { } - public listHosts_args( - ListHostsReq req) { + public getPartsAlloc_args( + GetPartsAllocReq req) { this(); this.req = req; } @@ -16745,21 +17283,21 @@ public listHosts_args( /** * Performs a deep copy on other. */ - public listHosts_args(listHosts_args other) { + public getPartsAlloc_args(getPartsAlloc_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listHosts_args deepCopy() { - return new listHosts_args(this); + public getPartsAlloc_args deepCopy() { + return new getPartsAlloc_args(this); } - public ListHostsReq getReq() { + public GetPartsAllocReq getReq() { return this.req; } - public listHosts_args setReq(ListHostsReq req) { + public getPartsAlloc_args setReq(GetPartsAllocReq req) { this.req = req; return this; } @@ -16785,7 +17323,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListHostsReq)__value); + setReq((GetPartsAllocReq)__value); } break; @@ -16810,9 +17348,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listHosts_args)) + if (!(_that instanceof getPartsAlloc_args)) return false; - listHosts_args that = (listHosts_args)_that; + getPartsAlloc_args that = (getPartsAlloc_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -16825,7 +17363,7 @@ public int hashCode() { } @Override - public int compareTo(listHosts_args other) { + public int compareTo(getPartsAlloc_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -16860,7 +17398,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListHostsReq(); + this.req = new GetPartsAllocReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -16902,7 +17440,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listHosts_args"); + StringBuilder sb = new StringBuilder("getPartsAlloc_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -16929,11 +17467,11 @@ public void validate() throws TException { } - public static class listHosts_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listHosts_result"); + public static class getPartsAlloc_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getPartsAlloc_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListHostsResp success; + public GetPartsAllocResp success; public static final int SUCCESS = 0; // isset id assignments @@ -16943,19 +17481,19 @@ public static class listHosts_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListHostsResp.class))); + new StructMetaData(TType.STRUCT, GetPartsAllocResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listHosts_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getPartsAlloc_result.class, metaDataMap); } - public listHosts_result() { + public getPartsAlloc_result() { } - public listHosts_result( - ListHostsResp success) { + public getPartsAlloc_result( + GetPartsAllocResp success) { this(); this.success = success; } @@ -16963,21 +17501,21 @@ public listHosts_result( /** * Performs a deep copy on other. */ - public listHosts_result(listHosts_result other) { + public getPartsAlloc_result(getPartsAlloc_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listHosts_result deepCopy() { - return new listHosts_result(this); + public getPartsAlloc_result deepCopy() { + return new getPartsAlloc_result(this); } - public ListHostsResp getSuccess() { + public GetPartsAllocResp getSuccess() { return this.success; } - public listHosts_result setSuccess(ListHostsResp success) { + public getPartsAlloc_result setSuccess(GetPartsAllocResp success) { this.success = success; return this; } @@ -17003,7 +17541,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListHostsResp)__value); + setSuccess((GetPartsAllocResp)__value); } break; @@ -17028,9 +17566,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listHosts_result)) + if (!(_that instanceof getPartsAlloc_result)) return false; - listHosts_result that = (listHosts_result)_that; + getPartsAlloc_result that = (getPartsAlloc_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -17043,7 +17581,7 @@ public int hashCode() { } @Override - public int compareTo(listHosts_result other) { + public int compareTo(getPartsAlloc_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -17078,7 +17616,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListHostsResp(); + this.success = new GetPartsAllocResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -17119,7 +17657,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listHosts_result"); + StringBuilder sb = new StringBuilder("getPartsAlloc_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -17146,11 +17684,11 @@ public void validate() throws TException { } - public static class getPartsAlloc_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getPartsAlloc_args"); + public static class listParts_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listParts_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetPartsAllocReq req; + public ListPartsReq req; public static final int REQ = 1; // isset id assignments @@ -17160,19 +17698,19 @@ public static class getPartsAlloc_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetPartsAllocReq.class))); + new StructMetaData(TType.STRUCT, ListPartsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getPartsAlloc_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listParts_args.class, metaDataMap); } - public getPartsAlloc_args() { + public listParts_args() { } - public getPartsAlloc_args( - GetPartsAllocReq req) { + public listParts_args( + ListPartsReq req) { this(); this.req = req; } @@ -17180,21 +17718,21 @@ public getPartsAlloc_args( /** * Performs a deep copy on other. */ - public getPartsAlloc_args(getPartsAlloc_args other) { + public listParts_args(listParts_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getPartsAlloc_args deepCopy() { - return new getPartsAlloc_args(this); + public listParts_args deepCopy() { + return new listParts_args(this); } - public GetPartsAllocReq getReq() { + public ListPartsReq getReq() { return this.req; } - public getPartsAlloc_args setReq(GetPartsAllocReq req) { + public listParts_args setReq(ListPartsReq req) { this.req = req; return this; } @@ -17220,7 +17758,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetPartsAllocReq)__value); + setReq((ListPartsReq)__value); } break; @@ -17245,9 +17783,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getPartsAlloc_args)) + if (!(_that instanceof listParts_args)) return false; - getPartsAlloc_args that = (getPartsAlloc_args)_that; + listParts_args that = (listParts_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -17260,7 +17798,7 @@ public int hashCode() { } @Override - public int compareTo(getPartsAlloc_args other) { + public int compareTo(listParts_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -17295,7 +17833,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetPartsAllocReq(); + this.req = new ListPartsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -17337,7 +17875,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getPartsAlloc_args"); + StringBuilder sb = new StringBuilder("listParts_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -17364,11 +17902,11 @@ public void validate() throws TException { } - public static class getPartsAlloc_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getPartsAlloc_result"); + public static class listParts_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listParts_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetPartsAllocResp success; + public ListPartsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -17378,19 +17916,19 @@ public static class getPartsAlloc_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetPartsAllocResp.class))); + new StructMetaData(TType.STRUCT, ListPartsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getPartsAlloc_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listParts_result.class, metaDataMap); } - public getPartsAlloc_result() { + public listParts_result() { } - public getPartsAlloc_result( - GetPartsAllocResp success) { + public listParts_result( + ListPartsResp success) { this(); this.success = success; } @@ -17398,21 +17936,21 @@ public getPartsAlloc_result( /** * Performs a deep copy on other. */ - public getPartsAlloc_result(getPartsAlloc_result other) { + public listParts_result(listParts_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getPartsAlloc_result deepCopy() { - return new getPartsAlloc_result(this); + public listParts_result deepCopy() { + return new listParts_result(this); } - public GetPartsAllocResp getSuccess() { + public ListPartsResp getSuccess() { return this.success; } - public getPartsAlloc_result setSuccess(GetPartsAllocResp success) { + public listParts_result setSuccess(ListPartsResp success) { this.success = success; return this; } @@ -17438,7 +17976,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetPartsAllocResp)__value); + setSuccess((ListPartsResp)__value); } break; @@ -17463,9 +18001,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getPartsAlloc_result)) + if (!(_that instanceof listParts_result)) return false; - getPartsAlloc_result that = (getPartsAlloc_result)_that; + listParts_result that = (listParts_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -17478,7 +18016,7 @@ public int hashCode() { } @Override - public int compareTo(getPartsAlloc_result other) { + public int compareTo(listParts_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -17513,7 +18051,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetPartsAllocResp(); + this.success = new ListPartsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -17554,7 +18092,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getPartsAlloc_result"); + StringBuilder sb = new StringBuilder("listParts_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -17581,11 +18119,11 @@ public void validate() throws TException { } - public static class listParts_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listParts_args"); + public static class multiPut_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("multiPut_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListPartsReq req; + public MultiPutReq req; public static final int REQ = 1; // isset id assignments @@ -17595,19 +18133,19 @@ public static class listParts_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListPartsReq.class))); + new StructMetaData(TType.STRUCT, MultiPutReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listParts_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(multiPut_args.class, metaDataMap); } - public listParts_args() { + public multiPut_args() { } - public listParts_args( - ListPartsReq req) { + public multiPut_args( + MultiPutReq req) { this(); this.req = req; } @@ -17615,21 +18153,21 @@ public listParts_args( /** * Performs a deep copy on other. */ - public listParts_args(listParts_args other) { + public multiPut_args(multiPut_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listParts_args deepCopy() { - return new listParts_args(this); + public multiPut_args deepCopy() { + return new multiPut_args(this); } - public ListPartsReq getReq() { + public MultiPutReq getReq() { return this.req; } - public listParts_args setReq(ListPartsReq req) { + public multiPut_args setReq(MultiPutReq req) { this.req = req; return this; } @@ -17655,7 +18193,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListPartsReq)__value); + setReq((MultiPutReq)__value); } break; @@ -17680,9 +18218,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listParts_args)) + if (!(_that instanceof multiPut_args)) return false; - listParts_args that = (listParts_args)_that; + multiPut_args that = (multiPut_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -17695,7 +18233,7 @@ public int hashCode() { } @Override - public int compareTo(listParts_args other) { + public int compareTo(multiPut_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -17730,7 +18268,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListPartsReq(); + this.req = new MultiPutReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -17772,7 +18310,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listParts_args"); + StringBuilder sb = new StringBuilder("multiPut_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -17799,11 +18337,11 @@ public void validate() throws TException { } - public static class listParts_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listParts_result"); + public static class multiPut_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("multiPut_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListPartsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -17813,19 +18351,19 @@ public static class listParts_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListPartsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listParts_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(multiPut_result.class, metaDataMap); } - public listParts_result() { + public multiPut_result() { } - public listParts_result( - ListPartsResp success) { + public multiPut_result( + ExecResp success) { this(); this.success = success; } @@ -17833,21 +18371,21 @@ public listParts_result( /** * Performs a deep copy on other. */ - public listParts_result(listParts_result other) { + public multiPut_result(multiPut_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listParts_result deepCopy() { - return new listParts_result(this); + public multiPut_result deepCopy() { + return new multiPut_result(this); } - public ListPartsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listParts_result setSuccess(ListPartsResp success) { + public multiPut_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -17873,7 +18411,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListPartsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -17898,9 +18436,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listParts_result)) + if (!(_that instanceof multiPut_result)) return false; - listParts_result that = (listParts_result)_that; + multiPut_result that = (multiPut_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -17913,7 +18451,7 @@ public int hashCode() { } @Override - public int compareTo(listParts_result other) { + public int compareTo(multiPut_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -17948,7 +18486,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListPartsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -17989,7 +18527,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listParts_result"); + StringBuilder sb = new StringBuilder("multiPut_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -18016,11 +18554,11 @@ public void validate() throws TException { } - public static class multiPut_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("multiPut_args"); + public static class get_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("get_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public MultiPutReq req; + public GetReq req; public static final int REQ = 1; // isset id assignments @@ -18030,19 +18568,19 @@ public static class multiPut_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, MultiPutReq.class))); + new StructMetaData(TType.STRUCT, GetReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(multiPut_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(get_args.class, metaDataMap); } - public multiPut_args() { + public get_args() { } - public multiPut_args( - MultiPutReq req) { + public get_args( + GetReq req) { this(); this.req = req; } @@ -18050,21 +18588,21 @@ public multiPut_args( /** * Performs a deep copy on other. */ - public multiPut_args(multiPut_args other) { + public get_args(get_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public multiPut_args deepCopy() { - return new multiPut_args(this); + public get_args deepCopy() { + return new get_args(this); } - public MultiPutReq getReq() { + public GetReq getReq() { return this.req; } - public multiPut_args setReq(MultiPutReq req) { + public get_args setReq(GetReq req) { this.req = req; return this; } @@ -18090,7 +18628,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((MultiPutReq)__value); + setReq((GetReq)__value); } break; @@ -18115,9 +18653,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof multiPut_args)) + if (!(_that instanceof get_args)) return false; - multiPut_args that = (multiPut_args)_that; + get_args that = (get_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -18130,7 +18668,7 @@ public int hashCode() { } @Override - public int compareTo(multiPut_args other) { + public int compareTo(get_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -18165,7 +18703,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new MultiPutReq(); + this.req = new GetReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -18207,7 +18745,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("multiPut_args"); + StringBuilder sb = new StringBuilder("get_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -18234,11 +18772,11 @@ public void validate() throws TException { } - public static class multiPut_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("multiPut_result"); + public static class get_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("get_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetResp success; public static final int SUCCESS = 0; // isset id assignments @@ -18248,19 +18786,19 @@ public static class multiPut_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(multiPut_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(get_result.class, metaDataMap); } - public multiPut_result() { + public get_result() { } - public multiPut_result( - ExecResp success) { + public get_result( + GetResp success) { this(); this.success = success; } @@ -18268,21 +18806,21 @@ public multiPut_result( /** * Performs a deep copy on other. */ - public multiPut_result(multiPut_result other) { + public get_result(get_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public multiPut_result deepCopy() { - return new multiPut_result(this); + public get_result deepCopy() { + return new get_result(this); } - public ExecResp getSuccess() { + public GetResp getSuccess() { return this.success; } - public multiPut_result setSuccess(ExecResp success) { + public get_result setSuccess(GetResp success) { this.success = success; return this; } @@ -18308,7 +18846,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetResp)__value); } break; @@ -18333,9 +18871,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof multiPut_result)) + if (!(_that instanceof get_result)) return false; - multiPut_result that = (multiPut_result)_that; + get_result that = (get_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -18348,7 +18886,7 @@ public int hashCode() { } @Override - public int compareTo(multiPut_result other) { + public int compareTo(get_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -18383,7 +18921,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -18424,7 +18962,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("multiPut_result"); + StringBuilder sb = new StringBuilder("get_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -18451,11 +18989,11 @@ public void validate() throws TException { } - public static class get_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("get_args"); + public static class multiGet_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("multiGet_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetReq req; + public MultiGetReq req; public static final int REQ = 1; // isset id assignments @@ -18465,19 +19003,19 @@ public static class get_args implements TBase, java.io.Serializable, Cloneable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetReq.class))); + new StructMetaData(TType.STRUCT, MultiGetReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(get_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(multiGet_args.class, metaDataMap); } - public get_args() { + public multiGet_args() { } - public get_args( - GetReq req) { + public multiGet_args( + MultiGetReq req) { this(); this.req = req; } @@ -18485,21 +19023,21 @@ public get_args( /** * Performs a deep copy on other. */ - public get_args(get_args other) { + public multiGet_args(multiGet_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public get_args deepCopy() { - return new get_args(this); + public multiGet_args deepCopy() { + return new multiGet_args(this); } - public GetReq getReq() { + public MultiGetReq getReq() { return this.req; } - public get_args setReq(GetReq req) { + public multiGet_args setReq(MultiGetReq req) { this.req = req; return this; } @@ -18525,7 +19063,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetReq)__value); + setReq((MultiGetReq)__value); } break; @@ -18550,9 +19088,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof get_args)) + if (!(_that instanceof multiGet_args)) return false; - get_args that = (get_args)_that; + multiGet_args that = (multiGet_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -18565,7 +19103,7 @@ public int hashCode() { } @Override - public int compareTo(get_args other) { + public int compareTo(multiGet_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -18600,7 +19138,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetReq(); + this.req = new MultiGetReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -18642,7 +19180,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("get_args"); + StringBuilder sb = new StringBuilder("multiGet_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -18669,11 +19207,11 @@ public void validate() throws TException { } - public static class get_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("get_result"); + public static class multiGet_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("multiGet_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetResp success; + public MultiGetResp success; public static final int SUCCESS = 0; // isset id assignments @@ -18683,19 +19221,19 @@ public static class get_result implements TBase, java.io.Serializable, Cloneable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetResp.class))); + new StructMetaData(TType.STRUCT, MultiGetResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(get_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(multiGet_result.class, metaDataMap); } - public get_result() { + public multiGet_result() { } - public get_result( - GetResp success) { + public multiGet_result( + MultiGetResp success) { this(); this.success = success; } @@ -18703,21 +19241,21 @@ public get_result( /** * Performs a deep copy on other. */ - public get_result(get_result other) { + public multiGet_result(multiGet_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public get_result deepCopy() { - return new get_result(this); + public multiGet_result deepCopy() { + return new multiGet_result(this); } - public GetResp getSuccess() { + public MultiGetResp getSuccess() { return this.success; } - public get_result setSuccess(GetResp success) { + public multiGet_result setSuccess(MultiGetResp success) { this.success = success; return this; } @@ -18743,7 +19281,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetResp)__value); + setSuccess((MultiGetResp)__value); } break; @@ -18768,9 +19306,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof get_result)) + if (!(_that instanceof multiGet_result)) return false; - get_result that = (get_result)_that; + multiGet_result that = (multiGet_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -18783,7 +19321,7 @@ public int hashCode() { } @Override - public int compareTo(get_result other) { + public int compareTo(multiGet_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -18818,7 +19356,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetResp(); + this.success = new MultiGetResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -18859,7 +19397,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("get_result"); + StringBuilder sb = new StringBuilder("multiGet_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -18886,11 +19424,11 @@ public void validate() throws TException { } - public static class multiGet_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("multiGet_args"); + public static class remove_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("remove_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public MultiGetReq req; + public RemoveReq req; public static final int REQ = 1; // isset id assignments @@ -18900,19 +19438,19 @@ public static class multiGet_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, MultiGetReq.class))); + new StructMetaData(TType.STRUCT, RemoveReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(multiGet_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(remove_args.class, metaDataMap); } - public multiGet_args() { + public remove_args() { } - public multiGet_args( - MultiGetReq req) { + public remove_args( + RemoveReq req) { this(); this.req = req; } @@ -18920,21 +19458,21 @@ public multiGet_args( /** * Performs a deep copy on other. */ - public multiGet_args(multiGet_args other) { + public remove_args(remove_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public multiGet_args deepCopy() { - return new multiGet_args(this); + public remove_args deepCopy() { + return new remove_args(this); } - public MultiGetReq getReq() { + public RemoveReq getReq() { return this.req; } - public multiGet_args setReq(MultiGetReq req) { + public remove_args setReq(RemoveReq req) { this.req = req; return this; } @@ -18960,7 +19498,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((MultiGetReq)__value); + setReq((RemoveReq)__value); } break; @@ -18985,9 +19523,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof multiGet_args)) + if (!(_that instanceof remove_args)) return false; - multiGet_args that = (multiGet_args)_that; + remove_args that = (remove_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -19000,7 +19538,7 @@ public int hashCode() { } @Override - public int compareTo(multiGet_args other) { + public int compareTo(remove_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -19035,7 +19573,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new MultiGetReq(); + this.req = new RemoveReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -19077,7 +19615,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("multiGet_args"); + StringBuilder sb = new StringBuilder("remove_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -19104,11 +19642,11 @@ public void validate() throws TException { } - public static class multiGet_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("multiGet_result"); + public static class remove_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("remove_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public MultiGetResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -19118,19 +19656,19 @@ public static class multiGet_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, MultiGetResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(multiGet_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(remove_result.class, metaDataMap); } - public multiGet_result() { + public remove_result() { } - public multiGet_result( - MultiGetResp success) { + public remove_result( + ExecResp success) { this(); this.success = success; } @@ -19138,21 +19676,21 @@ public multiGet_result( /** * Performs a deep copy on other. */ - public multiGet_result(multiGet_result other) { + public remove_result(remove_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public multiGet_result deepCopy() { - return new multiGet_result(this); + public remove_result deepCopy() { + return new remove_result(this); } - public MultiGetResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public multiGet_result setSuccess(MultiGetResp success) { + public remove_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -19178,7 +19716,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((MultiGetResp)__value); + setSuccess((ExecResp)__value); } break; @@ -19203,9 +19741,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof multiGet_result)) + if (!(_that instanceof remove_result)) return false; - multiGet_result that = (multiGet_result)_that; + remove_result that = (remove_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -19218,7 +19756,7 @@ public int hashCode() { } @Override - public int compareTo(multiGet_result other) { + public int compareTo(remove_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -19253,7 +19791,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new MultiGetResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -19294,7 +19832,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("multiGet_result"); + StringBuilder sb = new StringBuilder("remove_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -19321,11 +19859,11 @@ public void validate() throws TException { } - public static class remove_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("remove_args"); + public static class removeRange_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeRange_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RemoveReq req; + public RemoveRangeReq req; public static final int REQ = 1; // isset id assignments @@ -19335,19 +19873,19 @@ public static class remove_args implements TBase, java.io.Serializable, Cloneabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RemoveReq.class))); + new StructMetaData(TType.STRUCT, RemoveRangeReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(remove_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeRange_args.class, metaDataMap); } - public remove_args() { + public removeRange_args() { } - public remove_args( - RemoveReq req) { + public removeRange_args( + RemoveRangeReq req) { this(); this.req = req; } @@ -19355,21 +19893,21 @@ public remove_args( /** * Performs a deep copy on other. */ - public remove_args(remove_args other) { + public removeRange_args(removeRange_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public remove_args deepCopy() { - return new remove_args(this); + public removeRange_args deepCopy() { + return new removeRange_args(this); } - public RemoveReq getReq() { + public RemoveRangeReq getReq() { return this.req; } - public remove_args setReq(RemoveReq req) { + public removeRange_args setReq(RemoveRangeReq req) { this.req = req; return this; } @@ -19395,7 +19933,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RemoveReq)__value); + setReq((RemoveRangeReq)__value); } break; @@ -19420,9 +19958,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof remove_args)) + if (!(_that instanceof removeRange_args)) return false; - remove_args that = (remove_args)_that; + removeRange_args that = (removeRange_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -19435,7 +19973,7 @@ public int hashCode() { } @Override - public int compareTo(remove_args other) { + public int compareTo(removeRange_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -19470,7 +20008,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RemoveReq(); + this.req = new RemoveRangeReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -19512,7 +20050,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("remove_args"); + StringBuilder sb = new StringBuilder("removeRange_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -19539,8 +20077,8 @@ public void validate() throws TException { } - public static class remove_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("remove_result"); + public static class removeRange_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeRange_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -19558,13 +20096,13 @@ public static class remove_result implements TBase, java.io.Serializable, Clonea } static { - FieldMetaData.addStructMetaDataMap(remove_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeRange_result.class, metaDataMap); } - public remove_result() { + public removeRange_result() { } - public remove_result( + public removeRange_result( ExecResp success) { this(); this.success = success; @@ -19573,21 +20111,21 @@ public remove_result( /** * Performs a deep copy on other. */ - public remove_result(remove_result other) { + public removeRange_result(removeRange_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public remove_result deepCopy() { - return new remove_result(this); + public removeRange_result deepCopy() { + return new removeRange_result(this); } public ExecResp getSuccess() { return this.success; } - public remove_result setSuccess(ExecResp success) { + public removeRange_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -19638,9 +20176,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof remove_result)) + if (!(_that instanceof removeRange_result)) return false; - remove_result that = (remove_result)_that; + removeRange_result that = (removeRange_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -19653,7 +20191,7 @@ public int hashCode() { } @Override - public int compareTo(remove_result other) { + public int compareTo(removeRange_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -19729,7 +20267,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("remove_result"); + StringBuilder sb = new StringBuilder("removeRange_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -19756,11 +20294,11 @@ public void validate() throws TException { } - public static class removeRange_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeRange_args"); + public static class scan_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("scan_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RemoveRangeReq req; + public ScanReq req; public static final int REQ = 1; // isset id assignments @@ -19770,19 +20308,19 @@ public static class removeRange_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RemoveRangeReq.class))); + new StructMetaData(TType.STRUCT, ScanReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(removeRange_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(scan_args.class, metaDataMap); } - public removeRange_args() { + public scan_args() { } - public removeRange_args( - RemoveRangeReq req) { + public scan_args( + ScanReq req) { this(); this.req = req; } @@ -19790,21 +20328,21 @@ public removeRange_args( /** * Performs a deep copy on other. */ - public removeRange_args(removeRange_args other) { + public scan_args(scan_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public removeRange_args deepCopy() { - return new removeRange_args(this); + public scan_args deepCopy() { + return new scan_args(this); } - public RemoveRangeReq getReq() { + public ScanReq getReq() { return this.req; } - public removeRange_args setReq(RemoveRangeReq req) { + public scan_args setReq(ScanReq req) { this.req = req; return this; } @@ -19830,7 +20368,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RemoveRangeReq)__value); + setReq((ScanReq)__value); } break; @@ -19855,9 +20393,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeRange_args)) + if (!(_that instanceof scan_args)) return false; - removeRange_args that = (removeRange_args)_that; + scan_args that = (scan_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -19870,7 +20408,7 @@ public int hashCode() { } @Override - public int compareTo(removeRange_args other) { + public int compareTo(scan_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -19905,7 +20443,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RemoveRangeReq(); + this.req = new ScanReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -19947,7 +20485,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeRange_args"); + StringBuilder sb = new StringBuilder("scan_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -19974,11 +20512,11 @@ public void validate() throws TException { } - public static class removeRange_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeRange_result"); + public static class scan_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("scan_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ScanResp success; public static final int SUCCESS = 0; // isset id assignments @@ -19988,19 +20526,19 @@ public static class removeRange_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ScanResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(removeRange_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(scan_result.class, metaDataMap); } - public removeRange_result() { + public scan_result() { } - public removeRange_result( - ExecResp success) { + public scan_result( + ScanResp success) { this(); this.success = success; } @@ -20008,21 +20546,21 @@ public removeRange_result( /** * Performs a deep copy on other. */ - public removeRange_result(removeRange_result other) { + public scan_result(scan_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public removeRange_result deepCopy() { - return new removeRange_result(this); + public scan_result deepCopy() { + return new scan_result(this); } - public ExecResp getSuccess() { + public ScanResp getSuccess() { return this.success; } - public removeRange_result setSuccess(ExecResp success) { + public scan_result setSuccess(ScanResp success) { this.success = success; return this; } @@ -20048,7 +20586,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ScanResp)__value); } break; @@ -20073,9 +20611,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeRange_result)) + if (!(_that instanceof scan_result)) return false; - removeRange_result that = (removeRange_result)_that; + scan_result that = (scan_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -20088,7 +20626,7 @@ public int hashCode() { } @Override - public int compareTo(removeRange_result other) { + public int compareTo(scan_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -20123,7 +20661,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ScanResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -20164,7 +20702,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeRange_result"); + StringBuilder sb = new StringBuilder("scan_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -20191,11 +20729,11 @@ public void validate() throws TException { } - public static class scan_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("scan_args"); + public static class createTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTagIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ScanReq req; + public CreateTagIndexReq req; public static final int REQ = 1; // isset id assignments @@ -20205,19 +20743,19 @@ public static class scan_args implements TBase, java.io.Serializable, Cloneable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ScanReq.class))); + new StructMetaData(TType.STRUCT, CreateTagIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(scan_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createTagIndex_args.class, metaDataMap); } - public scan_args() { + public createTagIndex_args() { } - public scan_args( - ScanReq req) { + public createTagIndex_args( + CreateTagIndexReq req) { this(); this.req = req; } @@ -20225,21 +20763,21 @@ public scan_args( /** * Performs a deep copy on other. */ - public scan_args(scan_args other) { + public createTagIndex_args(createTagIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public scan_args deepCopy() { - return new scan_args(this); + public createTagIndex_args deepCopy() { + return new createTagIndex_args(this); } - public ScanReq getReq() { + public CreateTagIndexReq getReq() { return this.req; } - public scan_args setReq(ScanReq req) { + public createTagIndex_args setReq(CreateTagIndexReq req) { this.req = req; return this; } @@ -20265,7 +20803,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ScanReq)__value); + setReq((CreateTagIndexReq)__value); } break; @@ -20290,9 +20828,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof scan_args)) + if (!(_that instanceof createTagIndex_args)) return false; - scan_args that = (scan_args)_that; + createTagIndex_args that = (createTagIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -20305,7 +20843,7 @@ public int hashCode() { } @Override - public int compareTo(scan_args other) { + public int compareTo(createTagIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -20340,7 +20878,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ScanReq(); + this.req = new CreateTagIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -20382,7 +20920,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("scan_args"); + StringBuilder sb = new StringBuilder("createTagIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -20409,11 +20947,11 @@ public void validate() throws TException { } - public static class scan_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("scan_result"); + public static class createTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createTagIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ScanResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -20423,19 +20961,19 @@ public static class scan_result implements TBase, java.io.Serializable, Cloneabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ScanResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(scan_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createTagIndex_result.class, metaDataMap); } - public scan_result() { + public createTagIndex_result() { } - public scan_result( - ScanResp success) { + public createTagIndex_result( + ExecResp success) { this(); this.success = success; } @@ -20443,21 +20981,21 @@ public scan_result( /** * Performs a deep copy on other. */ - public scan_result(scan_result other) { + public createTagIndex_result(createTagIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public scan_result deepCopy() { - return new scan_result(this); + public createTagIndex_result deepCopy() { + return new createTagIndex_result(this); } - public ScanResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public scan_result setSuccess(ScanResp success) { + public createTagIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -20483,7 +21021,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ScanResp)__value); + setSuccess((ExecResp)__value); } break; @@ -20508,9 +21046,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof scan_result)) + if (!(_that instanceof createTagIndex_result)) return false; - scan_result that = (scan_result)_that; + createTagIndex_result that = (createTagIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -20523,7 +21061,7 @@ public int hashCode() { } @Override - public int compareTo(scan_result other) { + public int compareTo(createTagIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -20558,7 +21096,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ScanResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -20599,7 +21137,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("scan_result"); + StringBuilder sb = new StringBuilder("createTagIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -20626,11 +21164,11 @@ public void validate() throws TException { } - public static class createTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTagIndex_args"); + public static class dropTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTagIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateTagIndexReq req; + public DropTagIndexReq req; public static final int REQ = 1; // isset id assignments @@ -20640,19 +21178,19 @@ public static class createTagIndex_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateTagIndexReq.class))); + new StructMetaData(TType.STRUCT, DropTagIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createTagIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTagIndex_args.class, metaDataMap); } - public createTagIndex_args() { + public dropTagIndex_args() { } - public createTagIndex_args( - CreateTagIndexReq req) { + public dropTagIndex_args( + DropTagIndexReq req) { this(); this.req = req; } @@ -20660,21 +21198,21 @@ public createTagIndex_args( /** * Performs a deep copy on other. */ - public createTagIndex_args(createTagIndex_args other) { + public dropTagIndex_args(dropTagIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createTagIndex_args deepCopy() { - return new createTagIndex_args(this); + public dropTagIndex_args deepCopy() { + return new dropTagIndex_args(this); } - public CreateTagIndexReq getReq() { + public DropTagIndexReq getReq() { return this.req; } - public createTagIndex_args setReq(CreateTagIndexReq req) { + public dropTagIndex_args setReq(DropTagIndexReq req) { this.req = req; return this; } @@ -20700,7 +21238,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateTagIndexReq)__value); + setReq((DropTagIndexReq)__value); } break; @@ -20725,9 +21263,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTagIndex_args)) + if (!(_that instanceof dropTagIndex_args)) return false; - createTagIndex_args that = (createTagIndex_args)_that; + dropTagIndex_args that = (dropTagIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -20740,7 +21278,7 @@ public int hashCode() { } @Override - public int compareTo(createTagIndex_args other) { + public int compareTo(dropTagIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -20775,7 +21313,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateTagIndexReq(); + this.req = new DropTagIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -20817,7 +21355,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTagIndex_args"); + StringBuilder sb = new StringBuilder("dropTagIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -20844,8 +21382,8 @@ public void validate() throws TException { } - public static class createTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createTagIndex_result"); + public static class dropTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropTagIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -20863,13 +21401,13 @@ public static class createTagIndex_result implements TBase, java.io.Serializable } static { - FieldMetaData.addStructMetaDataMap(createTagIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropTagIndex_result.class, metaDataMap); } - public createTagIndex_result() { + public dropTagIndex_result() { } - public createTagIndex_result( + public dropTagIndex_result( ExecResp success) { this(); this.success = success; @@ -20878,21 +21416,21 @@ public createTagIndex_result( /** * Performs a deep copy on other. */ - public createTagIndex_result(createTagIndex_result other) { + public dropTagIndex_result(dropTagIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createTagIndex_result deepCopy() { - return new createTagIndex_result(this); + public dropTagIndex_result deepCopy() { + return new dropTagIndex_result(this); } public ExecResp getSuccess() { return this.success; } - public createTagIndex_result setSuccess(ExecResp success) { + public dropTagIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -20943,9 +21481,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createTagIndex_result)) + if (!(_that instanceof dropTagIndex_result)) return false; - createTagIndex_result that = (createTagIndex_result)_that; + dropTagIndex_result that = (dropTagIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -20958,7 +21496,7 @@ public int hashCode() { } @Override - public int compareTo(createTagIndex_result other) { + public int compareTo(dropTagIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -21034,7 +21572,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createTagIndex_result"); + StringBuilder sb = new StringBuilder("dropTagIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -21061,11 +21599,11 @@ public void validate() throws TException { } - public static class dropTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTagIndex_args"); + public static class getTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTagIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropTagIndexReq req; + public GetTagIndexReq req; public static final int REQ = 1; // isset id assignments @@ -21075,19 +21613,19 @@ public static class dropTagIndex_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropTagIndexReq.class))); + new StructMetaData(TType.STRUCT, GetTagIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropTagIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTagIndex_args.class, metaDataMap); } - public dropTagIndex_args() { + public getTagIndex_args() { } - public dropTagIndex_args( - DropTagIndexReq req) { + public getTagIndex_args( + GetTagIndexReq req) { this(); this.req = req; } @@ -21095,21 +21633,21 @@ public dropTagIndex_args( /** * Performs a deep copy on other. */ - public dropTagIndex_args(dropTagIndex_args other) { + public getTagIndex_args(getTagIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropTagIndex_args deepCopy() { - return new dropTagIndex_args(this); + public getTagIndex_args deepCopy() { + return new getTagIndex_args(this); } - public DropTagIndexReq getReq() { + public GetTagIndexReq getReq() { return this.req; } - public dropTagIndex_args setReq(DropTagIndexReq req) { + public getTagIndex_args setReq(GetTagIndexReq req) { this.req = req; return this; } @@ -21135,7 +21673,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropTagIndexReq)__value); + setReq((GetTagIndexReq)__value); } break; @@ -21160,9 +21698,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTagIndex_args)) + if (!(_that instanceof getTagIndex_args)) return false; - dropTagIndex_args that = (dropTagIndex_args)_that; + getTagIndex_args that = (getTagIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -21175,7 +21713,7 @@ public int hashCode() { } @Override - public int compareTo(dropTagIndex_args other) { + public int compareTo(getTagIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -21210,7 +21748,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropTagIndexReq(); + this.req = new GetTagIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -21252,7 +21790,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTagIndex_args"); + StringBuilder sb = new StringBuilder("getTagIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -21279,11 +21817,11 @@ public void validate() throws TException { } - public static class dropTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropTagIndex_result"); + public static class getTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getTagIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetTagIndexResp success; public static final int SUCCESS = 0; // isset id assignments @@ -21293,19 +21831,19 @@ public static class dropTagIndex_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetTagIndexResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropTagIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getTagIndex_result.class, metaDataMap); } - public dropTagIndex_result() { + public getTagIndex_result() { } - public dropTagIndex_result( - ExecResp success) { + public getTagIndex_result( + GetTagIndexResp success) { this(); this.success = success; } @@ -21313,21 +21851,21 @@ public dropTagIndex_result( /** * Performs a deep copy on other. */ - public dropTagIndex_result(dropTagIndex_result other) { + public getTagIndex_result(getTagIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropTagIndex_result deepCopy() { - return new dropTagIndex_result(this); + public getTagIndex_result deepCopy() { + return new getTagIndex_result(this); } - public ExecResp getSuccess() { + public GetTagIndexResp getSuccess() { return this.success; } - public dropTagIndex_result setSuccess(ExecResp success) { + public getTagIndex_result setSuccess(GetTagIndexResp success) { this.success = success; return this; } @@ -21353,7 +21891,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetTagIndexResp)__value); } break; @@ -21378,9 +21916,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropTagIndex_result)) + if (!(_that instanceof getTagIndex_result)) return false; - dropTagIndex_result that = (dropTagIndex_result)_that; + getTagIndex_result that = (getTagIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -21393,7 +21931,7 @@ public int hashCode() { } @Override - public int compareTo(dropTagIndex_result other) { + public int compareTo(getTagIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -21428,7 +21966,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetTagIndexResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -21469,7 +22007,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropTagIndex_result"); + StringBuilder sb = new StringBuilder("getTagIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -21496,11 +22034,11 @@ public void validate() throws TException { } - public static class getTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTagIndex_args"); + public static class listTagIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTagIndexes_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetTagIndexReq req; + public ListTagIndexesReq req; public static final int REQ = 1; // isset id assignments @@ -21510,19 +22048,19 @@ public static class getTagIndex_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagIndexReq.class))); + new StructMetaData(TType.STRUCT, ListTagIndexesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTagIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTagIndexes_args.class, metaDataMap); } - public getTagIndex_args() { + public listTagIndexes_args() { } - public getTagIndex_args( - GetTagIndexReq req) { + public listTagIndexes_args( + ListTagIndexesReq req) { this(); this.req = req; } @@ -21530,21 +22068,21 @@ public getTagIndex_args( /** * Performs a deep copy on other. */ - public getTagIndex_args(getTagIndex_args other) { + public listTagIndexes_args(listTagIndexes_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getTagIndex_args deepCopy() { - return new getTagIndex_args(this); + public listTagIndexes_args deepCopy() { + return new listTagIndexes_args(this); } - public GetTagIndexReq getReq() { + public ListTagIndexesReq getReq() { return this.req; } - public getTagIndex_args setReq(GetTagIndexReq req) { + public listTagIndexes_args setReq(ListTagIndexesReq req) { this.req = req; return this; } @@ -21570,7 +22108,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetTagIndexReq)__value); + setReq((ListTagIndexesReq)__value); } break; @@ -21595,9 +22133,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTagIndex_args)) + if (!(_that instanceof listTagIndexes_args)) return false; - getTagIndex_args that = (getTagIndex_args)_that; + listTagIndexes_args that = (listTagIndexes_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -21610,7 +22148,7 @@ public int hashCode() { } @Override - public int compareTo(getTagIndex_args other) { + public int compareTo(listTagIndexes_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -21645,7 +22183,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetTagIndexReq(); + this.req = new ListTagIndexesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -21687,7 +22225,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTagIndex_args"); + StringBuilder sb = new StringBuilder("listTagIndexes_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -21714,11 +22252,11 @@ public void validate() throws TException { } - public static class getTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getTagIndex_result"); + public static class listTagIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTagIndexes_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetTagIndexResp success; + public ListTagIndexesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -21728,19 +22266,19 @@ public static class getTagIndex_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetTagIndexResp.class))); + new StructMetaData(TType.STRUCT, ListTagIndexesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getTagIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTagIndexes_result.class, metaDataMap); } - public getTagIndex_result() { + public listTagIndexes_result() { } - public getTagIndex_result( - GetTagIndexResp success) { + public listTagIndexes_result( + ListTagIndexesResp success) { this(); this.success = success; } @@ -21748,21 +22286,21 @@ public getTagIndex_result( /** * Performs a deep copy on other. */ - public getTagIndex_result(getTagIndex_result other) { + public listTagIndexes_result(listTagIndexes_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getTagIndex_result deepCopy() { - return new getTagIndex_result(this); + public listTagIndexes_result deepCopy() { + return new listTagIndexes_result(this); } - public GetTagIndexResp getSuccess() { + public ListTagIndexesResp getSuccess() { return this.success; } - public getTagIndex_result setSuccess(GetTagIndexResp success) { + public listTagIndexes_result setSuccess(ListTagIndexesResp success) { this.success = success; return this; } @@ -21788,7 +22326,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetTagIndexResp)__value); + setSuccess((ListTagIndexesResp)__value); } break; @@ -21813,9 +22351,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getTagIndex_result)) + if (!(_that instanceof listTagIndexes_result)) return false; - getTagIndex_result that = (getTagIndex_result)_that; + listTagIndexes_result that = (listTagIndexes_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -21828,7 +22366,7 @@ public int hashCode() { } @Override - public int compareTo(getTagIndex_result other) { + public int compareTo(listTagIndexes_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -21863,7 +22401,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetTagIndexResp(); + this.success = new ListTagIndexesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -21904,7 +22442,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getTagIndex_result"); + StringBuilder sb = new StringBuilder("listTagIndexes_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -21931,11 +22469,11 @@ public void validate() throws TException { } - public static class listTagIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTagIndexes_args"); + public static class rebuildTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("rebuildTagIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListTagIndexesReq req; + public RebuildIndexReq req; public static final int REQ = 1; // isset id assignments @@ -21945,19 +22483,19 @@ public static class listTagIndexes_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagIndexesReq.class))); + new StructMetaData(TType.STRUCT, RebuildIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTagIndexes_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(rebuildTagIndex_args.class, metaDataMap); } - public listTagIndexes_args() { + public rebuildTagIndex_args() { } - public listTagIndexes_args( - ListTagIndexesReq req) { + public rebuildTagIndex_args( + RebuildIndexReq req) { this(); this.req = req; } @@ -21965,21 +22503,21 @@ public listTagIndexes_args( /** * Performs a deep copy on other. */ - public listTagIndexes_args(listTagIndexes_args other) { + public rebuildTagIndex_args(rebuildTagIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listTagIndexes_args deepCopy() { - return new listTagIndexes_args(this); + public rebuildTagIndex_args deepCopy() { + return new rebuildTagIndex_args(this); } - public ListTagIndexesReq getReq() { + public RebuildIndexReq getReq() { return this.req; } - public listTagIndexes_args setReq(ListTagIndexesReq req) { + public rebuildTagIndex_args setReq(RebuildIndexReq req) { this.req = req; return this; } @@ -22005,7 +22543,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListTagIndexesReq)__value); + setReq((RebuildIndexReq)__value); } break; @@ -22030,9 +22568,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTagIndexes_args)) + if (!(_that instanceof rebuildTagIndex_args)) return false; - listTagIndexes_args that = (listTagIndexes_args)_that; + rebuildTagIndex_args that = (rebuildTagIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -22045,7 +22583,7 @@ public int hashCode() { } @Override - public int compareTo(listTagIndexes_args other) { + public int compareTo(rebuildTagIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -22080,7 +22618,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListTagIndexesReq(); + this.req = new RebuildIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -22122,7 +22660,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTagIndexes_args"); + StringBuilder sb = new StringBuilder("rebuildTagIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -22149,11 +22687,11 @@ public void validate() throws TException { } - public static class listTagIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTagIndexes_result"); + public static class rebuildTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("rebuildTagIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListTagIndexesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -22163,19 +22701,19 @@ public static class listTagIndexes_result implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListTagIndexesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTagIndexes_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(rebuildTagIndex_result.class, metaDataMap); } - public listTagIndexes_result() { + public rebuildTagIndex_result() { } - public listTagIndexes_result( - ListTagIndexesResp success) { + public rebuildTagIndex_result( + ExecResp success) { this(); this.success = success; } @@ -22183,21 +22721,21 @@ public listTagIndexes_result( /** * Performs a deep copy on other. */ - public listTagIndexes_result(listTagIndexes_result other) { + public rebuildTagIndex_result(rebuildTagIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listTagIndexes_result deepCopy() { - return new listTagIndexes_result(this); + public rebuildTagIndex_result deepCopy() { + return new rebuildTagIndex_result(this); } - public ListTagIndexesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listTagIndexes_result setSuccess(ListTagIndexesResp success) { + public rebuildTagIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -22223,7 +22761,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListTagIndexesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -22248,9 +22786,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTagIndexes_result)) + if (!(_that instanceof rebuildTagIndex_result)) return false; - listTagIndexes_result that = (listTagIndexes_result)_that; + rebuildTagIndex_result that = (rebuildTagIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -22263,7 +22801,7 @@ public int hashCode() { } @Override - public int compareTo(listTagIndexes_result other) { + public int compareTo(rebuildTagIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -22298,7 +22836,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListTagIndexesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -22339,7 +22877,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTagIndexes_result"); + StringBuilder sb = new StringBuilder("rebuildTagIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -22366,11 +22904,11 @@ public void validate() throws TException { } - public static class rebuildTagIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("rebuildTagIndex_args"); + public static class listTagIndexStatus_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTagIndexStatus_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RebuildIndexReq req; + public ListIndexStatusReq req; public static final int REQ = 1; // isset id assignments @@ -22380,19 +22918,19 @@ public static class rebuildTagIndex_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RebuildIndexReq.class))); + new StructMetaData(TType.STRUCT, ListIndexStatusReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(rebuildTagIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTagIndexStatus_args.class, metaDataMap); } - public rebuildTagIndex_args() { + public listTagIndexStatus_args() { } - public rebuildTagIndex_args( - RebuildIndexReq req) { + public listTagIndexStatus_args( + ListIndexStatusReq req) { this(); this.req = req; } @@ -22400,21 +22938,21 @@ public rebuildTagIndex_args( /** * Performs a deep copy on other. */ - public rebuildTagIndex_args(rebuildTagIndex_args other) { + public listTagIndexStatus_args(listTagIndexStatus_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public rebuildTagIndex_args deepCopy() { - return new rebuildTagIndex_args(this); + public listTagIndexStatus_args deepCopy() { + return new listTagIndexStatus_args(this); } - public RebuildIndexReq getReq() { + public ListIndexStatusReq getReq() { return this.req; } - public rebuildTagIndex_args setReq(RebuildIndexReq req) { + public listTagIndexStatus_args setReq(ListIndexStatusReq req) { this.req = req; return this; } @@ -22440,7 +22978,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RebuildIndexReq)__value); + setReq((ListIndexStatusReq)__value); } break; @@ -22465,9 +23003,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof rebuildTagIndex_args)) + if (!(_that instanceof listTagIndexStatus_args)) return false; - rebuildTagIndex_args that = (rebuildTagIndex_args)_that; + listTagIndexStatus_args that = (listTagIndexStatus_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -22480,7 +23018,7 @@ public int hashCode() { } @Override - public int compareTo(rebuildTagIndex_args other) { + public int compareTo(listTagIndexStatus_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -22515,7 +23053,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RebuildIndexReq(); + this.req = new ListIndexStatusReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -22557,7 +23095,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("rebuildTagIndex_args"); + StringBuilder sb = new StringBuilder("listTagIndexStatus_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -22584,11 +23122,11 @@ public void validate() throws TException { } - public static class rebuildTagIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("rebuildTagIndex_result"); + public static class listTagIndexStatus_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listTagIndexStatus_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListIndexStatusResp success; public static final int SUCCESS = 0; // isset id assignments @@ -22598,19 +23136,19 @@ public static class rebuildTagIndex_result implements TBase, java.io.Serializabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListIndexStatusResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(rebuildTagIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listTagIndexStatus_result.class, metaDataMap); } - public rebuildTagIndex_result() { + public listTagIndexStatus_result() { } - public rebuildTagIndex_result( - ExecResp success) { + public listTagIndexStatus_result( + ListIndexStatusResp success) { this(); this.success = success; } @@ -22618,21 +23156,21 @@ public rebuildTagIndex_result( /** * Performs a deep copy on other. */ - public rebuildTagIndex_result(rebuildTagIndex_result other) { + public listTagIndexStatus_result(listTagIndexStatus_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public rebuildTagIndex_result deepCopy() { - return new rebuildTagIndex_result(this); + public listTagIndexStatus_result deepCopy() { + return new listTagIndexStatus_result(this); } - public ExecResp getSuccess() { + public ListIndexStatusResp getSuccess() { return this.success; } - public rebuildTagIndex_result setSuccess(ExecResp success) { + public listTagIndexStatus_result setSuccess(ListIndexStatusResp success) { this.success = success; return this; } @@ -22658,7 +23196,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListIndexStatusResp)__value); } break; @@ -22683,9 +23221,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof rebuildTagIndex_result)) + if (!(_that instanceof listTagIndexStatus_result)) return false; - rebuildTagIndex_result that = (rebuildTagIndex_result)_that; + listTagIndexStatus_result that = (listTagIndexStatus_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -22698,7 +23236,7 @@ public int hashCode() { } @Override - public int compareTo(rebuildTagIndex_result other) { + public int compareTo(listTagIndexStatus_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -22733,7 +23271,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListIndexStatusResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -22774,7 +23312,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("rebuildTagIndex_result"); + StringBuilder sb = new StringBuilder("listTagIndexStatus_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -22801,11 +23339,11 @@ public void validate() throws TException { } - public static class listTagIndexStatus_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTagIndexStatus_args"); + public static class createEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdgeIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListIndexStatusReq req; + public CreateEdgeIndexReq req; public static final int REQ = 1; // isset id assignments @@ -22815,19 +23353,19 @@ public static class listTagIndexStatus_args implements TBase, java.io.Serializab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListIndexStatusReq.class))); + new StructMetaData(TType.STRUCT, CreateEdgeIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTagIndexStatus_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdgeIndex_args.class, metaDataMap); } - public listTagIndexStatus_args() { + public createEdgeIndex_args() { } - public listTagIndexStatus_args( - ListIndexStatusReq req) { + public createEdgeIndex_args( + CreateEdgeIndexReq req) { this(); this.req = req; } @@ -22835,21 +23373,21 @@ public listTagIndexStatus_args( /** * Performs a deep copy on other. */ - public listTagIndexStatus_args(listTagIndexStatus_args other) { + public createEdgeIndex_args(createEdgeIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listTagIndexStatus_args deepCopy() { - return new listTagIndexStatus_args(this); + public createEdgeIndex_args deepCopy() { + return new createEdgeIndex_args(this); } - public ListIndexStatusReq getReq() { + public CreateEdgeIndexReq getReq() { return this.req; } - public listTagIndexStatus_args setReq(ListIndexStatusReq req) { + public createEdgeIndex_args setReq(CreateEdgeIndexReq req) { this.req = req; return this; } @@ -22875,7 +23413,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListIndexStatusReq)__value); + setReq((CreateEdgeIndexReq)__value); } break; @@ -22900,9 +23438,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTagIndexStatus_args)) + if (!(_that instanceof createEdgeIndex_args)) return false; - listTagIndexStatus_args that = (listTagIndexStatus_args)_that; + createEdgeIndex_args that = (createEdgeIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -22915,7 +23453,7 @@ public int hashCode() { } @Override - public int compareTo(listTagIndexStatus_args other) { + public int compareTo(createEdgeIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -22950,7 +23488,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListIndexStatusReq(); + this.req = new CreateEdgeIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -22992,7 +23530,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTagIndexStatus_args"); + StringBuilder sb = new StringBuilder("createEdgeIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -23019,11 +23557,11 @@ public void validate() throws TException { } - public static class listTagIndexStatus_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listTagIndexStatus_result"); + public static class createEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createEdgeIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListIndexStatusResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -23033,19 +23571,19 @@ public static class listTagIndexStatus_result implements TBase, java.io.Serializ static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListIndexStatusResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listTagIndexStatus_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createEdgeIndex_result.class, metaDataMap); } - public listTagIndexStatus_result() { + public createEdgeIndex_result() { } - public listTagIndexStatus_result( - ListIndexStatusResp success) { + public createEdgeIndex_result( + ExecResp success) { this(); this.success = success; } @@ -23053,21 +23591,21 @@ public listTagIndexStatus_result( /** * Performs a deep copy on other. */ - public listTagIndexStatus_result(listTagIndexStatus_result other) { + public createEdgeIndex_result(createEdgeIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listTagIndexStatus_result deepCopy() { - return new listTagIndexStatus_result(this); + public createEdgeIndex_result deepCopy() { + return new createEdgeIndex_result(this); } - public ListIndexStatusResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listTagIndexStatus_result setSuccess(ListIndexStatusResp success) { + public createEdgeIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -23093,7 +23631,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListIndexStatusResp)__value); + setSuccess((ExecResp)__value); } break; @@ -23118,9 +23656,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listTagIndexStatus_result)) + if (!(_that instanceof createEdgeIndex_result)) return false; - listTagIndexStatus_result that = (listTagIndexStatus_result)_that; + createEdgeIndex_result that = (createEdgeIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -23133,7 +23671,7 @@ public int hashCode() { } @Override - public int compareTo(listTagIndexStatus_result other) { + public int compareTo(createEdgeIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -23168,7 +23706,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListIndexStatusResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -23209,7 +23747,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listTagIndexStatus_result"); + StringBuilder sb = new StringBuilder("createEdgeIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -23236,11 +23774,11 @@ public void validate() throws TException { } - public static class createEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdgeIndex_args"); + public static class dropEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdgeIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateEdgeIndexReq req; + public DropEdgeIndexReq req; public static final int REQ = 1; // isset id assignments @@ -23250,19 +23788,19 @@ public static class createEdgeIndex_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateEdgeIndexReq.class))); + new StructMetaData(TType.STRUCT, DropEdgeIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createEdgeIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdgeIndex_args.class, metaDataMap); } - public createEdgeIndex_args() { + public dropEdgeIndex_args() { } - public createEdgeIndex_args( - CreateEdgeIndexReq req) { + public dropEdgeIndex_args( + DropEdgeIndexReq req) { this(); this.req = req; } @@ -23270,21 +23808,21 @@ public createEdgeIndex_args( /** * Performs a deep copy on other. */ - public createEdgeIndex_args(createEdgeIndex_args other) { + public dropEdgeIndex_args(dropEdgeIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createEdgeIndex_args deepCopy() { - return new createEdgeIndex_args(this); + public dropEdgeIndex_args deepCopy() { + return new dropEdgeIndex_args(this); } - public CreateEdgeIndexReq getReq() { + public DropEdgeIndexReq getReq() { return this.req; } - public createEdgeIndex_args setReq(CreateEdgeIndexReq req) { + public dropEdgeIndex_args setReq(DropEdgeIndexReq req) { this.req = req; return this; } @@ -23310,7 +23848,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateEdgeIndexReq)__value); + setReq((DropEdgeIndexReq)__value); } break; @@ -23335,9 +23873,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdgeIndex_args)) + if (!(_that instanceof dropEdgeIndex_args)) return false; - createEdgeIndex_args that = (createEdgeIndex_args)_that; + dropEdgeIndex_args that = (dropEdgeIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -23350,7 +23888,7 @@ public int hashCode() { } @Override - public int compareTo(createEdgeIndex_args other) { + public int compareTo(dropEdgeIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -23385,7 +23923,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateEdgeIndexReq(); + this.req = new DropEdgeIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -23427,7 +23965,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdgeIndex_args"); + StringBuilder sb = new StringBuilder("dropEdgeIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -23454,8 +23992,8 @@ public void validate() throws TException { } - public static class createEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createEdgeIndex_result"); + public static class dropEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropEdgeIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -23473,13 +24011,13 @@ public static class createEdgeIndex_result implements TBase, java.io.Serializabl } static { - FieldMetaData.addStructMetaDataMap(createEdgeIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropEdgeIndex_result.class, metaDataMap); } - public createEdgeIndex_result() { + public dropEdgeIndex_result() { } - public createEdgeIndex_result( + public dropEdgeIndex_result( ExecResp success) { this(); this.success = success; @@ -23488,21 +24026,21 @@ public createEdgeIndex_result( /** * Performs a deep copy on other. */ - public createEdgeIndex_result(createEdgeIndex_result other) { + public dropEdgeIndex_result(dropEdgeIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createEdgeIndex_result deepCopy() { - return new createEdgeIndex_result(this); + public dropEdgeIndex_result deepCopy() { + return new dropEdgeIndex_result(this); } public ExecResp getSuccess() { return this.success; } - public createEdgeIndex_result setSuccess(ExecResp success) { + public dropEdgeIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -23553,9 +24091,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createEdgeIndex_result)) + if (!(_that instanceof dropEdgeIndex_result)) return false; - createEdgeIndex_result that = (createEdgeIndex_result)_that; + dropEdgeIndex_result that = (dropEdgeIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -23568,7 +24106,7 @@ public int hashCode() { } @Override - public int compareTo(createEdgeIndex_result other) { + public int compareTo(dropEdgeIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -23644,7 +24182,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createEdgeIndex_result"); + StringBuilder sb = new StringBuilder("dropEdgeIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -23671,11 +24209,11 @@ public void validate() throws TException { } - public static class dropEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdgeIndex_args"); + public static class getEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdgeIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropEdgeIndexReq req; + public GetEdgeIndexReq req; public static final int REQ = 1; // isset id assignments @@ -23685,19 +24223,19 @@ public static class dropEdgeIndex_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropEdgeIndexReq.class))); + new StructMetaData(TType.STRUCT, GetEdgeIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropEdgeIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdgeIndex_args.class, metaDataMap); } - public dropEdgeIndex_args() { + public getEdgeIndex_args() { } - public dropEdgeIndex_args( - DropEdgeIndexReq req) { + public getEdgeIndex_args( + GetEdgeIndexReq req) { this(); this.req = req; } @@ -23705,21 +24243,21 @@ public dropEdgeIndex_args( /** * Performs a deep copy on other. */ - public dropEdgeIndex_args(dropEdgeIndex_args other) { + public getEdgeIndex_args(getEdgeIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropEdgeIndex_args deepCopy() { - return new dropEdgeIndex_args(this); + public getEdgeIndex_args deepCopy() { + return new getEdgeIndex_args(this); } - public DropEdgeIndexReq getReq() { + public GetEdgeIndexReq getReq() { return this.req; } - public dropEdgeIndex_args setReq(DropEdgeIndexReq req) { + public getEdgeIndex_args setReq(GetEdgeIndexReq req) { this.req = req; return this; } @@ -23745,7 +24283,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropEdgeIndexReq)__value); + setReq((GetEdgeIndexReq)__value); } break; @@ -23770,9 +24308,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdgeIndex_args)) + if (!(_that instanceof getEdgeIndex_args)) return false; - dropEdgeIndex_args that = (dropEdgeIndex_args)_that; + getEdgeIndex_args that = (getEdgeIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -23785,7 +24323,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdgeIndex_args other) { + public int compareTo(getEdgeIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -23820,7 +24358,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropEdgeIndexReq(); + this.req = new GetEdgeIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -23862,7 +24400,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdgeIndex_args"); + StringBuilder sb = new StringBuilder("getEdgeIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -23889,11 +24427,11 @@ public void validate() throws TException { } - public static class dropEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropEdgeIndex_result"); + public static class getEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getEdgeIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetEdgeIndexResp success; public static final int SUCCESS = 0; // isset id assignments @@ -23903,19 +24441,19 @@ public static class dropEdgeIndex_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetEdgeIndexResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropEdgeIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getEdgeIndex_result.class, metaDataMap); } - public dropEdgeIndex_result() { + public getEdgeIndex_result() { } - public dropEdgeIndex_result( - ExecResp success) { + public getEdgeIndex_result( + GetEdgeIndexResp success) { this(); this.success = success; } @@ -23923,21 +24461,21 @@ public dropEdgeIndex_result( /** * Performs a deep copy on other. */ - public dropEdgeIndex_result(dropEdgeIndex_result other) { + public getEdgeIndex_result(getEdgeIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropEdgeIndex_result deepCopy() { - return new dropEdgeIndex_result(this); + public getEdgeIndex_result deepCopy() { + return new getEdgeIndex_result(this); } - public ExecResp getSuccess() { + public GetEdgeIndexResp getSuccess() { return this.success; } - public dropEdgeIndex_result setSuccess(ExecResp success) { + public getEdgeIndex_result setSuccess(GetEdgeIndexResp success) { this.success = success; return this; } @@ -23963,7 +24501,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetEdgeIndexResp)__value); } break; @@ -23988,9 +24526,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropEdgeIndex_result)) + if (!(_that instanceof getEdgeIndex_result)) return false; - dropEdgeIndex_result that = (dropEdgeIndex_result)_that; + getEdgeIndex_result that = (getEdgeIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -24003,7 +24541,7 @@ public int hashCode() { } @Override - public int compareTo(dropEdgeIndex_result other) { + public int compareTo(getEdgeIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -24038,7 +24576,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetEdgeIndexResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -24079,7 +24617,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropEdgeIndex_result"); + StringBuilder sb = new StringBuilder("getEdgeIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -24106,11 +24644,11 @@ public void validate() throws TException { } - public static class getEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdgeIndex_args"); + public static class listEdgeIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexes_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetEdgeIndexReq req; + public ListEdgeIndexesReq req; public static final int REQ = 1; // isset id assignments @@ -24120,19 +24658,19 @@ public static class getEdgeIndex_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeIndexReq.class))); + new StructMetaData(TType.STRUCT, ListEdgeIndexesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdgeIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdgeIndexes_args.class, metaDataMap); } - public getEdgeIndex_args() { + public listEdgeIndexes_args() { } - public getEdgeIndex_args( - GetEdgeIndexReq req) { + public listEdgeIndexes_args( + ListEdgeIndexesReq req) { this(); this.req = req; } @@ -24140,21 +24678,21 @@ public getEdgeIndex_args( /** * Performs a deep copy on other. */ - public getEdgeIndex_args(getEdgeIndex_args other) { + public listEdgeIndexes_args(listEdgeIndexes_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getEdgeIndex_args deepCopy() { - return new getEdgeIndex_args(this); + public listEdgeIndexes_args deepCopy() { + return new listEdgeIndexes_args(this); } - public GetEdgeIndexReq getReq() { + public ListEdgeIndexesReq getReq() { return this.req; } - public getEdgeIndex_args setReq(GetEdgeIndexReq req) { + public listEdgeIndexes_args setReq(ListEdgeIndexesReq req) { this.req = req; return this; } @@ -24180,7 +24718,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetEdgeIndexReq)__value); + setReq((ListEdgeIndexesReq)__value); } break; @@ -24205,9 +24743,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdgeIndex_args)) + if (!(_that instanceof listEdgeIndexes_args)) return false; - getEdgeIndex_args that = (getEdgeIndex_args)_that; + listEdgeIndexes_args that = (listEdgeIndexes_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -24220,7 +24758,7 @@ public int hashCode() { } @Override - public int compareTo(getEdgeIndex_args other) { + public int compareTo(listEdgeIndexes_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -24255,7 +24793,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetEdgeIndexReq(); + this.req = new ListEdgeIndexesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -24297,7 +24835,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdgeIndex_args"); + StringBuilder sb = new StringBuilder("listEdgeIndexes_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -24324,11 +24862,11 @@ public void validate() throws TException { } - public static class getEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getEdgeIndex_result"); + public static class listEdgeIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexes_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetEdgeIndexResp success; + public ListEdgeIndexesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -24338,19 +24876,19 @@ public static class getEdgeIndex_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetEdgeIndexResp.class))); + new StructMetaData(TType.STRUCT, ListEdgeIndexesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getEdgeIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdgeIndexes_result.class, metaDataMap); } - public getEdgeIndex_result() { + public listEdgeIndexes_result() { } - public getEdgeIndex_result( - GetEdgeIndexResp success) { + public listEdgeIndexes_result( + ListEdgeIndexesResp success) { this(); this.success = success; } @@ -24358,21 +24896,21 @@ public getEdgeIndex_result( /** * Performs a deep copy on other. */ - public getEdgeIndex_result(getEdgeIndex_result other) { + public listEdgeIndexes_result(listEdgeIndexes_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getEdgeIndex_result deepCopy() { - return new getEdgeIndex_result(this); + public listEdgeIndexes_result deepCopy() { + return new listEdgeIndexes_result(this); } - public GetEdgeIndexResp getSuccess() { + public ListEdgeIndexesResp getSuccess() { return this.success; } - public getEdgeIndex_result setSuccess(GetEdgeIndexResp success) { + public listEdgeIndexes_result setSuccess(ListEdgeIndexesResp success) { this.success = success; return this; } @@ -24398,7 +24936,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetEdgeIndexResp)__value); + setSuccess((ListEdgeIndexesResp)__value); } break; @@ -24423,9 +24961,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getEdgeIndex_result)) + if (!(_that instanceof listEdgeIndexes_result)) return false; - getEdgeIndex_result that = (getEdgeIndex_result)_that; + listEdgeIndexes_result that = (listEdgeIndexes_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -24438,7 +24976,7 @@ public int hashCode() { } @Override - public int compareTo(getEdgeIndex_result other) { + public int compareTo(listEdgeIndexes_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -24473,7 +25011,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetEdgeIndexResp(); + this.success = new ListEdgeIndexesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -24514,7 +25052,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getEdgeIndex_result"); + StringBuilder sb = new StringBuilder("listEdgeIndexes_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -24541,11 +25079,11 @@ public void validate() throws TException { } - public static class listEdgeIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexes_args"); + public static class rebuildEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("rebuildEdgeIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListEdgeIndexesReq req; + public RebuildIndexReq req; public static final int REQ = 1; // isset id assignments @@ -24555,19 +25093,19 @@ public static class listEdgeIndexes_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgeIndexesReq.class))); + new StructMetaData(TType.STRUCT, RebuildIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdgeIndexes_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(rebuildEdgeIndex_args.class, metaDataMap); } - public listEdgeIndexes_args() { + public rebuildEdgeIndex_args() { } - public listEdgeIndexes_args( - ListEdgeIndexesReq req) { + public rebuildEdgeIndex_args( + RebuildIndexReq req) { this(); this.req = req; } @@ -24575,21 +25113,21 @@ public listEdgeIndexes_args( /** * Performs a deep copy on other. */ - public listEdgeIndexes_args(listEdgeIndexes_args other) { + public rebuildEdgeIndex_args(rebuildEdgeIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listEdgeIndexes_args deepCopy() { - return new listEdgeIndexes_args(this); + public rebuildEdgeIndex_args deepCopy() { + return new rebuildEdgeIndex_args(this); } - public ListEdgeIndexesReq getReq() { + public RebuildIndexReq getReq() { return this.req; } - public listEdgeIndexes_args setReq(ListEdgeIndexesReq req) { + public rebuildEdgeIndex_args setReq(RebuildIndexReq req) { this.req = req; return this; } @@ -24615,7 +25153,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListEdgeIndexesReq)__value); + setReq((RebuildIndexReq)__value); } break; @@ -24640,9 +25178,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdgeIndexes_args)) + if (!(_that instanceof rebuildEdgeIndex_args)) return false; - listEdgeIndexes_args that = (listEdgeIndexes_args)_that; + rebuildEdgeIndex_args that = (rebuildEdgeIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -24655,7 +25193,7 @@ public int hashCode() { } @Override - public int compareTo(listEdgeIndexes_args other) { + public int compareTo(rebuildEdgeIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -24690,7 +25228,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListEdgeIndexesReq(); + this.req = new RebuildIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -24732,7 +25270,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdgeIndexes_args"); + StringBuilder sb = new StringBuilder("rebuildEdgeIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -24759,11 +25297,11 @@ public void validate() throws TException { } - public static class listEdgeIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexes_result"); + public static class rebuildEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("rebuildEdgeIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListEdgeIndexesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -24773,19 +25311,19 @@ public static class listEdgeIndexes_result implements TBase, java.io.Serializabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListEdgeIndexesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdgeIndexes_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(rebuildEdgeIndex_result.class, metaDataMap); } - public listEdgeIndexes_result() { + public rebuildEdgeIndex_result() { } - public listEdgeIndexes_result( - ListEdgeIndexesResp success) { + public rebuildEdgeIndex_result( + ExecResp success) { this(); this.success = success; } @@ -24793,21 +25331,21 @@ public listEdgeIndexes_result( /** * Performs a deep copy on other. */ - public listEdgeIndexes_result(listEdgeIndexes_result other) { + public rebuildEdgeIndex_result(rebuildEdgeIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listEdgeIndexes_result deepCopy() { - return new listEdgeIndexes_result(this); + public rebuildEdgeIndex_result deepCopy() { + return new rebuildEdgeIndex_result(this); } - public ListEdgeIndexesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listEdgeIndexes_result setSuccess(ListEdgeIndexesResp success) { + public rebuildEdgeIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -24833,7 +25371,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListEdgeIndexesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -24858,9 +25396,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdgeIndexes_result)) + if (!(_that instanceof rebuildEdgeIndex_result)) return false; - listEdgeIndexes_result that = (listEdgeIndexes_result)_that; + rebuildEdgeIndex_result that = (rebuildEdgeIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -24873,7 +25411,7 @@ public int hashCode() { } @Override - public int compareTo(listEdgeIndexes_result other) { + public int compareTo(rebuildEdgeIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -24908,7 +25446,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListEdgeIndexesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -24949,7 +25487,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdgeIndexes_result"); + StringBuilder sb = new StringBuilder("rebuildEdgeIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -24976,11 +25514,11 @@ public void validate() throws TException { } - public static class rebuildEdgeIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("rebuildEdgeIndex_args"); + public static class listEdgeIndexStatus_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexStatus_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RebuildIndexReq req; + public ListIndexStatusReq req; public static final int REQ = 1; // isset id assignments @@ -24990,19 +25528,19 @@ public static class rebuildEdgeIndex_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RebuildIndexReq.class))); + new StructMetaData(TType.STRUCT, ListIndexStatusReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(rebuildEdgeIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdgeIndexStatus_args.class, metaDataMap); } - public rebuildEdgeIndex_args() { + public listEdgeIndexStatus_args() { } - public rebuildEdgeIndex_args( - RebuildIndexReq req) { + public listEdgeIndexStatus_args( + ListIndexStatusReq req) { this(); this.req = req; } @@ -25010,21 +25548,21 @@ public rebuildEdgeIndex_args( /** * Performs a deep copy on other. */ - public rebuildEdgeIndex_args(rebuildEdgeIndex_args other) { + public listEdgeIndexStatus_args(listEdgeIndexStatus_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public rebuildEdgeIndex_args deepCopy() { - return new rebuildEdgeIndex_args(this); + public listEdgeIndexStatus_args deepCopy() { + return new listEdgeIndexStatus_args(this); } - public RebuildIndexReq getReq() { + public ListIndexStatusReq getReq() { return this.req; } - public rebuildEdgeIndex_args setReq(RebuildIndexReq req) { + public listEdgeIndexStatus_args setReq(ListIndexStatusReq req) { this.req = req; return this; } @@ -25050,7 +25588,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RebuildIndexReq)__value); + setReq((ListIndexStatusReq)__value); } break; @@ -25075,9 +25613,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof rebuildEdgeIndex_args)) + if (!(_that instanceof listEdgeIndexStatus_args)) return false; - rebuildEdgeIndex_args that = (rebuildEdgeIndex_args)_that; + listEdgeIndexStatus_args that = (listEdgeIndexStatus_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -25090,7 +25628,7 @@ public int hashCode() { } @Override - public int compareTo(rebuildEdgeIndex_args other) { + public int compareTo(listEdgeIndexStatus_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -25125,7 +25663,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RebuildIndexReq(); + this.req = new ListIndexStatusReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -25167,7 +25705,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("rebuildEdgeIndex_args"); + StringBuilder sb = new StringBuilder("listEdgeIndexStatus_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -25194,11 +25732,11 @@ public void validate() throws TException { } - public static class rebuildEdgeIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("rebuildEdgeIndex_result"); + public static class listEdgeIndexStatus_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexStatus_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListIndexStatusResp success; public static final int SUCCESS = 0; // isset id assignments @@ -25208,19 +25746,19 @@ public static class rebuildEdgeIndex_result implements TBase, java.io.Serializab static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListIndexStatusResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(rebuildEdgeIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listEdgeIndexStatus_result.class, metaDataMap); } - public rebuildEdgeIndex_result() { + public listEdgeIndexStatus_result() { } - public rebuildEdgeIndex_result( - ExecResp success) { + public listEdgeIndexStatus_result( + ListIndexStatusResp success) { this(); this.success = success; } @@ -25228,21 +25766,21 @@ public rebuildEdgeIndex_result( /** * Performs a deep copy on other. */ - public rebuildEdgeIndex_result(rebuildEdgeIndex_result other) { + public listEdgeIndexStatus_result(listEdgeIndexStatus_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public rebuildEdgeIndex_result deepCopy() { - return new rebuildEdgeIndex_result(this); + public listEdgeIndexStatus_result deepCopy() { + return new listEdgeIndexStatus_result(this); } - public ExecResp getSuccess() { + public ListIndexStatusResp getSuccess() { return this.success; } - public rebuildEdgeIndex_result setSuccess(ExecResp success) { + public listEdgeIndexStatus_result setSuccess(ListIndexStatusResp success) { this.success = success; return this; } @@ -25268,7 +25806,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListIndexStatusResp)__value); } break; @@ -25293,9 +25831,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof rebuildEdgeIndex_result)) + if (!(_that instanceof listEdgeIndexStatus_result)) return false; - rebuildEdgeIndex_result that = (rebuildEdgeIndex_result)_that; + listEdgeIndexStatus_result that = (listEdgeIndexStatus_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -25308,7 +25846,7 @@ public int hashCode() { } @Override - public int compareTo(rebuildEdgeIndex_result other) { + public int compareTo(listEdgeIndexStatus_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -25343,7 +25881,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListIndexStatusResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -25384,7 +25922,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("rebuildEdgeIndex_result"); + StringBuilder sb = new StringBuilder("listEdgeIndexStatus_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -25411,11 +25949,11 @@ public void validate() throws TException { } - public static class listEdgeIndexStatus_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexStatus_args"); + public static class createUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createUser_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListIndexStatusReq req; + public CreateUserReq req; public static final int REQ = 1; // isset id assignments @@ -25425,19 +25963,19 @@ public static class listEdgeIndexStatus_args implements TBase, java.io.Serializa static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListIndexStatusReq.class))); + new StructMetaData(TType.STRUCT, CreateUserReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdgeIndexStatus_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createUser_args.class, metaDataMap); } - public listEdgeIndexStatus_args() { + public createUser_args() { } - public listEdgeIndexStatus_args( - ListIndexStatusReq req) { + public createUser_args( + CreateUserReq req) { this(); this.req = req; } @@ -25445,21 +25983,21 @@ public listEdgeIndexStatus_args( /** * Performs a deep copy on other. */ - public listEdgeIndexStatus_args(listEdgeIndexStatus_args other) { + public createUser_args(createUser_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listEdgeIndexStatus_args deepCopy() { - return new listEdgeIndexStatus_args(this); + public createUser_args deepCopy() { + return new createUser_args(this); } - public ListIndexStatusReq getReq() { + public CreateUserReq getReq() { return this.req; } - public listEdgeIndexStatus_args setReq(ListIndexStatusReq req) { + public createUser_args setReq(CreateUserReq req) { this.req = req; return this; } @@ -25485,7 +26023,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListIndexStatusReq)__value); + setReq((CreateUserReq)__value); } break; @@ -25510,9 +26048,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdgeIndexStatus_args)) + if (!(_that instanceof createUser_args)) return false; - listEdgeIndexStatus_args that = (listEdgeIndexStatus_args)_that; + createUser_args that = (createUser_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -25525,7 +26063,7 @@ public int hashCode() { } @Override - public int compareTo(listEdgeIndexStatus_args other) { + public int compareTo(createUser_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -25560,7 +26098,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListIndexStatusReq(); + this.req = new CreateUserReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -25602,7 +26140,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdgeIndexStatus_args"); + StringBuilder sb = new StringBuilder("createUser_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -25629,11 +26167,11 @@ public void validate() throws TException { } - public static class listEdgeIndexStatus_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listEdgeIndexStatus_result"); + public static class createUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createUser_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListIndexStatusResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -25643,19 +26181,19 @@ public static class listEdgeIndexStatus_result implements TBase, java.io.Seriali static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListIndexStatusResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listEdgeIndexStatus_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createUser_result.class, metaDataMap); } - public listEdgeIndexStatus_result() { + public createUser_result() { } - public listEdgeIndexStatus_result( - ListIndexStatusResp success) { + public createUser_result( + ExecResp success) { this(); this.success = success; } @@ -25663,21 +26201,21 @@ public listEdgeIndexStatus_result( /** * Performs a deep copy on other. */ - public listEdgeIndexStatus_result(listEdgeIndexStatus_result other) { + public createUser_result(createUser_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listEdgeIndexStatus_result deepCopy() { - return new listEdgeIndexStatus_result(this); + public createUser_result deepCopy() { + return new createUser_result(this); } - public ListIndexStatusResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listEdgeIndexStatus_result setSuccess(ListIndexStatusResp success) { + public createUser_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -25703,7 +26241,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListIndexStatusResp)__value); + setSuccess((ExecResp)__value); } break; @@ -25728,9 +26266,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listEdgeIndexStatus_result)) + if (!(_that instanceof createUser_result)) return false; - listEdgeIndexStatus_result that = (listEdgeIndexStatus_result)_that; + createUser_result that = (createUser_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -25743,7 +26281,7 @@ public int hashCode() { } @Override - public int compareTo(listEdgeIndexStatus_result other) { + public int compareTo(createUser_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -25778,7 +26316,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListIndexStatusResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -25819,7 +26357,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listEdgeIndexStatus_result"); + StringBuilder sb = new StringBuilder("createUser_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -25846,11 +26384,11 @@ public void validate() throws TException { } - public static class createUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createUser_args"); + public static class dropUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropUser_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateUserReq req; + public DropUserReq req; public static final int REQ = 1; // isset id assignments @@ -25860,19 +26398,19 @@ public static class createUser_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateUserReq.class))); + new StructMetaData(TType.STRUCT, DropUserReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createUser_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropUser_args.class, metaDataMap); } - public createUser_args() { + public dropUser_args() { } - public createUser_args( - CreateUserReq req) { + public dropUser_args( + DropUserReq req) { this(); this.req = req; } @@ -25880,21 +26418,21 @@ public createUser_args( /** * Performs a deep copy on other. */ - public createUser_args(createUser_args other) { + public dropUser_args(dropUser_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createUser_args deepCopy() { - return new createUser_args(this); + public dropUser_args deepCopy() { + return new dropUser_args(this); } - public CreateUserReq getReq() { + public DropUserReq getReq() { return this.req; } - public createUser_args setReq(CreateUserReq req) { + public dropUser_args setReq(DropUserReq req) { this.req = req; return this; } @@ -25920,7 +26458,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateUserReq)__value); + setReq((DropUserReq)__value); } break; @@ -25945,9 +26483,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createUser_args)) + if (!(_that instanceof dropUser_args)) return false; - createUser_args that = (createUser_args)_that; + dropUser_args that = (dropUser_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -25960,7 +26498,7 @@ public int hashCode() { } @Override - public int compareTo(createUser_args other) { + public int compareTo(dropUser_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -25995,7 +26533,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateUserReq(); + this.req = new DropUserReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -26037,7 +26575,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createUser_args"); + StringBuilder sb = new StringBuilder("dropUser_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -26064,8 +26602,8 @@ public void validate() throws TException { } - public static class createUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createUser_result"); + public static class dropUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropUser_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -26083,13 +26621,13 @@ public static class createUser_result implements TBase, java.io.Serializable, Cl } static { - FieldMetaData.addStructMetaDataMap(createUser_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropUser_result.class, metaDataMap); } - public createUser_result() { + public dropUser_result() { } - public createUser_result( + public dropUser_result( ExecResp success) { this(); this.success = success; @@ -26098,21 +26636,21 @@ public createUser_result( /** * Performs a deep copy on other. */ - public createUser_result(createUser_result other) { + public dropUser_result(dropUser_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createUser_result deepCopy() { - return new createUser_result(this); + public dropUser_result deepCopy() { + return new dropUser_result(this); } public ExecResp getSuccess() { return this.success; } - public createUser_result setSuccess(ExecResp success) { + public dropUser_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -26163,9 +26701,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createUser_result)) + if (!(_that instanceof dropUser_result)) return false; - createUser_result that = (createUser_result)_that; + dropUser_result that = (dropUser_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -26178,7 +26716,7 @@ public int hashCode() { } @Override - public int compareTo(createUser_result other) { + public int compareTo(dropUser_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -26254,7 +26792,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createUser_result"); + StringBuilder sb = new StringBuilder("dropUser_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -26281,11 +26819,11 @@ public void validate() throws TException { } - public static class dropUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropUser_args"); + public static class alterUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterUser_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropUserReq req; + public AlterUserReq req; public static final int REQ = 1; // isset id assignments @@ -26295,19 +26833,19 @@ public static class dropUser_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropUserReq.class))); + new StructMetaData(TType.STRUCT, AlterUserReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropUser_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterUser_args.class, metaDataMap); } - public dropUser_args() { + public alterUser_args() { } - public dropUser_args( - DropUserReq req) { + public alterUser_args( + AlterUserReq req) { this(); this.req = req; } @@ -26315,21 +26853,21 @@ public dropUser_args( /** * Performs a deep copy on other. */ - public dropUser_args(dropUser_args other) { + public alterUser_args(alterUser_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropUser_args deepCopy() { - return new dropUser_args(this); + public alterUser_args deepCopy() { + return new alterUser_args(this); } - public DropUserReq getReq() { + public AlterUserReq getReq() { return this.req; } - public dropUser_args setReq(DropUserReq req) { + public alterUser_args setReq(AlterUserReq req) { this.req = req; return this; } @@ -26355,7 +26893,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropUserReq)__value); + setReq((AlterUserReq)__value); } break; @@ -26380,9 +26918,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropUser_args)) + if (!(_that instanceof alterUser_args)) return false; - dropUser_args that = (dropUser_args)_that; + alterUser_args that = (alterUser_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -26395,7 +26933,7 @@ public int hashCode() { } @Override - public int compareTo(dropUser_args other) { + public int compareTo(alterUser_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -26430,7 +26968,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropUserReq(); + this.req = new AlterUserReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -26472,7 +27010,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropUser_args"); + StringBuilder sb = new StringBuilder("alterUser_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -26499,8 +27037,8 @@ public void validate() throws TException { } - public static class dropUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropUser_result"); + public static class alterUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("alterUser_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -26518,13 +27056,13 @@ public static class dropUser_result implements TBase, java.io.Serializable, Clon } static { - FieldMetaData.addStructMetaDataMap(dropUser_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(alterUser_result.class, metaDataMap); } - public dropUser_result() { + public alterUser_result() { } - public dropUser_result( + public alterUser_result( ExecResp success) { this(); this.success = success; @@ -26533,21 +27071,21 @@ public dropUser_result( /** * Performs a deep copy on other. */ - public dropUser_result(dropUser_result other) { + public alterUser_result(alterUser_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropUser_result deepCopy() { - return new dropUser_result(this); + public alterUser_result deepCopy() { + return new alterUser_result(this); } public ExecResp getSuccess() { return this.success; } - public dropUser_result setSuccess(ExecResp success) { + public alterUser_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -26598,9 +27136,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropUser_result)) + if (!(_that instanceof alterUser_result)) return false; - dropUser_result that = (dropUser_result)_that; + alterUser_result that = (alterUser_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -26613,7 +27151,7 @@ public int hashCode() { } @Override - public int compareTo(dropUser_result other) { + public int compareTo(alterUser_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -26689,7 +27227,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropUser_result"); + StringBuilder sb = new StringBuilder("alterUser_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -26716,11 +27254,11 @@ public void validate() throws TException { } - public static class alterUser_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterUser_args"); + public static class grantRole_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("grantRole_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AlterUserReq req; + public GrantRoleReq req; public static final int REQ = 1; // isset id assignments @@ -26730,19 +27268,19 @@ public static class alterUser_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AlterUserReq.class))); + new StructMetaData(TType.STRUCT, GrantRoleReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(alterUser_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(grantRole_args.class, metaDataMap); } - public alterUser_args() { + public grantRole_args() { } - public alterUser_args( - AlterUserReq req) { + public grantRole_args( + GrantRoleReq req) { this(); this.req = req; } @@ -26750,21 +27288,21 @@ public alterUser_args( /** * Performs a deep copy on other. */ - public alterUser_args(alterUser_args other) { + public grantRole_args(grantRole_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public alterUser_args deepCopy() { - return new alterUser_args(this); + public grantRole_args deepCopy() { + return new grantRole_args(this); } - public AlterUserReq getReq() { + public GrantRoleReq getReq() { return this.req; } - public alterUser_args setReq(AlterUserReq req) { + public grantRole_args setReq(GrantRoleReq req) { this.req = req; return this; } @@ -26790,7 +27328,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AlterUserReq)__value); + setReq((GrantRoleReq)__value); } break; @@ -26815,9 +27353,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterUser_args)) + if (!(_that instanceof grantRole_args)) return false; - alterUser_args that = (alterUser_args)_that; + grantRole_args that = (grantRole_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -26830,7 +27368,7 @@ public int hashCode() { } @Override - public int compareTo(alterUser_args other) { + public int compareTo(grantRole_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -26865,7 +27403,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AlterUserReq(); + this.req = new GrantRoleReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -26907,7 +27445,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterUser_args"); + StringBuilder sb = new StringBuilder("grantRole_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -26934,8 +27472,8 @@ public void validate() throws TException { } - public static class alterUser_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("alterUser_result"); + public static class grantRole_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("grantRole_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -26953,13 +27491,13 @@ public static class alterUser_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(alterUser_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(grantRole_result.class, metaDataMap); } - public alterUser_result() { + public grantRole_result() { } - public alterUser_result( + public grantRole_result( ExecResp success) { this(); this.success = success; @@ -26968,21 +27506,21 @@ public alterUser_result( /** * Performs a deep copy on other. */ - public alterUser_result(alterUser_result other) { + public grantRole_result(grantRole_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public alterUser_result deepCopy() { - return new alterUser_result(this); + public grantRole_result deepCopy() { + return new grantRole_result(this); } public ExecResp getSuccess() { return this.success; } - public alterUser_result setSuccess(ExecResp success) { + public grantRole_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -27033,9 +27571,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof alterUser_result)) + if (!(_that instanceof grantRole_result)) return false; - alterUser_result that = (alterUser_result)_that; + grantRole_result that = (grantRole_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -27048,7 +27586,7 @@ public int hashCode() { } @Override - public int compareTo(alterUser_result other) { + public int compareTo(grantRole_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -27124,7 +27662,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("alterUser_result"); + StringBuilder sb = new StringBuilder("grantRole_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -27151,11 +27689,11 @@ public void validate() throws TException { } - public static class grantRole_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("grantRole_args"); + public static class revokeRole_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("revokeRole_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GrantRoleReq req; + public RevokeRoleReq req; public static final int REQ = 1; // isset id assignments @@ -27165,19 +27703,19 @@ public static class grantRole_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GrantRoleReq.class))); + new StructMetaData(TType.STRUCT, RevokeRoleReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(grantRole_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(revokeRole_args.class, metaDataMap); } - public grantRole_args() { + public revokeRole_args() { } - public grantRole_args( - GrantRoleReq req) { + public revokeRole_args( + RevokeRoleReq req) { this(); this.req = req; } @@ -27185,21 +27723,21 @@ public grantRole_args( /** * Performs a deep copy on other. */ - public grantRole_args(grantRole_args other) { + public revokeRole_args(revokeRole_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public grantRole_args deepCopy() { - return new grantRole_args(this); + public revokeRole_args deepCopy() { + return new revokeRole_args(this); } - public GrantRoleReq getReq() { + public RevokeRoleReq getReq() { return this.req; } - public grantRole_args setReq(GrantRoleReq req) { + public revokeRole_args setReq(RevokeRoleReq req) { this.req = req; return this; } @@ -27225,7 +27763,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GrantRoleReq)__value); + setReq((RevokeRoleReq)__value); } break; @@ -27250,9 +27788,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof grantRole_args)) + if (!(_that instanceof revokeRole_args)) return false; - grantRole_args that = (grantRole_args)_that; + revokeRole_args that = (revokeRole_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -27265,7 +27803,7 @@ public int hashCode() { } @Override - public int compareTo(grantRole_args other) { + public int compareTo(revokeRole_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -27300,7 +27838,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GrantRoleReq(); + this.req = new RevokeRoleReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -27342,7 +27880,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("grantRole_args"); + StringBuilder sb = new StringBuilder("revokeRole_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -27369,8 +27907,8 @@ public void validate() throws TException { } - public static class grantRole_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("grantRole_result"); + public static class revokeRole_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("revokeRole_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -27388,13 +27926,13 @@ public static class grantRole_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(grantRole_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(revokeRole_result.class, metaDataMap); } - public grantRole_result() { + public revokeRole_result() { } - public grantRole_result( + public revokeRole_result( ExecResp success) { this(); this.success = success; @@ -27403,21 +27941,21 @@ public grantRole_result( /** * Performs a deep copy on other. */ - public grantRole_result(grantRole_result other) { + public revokeRole_result(revokeRole_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public grantRole_result deepCopy() { - return new grantRole_result(this); + public revokeRole_result deepCopy() { + return new revokeRole_result(this); } public ExecResp getSuccess() { return this.success; } - public grantRole_result setSuccess(ExecResp success) { + public revokeRole_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -27468,9 +28006,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof grantRole_result)) + if (!(_that instanceof revokeRole_result)) return false; - grantRole_result that = (grantRole_result)_that; + revokeRole_result that = (revokeRole_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -27483,7 +28021,7 @@ public int hashCode() { } @Override - public int compareTo(grantRole_result other) { + public int compareTo(revokeRole_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -27559,7 +28097,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("grantRole_result"); + StringBuilder sb = new StringBuilder("revokeRole_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -27586,11 +28124,11 @@ public void validate() throws TException { } - public static class revokeRole_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("revokeRole_args"); + public static class listUsers_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listUsers_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RevokeRoleReq req; + public ListUsersReq req; public static final int REQ = 1; // isset id assignments @@ -27600,19 +28138,19 @@ public static class revokeRole_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RevokeRoleReq.class))); + new StructMetaData(TType.STRUCT, ListUsersReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(revokeRole_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listUsers_args.class, metaDataMap); } - public revokeRole_args() { + public listUsers_args() { } - public revokeRole_args( - RevokeRoleReq req) { + public listUsers_args( + ListUsersReq req) { this(); this.req = req; } @@ -27620,21 +28158,21 @@ public revokeRole_args( /** * Performs a deep copy on other. */ - public revokeRole_args(revokeRole_args other) { + public listUsers_args(listUsers_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public revokeRole_args deepCopy() { - return new revokeRole_args(this); + public listUsers_args deepCopy() { + return new listUsers_args(this); } - public RevokeRoleReq getReq() { + public ListUsersReq getReq() { return this.req; } - public revokeRole_args setReq(RevokeRoleReq req) { + public listUsers_args setReq(ListUsersReq req) { this.req = req; return this; } @@ -27660,7 +28198,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RevokeRoleReq)__value); + setReq((ListUsersReq)__value); } break; @@ -27685,9 +28223,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof revokeRole_args)) + if (!(_that instanceof listUsers_args)) return false; - revokeRole_args that = (revokeRole_args)_that; + listUsers_args that = (listUsers_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -27700,7 +28238,7 @@ public int hashCode() { } @Override - public int compareTo(revokeRole_args other) { + public int compareTo(listUsers_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -27735,7 +28273,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RevokeRoleReq(); + this.req = new ListUsersReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -27777,7 +28315,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("revokeRole_args"); + StringBuilder sb = new StringBuilder("listUsers_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -27804,11 +28342,11 @@ public void validate() throws TException { } - public static class revokeRole_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("revokeRole_result"); + public static class listUsers_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listUsers_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListUsersResp success; public static final int SUCCESS = 0; // isset id assignments @@ -27818,19 +28356,19 @@ public static class revokeRole_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListUsersResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(revokeRole_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listUsers_result.class, metaDataMap); } - public revokeRole_result() { + public listUsers_result() { } - public revokeRole_result( - ExecResp success) { + public listUsers_result( + ListUsersResp success) { this(); this.success = success; } @@ -27838,21 +28376,21 @@ public revokeRole_result( /** * Performs a deep copy on other. */ - public revokeRole_result(revokeRole_result other) { + public listUsers_result(listUsers_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public revokeRole_result deepCopy() { - return new revokeRole_result(this); + public listUsers_result deepCopy() { + return new listUsers_result(this); } - public ExecResp getSuccess() { + public ListUsersResp getSuccess() { return this.success; } - public revokeRole_result setSuccess(ExecResp success) { + public listUsers_result setSuccess(ListUsersResp success) { this.success = success; return this; } @@ -27878,7 +28416,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListUsersResp)__value); } break; @@ -27903,9 +28441,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof revokeRole_result)) + if (!(_that instanceof listUsers_result)) return false; - revokeRole_result that = (revokeRole_result)_that; + listUsers_result that = (listUsers_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -27918,7 +28456,7 @@ public int hashCode() { } @Override - public int compareTo(revokeRole_result other) { + public int compareTo(listUsers_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -27953,7 +28491,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListUsersResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -27994,7 +28532,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("revokeRole_result"); + StringBuilder sb = new StringBuilder("listUsers_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -28021,11 +28559,11 @@ public void validate() throws TException { } - public static class listUsers_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listUsers_args"); + public static class listRoles_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listRoles_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListUsersReq req; + public ListRolesReq req; public static final int REQ = 1; // isset id assignments @@ -28035,19 +28573,19 @@ public static class listUsers_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListUsersReq.class))); + new StructMetaData(TType.STRUCT, ListRolesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listUsers_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listRoles_args.class, metaDataMap); } - public listUsers_args() { + public listRoles_args() { } - public listUsers_args( - ListUsersReq req) { + public listRoles_args( + ListRolesReq req) { this(); this.req = req; } @@ -28055,21 +28593,21 @@ public listUsers_args( /** * Performs a deep copy on other. */ - public listUsers_args(listUsers_args other) { + public listRoles_args(listRoles_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listUsers_args deepCopy() { - return new listUsers_args(this); + public listRoles_args deepCopy() { + return new listRoles_args(this); } - public ListUsersReq getReq() { + public ListRolesReq getReq() { return this.req; } - public listUsers_args setReq(ListUsersReq req) { + public listRoles_args setReq(ListRolesReq req) { this.req = req; return this; } @@ -28095,7 +28633,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListUsersReq)__value); + setReq((ListRolesReq)__value); } break; @@ -28120,9 +28658,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listUsers_args)) + if (!(_that instanceof listRoles_args)) return false; - listUsers_args that = (listUsers_args)_that; + listRoles_args that = (listRoles_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -28135,7 +28673,7 @@ public int hashCode() { } @Override - public int compareTo(listUsers_args other) { + public int compareTo(listRoles_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -28170,7 +28708,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListUsersReq(); + this.req = new ListRolesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -28212,7 +28750,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listUsers_args"); + StringBuilder sb = new StringBuilder("listRoles_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -28239,11 +28777,11 @@ public void validate() throws TException { } - public static class listUsers_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listUsers_result"); + public static class listRoles_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listRoles_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListUsersResp success; + public ListRolesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -28253,19 +28791,19 @@ public static class listUsers_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListUsersResp.class))); + new StructMetaData(TType.STRUCT, ListRolesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listUsers_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listRoles_result.class, metaDataMap); } - public listUsers_result() { + public listRoles_result() { } - public listUsers_result( - ListUsersResp success) { + public listRoles_result( + ListRolesResp success) { this(); this.success = success; } @@ -28273,21 +28811,21 @@ public listUsers_result( /** * Performs a deep copy on other. */ - public listUsers_result(listUsers_result other) { + public listRoles_result(listRoles_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listUsers_result deepCopy() { - return new listUsers_result(this); + public listRoles_result deepCopy() { + return new listRoles_result(this); } - public ListUsersResp getSuccess() { + public ListRolesResp getSuccess() { return this.success; } - public listUsers_result setSuccess(ListUsersResp success) { + public listRoles_result setSuccess(ListRolesResp success) { this.success = success; return this; } @@ -28313,7 +28851,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListUsersResp)__value); + setSuccess((ListRolesResp)__value); } break; @@ -28338,9 +28876,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listUsers_result)) + if (!(_that instanceof listRoles_result)) return false; - listUsers_result that = (listUsers_result)_that; + listRoles_result that = (listRoles_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -28353,7 +28891,7 @@ public int hashCode() { } @Override - public int compareTo(listUsers_result other) { + public int compareTo(listRoles_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -28388,7 +28926,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListUsersResp(); + this.success = new ListRolesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -28429,7 +28967,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listUsers_result"); + StringBuilder sb = new StringBuilder("listRoles_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -28456,11 +28994,11 @@ public void validate() throws TException { } - public static class listRoles_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listRoles_args"); + public static class getUserRoles_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getUserRoles_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListRolesReq req; + public GetUserRolesReq req; public static final int REQ = 1; // isset id assignments @@ -28470,19 +29008,19 @@ public static class listRoles_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListRolesReq.class))); + new StructMetaData(TType.STRUCT, GetUserRolesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listRoles_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getUserRoles_args.class, metaDataMap); } - public listRoles_args() { + public getUserRoles_args() { } - public listRoles_args( - ListRolesReq req) { + public getUserRoles_args( + GetUserRolesReq req) { this(); this.req = req; } @@ -28490,21 +29028,21 @@ public listRoles_args( /** * Performs a deep copy on other. */ - public listRoles_args(listRoles_args other) { + public getUserRoles_args(getUserRoles_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listRoles_args deepCopy() { - return new listRoles_args(this); + public getUserRoles_args deepCopy() { + return new getUserRoles_args(this); } - public ListRolesReq getReq() { + public GetUserRolesReq getReq() { return this.req; } - public listRoles_args setReq(ListRolesReq req) { + public getUserRoles_args setReq(GetUserRolesReq req) { this.req = req; return this; } @@ -28530,7 +29068,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListRolesReq)__value); + setReq((GetUserRolesReq)__value); } break; @@ -28555,9 +29093,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listRoles_args)) + if (!(_that instanceof getUserRoles_args)) return false; - listRoles_args that = (listRoles_args)_that; + getUserRoles_args that = (getUserRoles_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -28570,7 +29108,7 @@ public int hashCode() { } @Override - public int compareTo(listRoles_args other) { + public int compareTo(getUserRoles_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -28605,7 +29143,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListRolesReq(); + this.req = new GetUserRolesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -28647,7 +29185,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listRoles_args"); + StringBuilder sb = new StringBuilder("getUserRoles_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -28674,8 +29212,8 @@ public void validate() throws TException { } - public static class listRoles_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listRoles_result"); + public static class getUserRoles_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getUserRoles_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ListRolesResp success; @@ -28693,13 +29231,13 @@ public static class listRoles_result implements TBase, java.io.Serializable, Clo } static { - FieldMetaData.addStructMetaDataMap(listRoles_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getUserRoles_result.class, metaDataMap); } - public listRoles_result() { + public getUserRoles_result() { } - public listRoles_result( + public getUserRoles_result( ListRolesResp success) { this(); this.success = success; @@ -28708,21 +29246,21 @@ public listRoles_result( /** * Performs a deep copy on other. */ - public listRoles_result(listRoles_result other) { + public getUserRoles_result(getUserRoles_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listRoles_result deepCopy() { - return new listRoles_result(this); + public getUserRoles_result deepCopy() { + return new getUserRoles_result(this); } public ListRolesResp getSuccess() { return this.success; } - public listRoles_result setSuccess(ListRolesResp success) { + public getUserRoles_result setSuccess(ListRolesResp success) { this.success = success; return this; } @@ -28773,9 +29311,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listRoles_result)) + if (!(_that instanceof getUserRoles_result)) return false; - listRoles_result that = (listRoles_result)_that; + getUserRoles_result that = (getUserRoles_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -28788,7 +29326,7 @@ public int hashCode() { } @Override - public int compareTo(listRoles_result other) { + public int compareTo(getUserRoles_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -28864,7 +29402,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listRoles_result"); + StringBuilder sb = new StringBuilder("getUserRoles_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -28891,11 +29429,11 @@ public void validate() throws TException { } - public static class getUserRoles_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getUserRoles_args"); + public static class changePassword_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("changePassword_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetUserRolesReq req; + public ChangePasswordReq req; public static final int REQ = 1; // isset id assignments @@ -28905,19 +29443,19 @@ public static class getUserRoles_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetUserRolesReq.class))); + new StructMetaData(TType.STRUCT, ChangePasswordReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getUserRoles_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(changePassword_args.class, metaDataMap); } - public getUserRoles_args() { + public changePassword_args() { } - public getUserRoles_args( - GetUserRolesReq req) { + public changePassword_args( + ChangePasswordReq req) { this(); this.req = req; } @@ -28925,21 +29463,21 @@ public getUserRoles_args( /** * Performs a deep copy on other. */ - public getUserRoles_args(getUserRoles_args other) { + public changePassword_args(changePassword_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getUserRoles_args deepCopy() { - return new getUserRoles_args(this); + public changePassword_args deepCopy() { + return new changePassword_args(this); } - public GetUserRolesReq getReq() { + public ChangePasswordReq getReq() { return this.req; } - public getUserRoles_args setReq(GetUserRolesReq req) { + public changePassword_args setReq(ChangePasswordReq req) { this.req = req; return this; } @@ -28965,7 +29503,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetUserRolesReq)__value); + setReq((ChangePasswordReq)__value); } break; @@ -28990,9 +29528,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getUserRoles_args)) + if (!(_that instanceof changePassword_args)) return false; - getUserRoles_args that = (getUserRoles_args)_that; + changePassword_args that = (changePassword_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -29005,7 +29543,7 @@ public int hashCode() { } @Override - public int compareTo(getUserRoles_args other) { + public int compareTo(changePassword_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29040,7 +29578,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetUserRolesReq(); + this.req = new ChangePasswordReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29082,7 +29620,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getUserRoles_args"); + StringBuilder sb = new StringBuilder("changePassword_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29109,11 +29647,11 @@ public void validate() throws TException { } - public static class getUserRoles_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getUserRoles_result"); + public static class changePassword_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("changePassword_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListRolesResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -29123,19 +29661,19 @@ public static class getUserRoles_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListRolesResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getUserRoles_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(changePassword_result.class, metaDataMap); } - public getUserRoles_result() { + public changePassword_result() { } - public getUserRoles_result( - ListRolesResp success) { + public changePassword_result( + ExecResp success) { this(); this.success = success; } @@ -29143,21 +29681,21 @@ public getUserRoles_result( /** * Performs a deep copy on other. */ - public getUserRoles_result(getUserRoles_result other) { + public changePassword_result(changePassword_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getUserRoles_result deepCopy() { - return new getUserRoles_result(this); + public changePassword_result deepCopy() { + return new changePassword_result(this); } - public ListRolesResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public getUserRoles_result setSuccess(ListRolesResp success) { + public changePassword_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -29183,7 +29721,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListRolesResp)__value); + setSuccess((ExecResp)__value); } break; @@ -29208,9 +29746,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getUserRoles_result)) + if (!(_that instanceof changePassword_result)) return false; - getUserRoles_result that = (getUserRoles_result)_that; + changePassword_result that = (changePassword_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -29223,7 +29761,7 @@ public int hashCode() { } @Override - public int compareTo(getUserRoles_result other) { + public int compareTo(changePassword_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29258,7 +29796,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListRolesResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29299,7 +29837,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getUserRoles_result"); + StringBuilder sb = new StringBuilder("changePassword_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29326,11 +29864,11 @@ public void validate() throws TException { } - public static class changePassword_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("changePassword_args"); + public static class heartBeat_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("heartBeat_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ChangePasswordReq req; + public HBReq req; public static final int REQ = 1; // isset id assignments @@ -29340,19 +29878,19 @@ public static class changePassword_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ChangePasswordReq.class))); + new StructMetaData(TType.STRUCT, HBReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(changePassword_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(heartBeat_args.class, metaDataMap); } - public changePassword_args() { + public heartBeat_args() { } - public changePassword_args( - ChangePasswordReq req) { + public heartBeat_args( + HBReq req) { this(); this.req = req; } @@ -29360,21 +29898,21 @@ public changePassword_args( /** * Performs a deep copy on other. */ - public changePassword_args(changePassword_args other) { + public heartBeat_args(heartBeat_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public changePassword_args deepCopy() { - return new changePassword_args(this); + public heartBeat_args deepCopy() { + return new heartBeat_args(this); } - public ChangePasswordReq getReq() { + public HBReq getReq() { return this.req; } - public changePassword_args setReq(ChangePasswordReq req) { + public heartBeat_args setReq(HBReq req) { this.req = req; return this; } @@ -29400,7 +29938,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ChangePasswordReq)__value); + setReq((HBReq)__value); } break; @@ -29425,9 +29963,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof changePassword_args)) + if (!(_that instanceof heartBeat_args)) return false; - changePassword_args that = (changePassword_args)_that; + heartBeat_args that = (heartBeat_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -29440,7 +29978,7 @@ public int hashCode() { } @Override - public int compareTo(changePassword_args other) { + public int compareTo(heartBeat_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29475,7 +30013,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ChangePasswordReq(); + this.req = new HBReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29517,7 +30055,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("changePassword_args"); + StringBuilder sb = new StringBuilder("heartBeat_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29544,11 +30082,11 @@ public void validate() throws TException { } - public static class changePassword_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("changePassword_result"); + public static class heartBeat_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("heartBeat_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public HBResp success; public static final int SUCCESS = 0; // isset id assignments @@ -29558,19 +30096,19 @@ public static class changePassword_result implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, HBResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(changePassword_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(heartBeat_result.class, metaDataMap); } - public changePassword_result() { + public heartBeat_result() { } - public changePassword_result( - ExecResp success) { + public heartBeat_result( + HBResp success) { this(); this.success = success; } @@ -29578,21 +30116,21 @@ public changePassword_result( /** * Performs a deep copy on other. */ - public changePassword_result(changePassword_result other) { + public heartBeat_result(heartBeat_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public changePassword_result deepCopy() { - return new changePassword_result(this); + public heartBeat_result deepCopy() { + return new heartBeat_result(this); } - public ExecResp getSuccess() { + public HBResp getSuccess() { return this.success; } - public changePassword_result setSuccess(ExecResp success) { + public heartBeat_result setSuccess(HBResp success) { this.success = success; return this; } @@ -29618,7 +30156,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((HBResp)__value); } break; @@ -29643,9 +30181,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof changePassword_result)) + if (!(_that instanceof heartBeat_result)) return false; - changePassword_result that = (changePassword_result)_that; + heartBeat_result that = (heartBeat_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -29658,7 +30196,7 @@ public int hashCode() { } @Override - public int compareTo(changePassword_result other) { + public int compareTo(heartBeat_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29693,7 +30231,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new HBResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29734,7 +30272,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("changePassword_result"); + StringBuilder sb = new StringBuilder("heartBeat_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29761,11 +30299,11 @@ public void validate() throws TException { } - public static class heartBeat_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("heartBeat_args"); + public static class agentHeartbeat_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("agentHeartbeat_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public HBReq req; + public AgentHBReq req; public static final int REQ = 1; // isset id assignments @@ -29775,19 +30313,19 @@ public static class heartBeat_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, HBReq.class))); + new StructMetaData(TType.STRUCT, AgentHBReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(heartBeat_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(agentHeartbeat_args.class, metaDataMap); } - public heartBeat_args() { + public agentHeartbeat_args() { } - public heartBeat_args( - HBReq req) { + public agentHeartbeat_args( + AgentHBReq req) { this(); this.req = req; } @@ -29795,21 +30333,21 @@ public heartBeat_args( /** * Performs a deep copy on other. */ - public heartBeat_args(heartBeat_args other) { + public agentHeartbeat_args(agentHeartbeat_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public heartBeat_args deepCopy() { - return new heartBeat_args(this); + public agentHeartbeat_args deepCopy() { + return new agentHeartbeat_args(this); } - public HBReq getReq() { + public AgentHBReq getReq() { return this.req; } - public heartBeat_args setReq(HBReq req) { + public agentHeartbeat_args setReq(AgentHBReq req) { this.req = req; return this; } @@ -29835,7 +30373,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((HBReq)__value); + setReq((AgentHBReq)__value); } break; @@ -29860,9 +30398,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof heartBeat_args)) + if (!(_that instanceof agentHeartbeat_args)) return false; - heartBeat_args that = (heartBeat_args)_that; + agentHeartbeat_args that = (agentHeartbeat_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -29875,7 +30413,7 @@ public int hashCode() { } @Override - public int compareTo(heartBeat_args other) { + public int compareTo(agentHeartbeat_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -29910,7 +30448,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new HBReq(); + this.req = new AgentHBReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -29952,7 +30490,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("heartBeat_args"); + StringBuilder sb = new StringBuilder("agentHeartbeat_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -29979,11 +30517,11 @@ public void validate() throws TException { } - public static class heartBeat_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("heartBeat_result"); + public static class agentHeartbeat_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("agentHeartbeat_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public HBResp success; + public AgentHBResp success; public static final int SUCCESS = 0; // isset id assignments @@ -29993,19 +30531,19 @@ public static class heartBeat_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, HBResp.class))); + new StructMetaData(TType.STRUCT, AgentHBResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(heartBeat_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(agentHeartbeat_result.class, metaDataMap); } - public heartBeat_result() { + public agentHeartbeat_result() { } - public heartBeat_result( - HBResp success) { + public agentHeartbeat_result( + AgentHBResp success) { this(); this.success = success; } @@ -30013,21 +30551,21 @@ public heartBeat_result( /** * Performs a deep copy on other. */ - public heartBeat_result(heartBeat_result other) { + public agentHeartbeat_result(agentHeartbeat_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public heartBeat_result deepCopy() { - return new heartBeat_result(this); + public agentHeartbeat_result deepCopy() { + return new agentHeartbeat_result(this); } - public HBResp getSuccess() { + public AgentHBResp getSuccess() { return this.success; } - public heartBeat_result setSuccess(HBResp success) { + public agentHeartbeat_result setSuccess(AgentHBResp success) { this.success = success; return this; } @@ -30053,7 +30591,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((HBResp)__value); + setSuccess((AgentHBResp)__value); } break; @@ -30078,9 +30616,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof heartBeat_result)) + if (!(_that instanceof agentHeartbeat_result)) return false; - heartBeat_result that = (heartBeat_result)_that; + agentHeartbeat_result that = (agentHeartbeat_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -30093,7 +30631,7 @@ public int hashCode() { } @Override - public int compareTo(heartBeat_result other) { + public int compareTo(agentHeartbeat_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -30128,7 +30666,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new HBResp(); + this.success = new AgentHBResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -30169,7 +30707,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("heartBeat_result"); + StringBuilder sb = new StringBuilder("agentHeartbeat_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -36171,11 +36709,11 @@ public void validate() throws TException { } - public static class createBackup_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createBackup_args"); + public static class addListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addListener_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateBackupReq req; + public AddListenerReq req; public static final int REQ = 1; // isset id assignments @@ -36185,19 +36723,19 @@ public static class createBackup_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateBackupReq.class))); + new StructMetaData(TType.STRUCT, AddListenerReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createBackup_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addListener_args.class, metaDataMap); } - public createBackup_args() { + public addListener_args() { } - public createBackup_args( - CreateBackupReq req) { + public addListener_args( + AddListenerReq req) { this(); this.req = req; } @@ -36205,21 +36743,21 @@ public createBackup_args( /** * Performs a deep copy on other. */ - public createBackup_args(createBackup_args other) { + public addListener_args(addListener_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createBackup_args deepCopy() { - return new createBackup_args(this); + public addListener_args deepCopy() { + return new addListener_args(this); } - public CreateBackupReq getReq() { + public AddListenerReq getReq() { return this.req; } - public createBackup_args setReq(CreateBackupReq req) { + public addListener_args setReq(AddListenerReq req) { this.req = req; return this; } @@ -36245,7 +36783,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateBackupReq)__value); + setReq((AddListenerReq)__value); } break; @@ -36270,9 +36808,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createBackup_args)) + if (!(_that instanceof addListener_args)) return false; - createBackup_args that = (createBackup_args)_that; + addListener_args that = (addListener_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -36285,7 +36823,7 @@ public int hashCode() { } @Override - public int compareTo(createBackup_args other) { + public int compareTo(addListener_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -36320,7 +36858,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateBackupReq(); + this.req = new AddListenerReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -36362,7 +36900,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createBackup_args"); + StringBuilder sb = new StringBuilder("addListener_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -36389,11 +36927,11 @@ public void validate() throws TException { } - public static class createBackup_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createBackup_result"); + public static class addListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("addListener_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public CreateBackupResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -36403,19 +36941,19 @@ public static class createBackup_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateBackupResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createBackup_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(addListener_result.class, metaDataMap); } - public createBackup_result() { + public addListener_result() { } - public createBackup_result( - CreateBackupResp success) { + public addListener_result( + ExecResp success) { this(); this.success = success; } @@ -36423,21 +36961,21 @@ public createBackup_result( /** * Performs a deep copy on other. */ - public createBackup_result(createBackup_result other) { + public addListener_result(addListener_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createBackup_result deepCopy() { - return new createBackup_result(this); + public addListener_result deepCopy() { + return new addListener_result(this); } - public CreateBackupResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public createBackup_result setSuccess(CreateBackupResp success) { + public addListener_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -36463,7 +37001,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((CreateBackupResp)__value); + setSuccess((ExecResp)__value); } break; @@ -36488,9 +37026,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createBackup_result)) + if (!(_that instanceof addListener_result)) return false; - createBackup_result that = (createBackup_result)_that; + addListener_result that = (addListener_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -36503,7 +37041,7 @@ public int hashCode() { } @Override - public int compareTo(createBackup_result other) { + public int compareTo(addListener_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -36538,7 +37076,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new CreateBackupResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -36579,7 +37117,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createBackup_result"); + StringBuilder sb = new StringBuilder("addListener_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -36606,11 +37144,11 @@ public void validate() throws TException { } - public static class restoreMeta_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("restoreMeta_args"); + public static class removeListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeListener_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RestoreMetaReq req; + public RemoveListenerReq req; public static final int REQ = 1; // isset id assignments @@ -36620,19 +37158,19 @@ public static class restoreMeta_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RestoreMetaReq.class))); + new StructMetaData(TType.STRUCT, RemoveListenerReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(restoreMeta_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeListener_args.class, metaDataMap); } - public restoreMeta_args() { + public removeListener_args() { } - public restoreMeta_args( - RestoreMetaReq req) { + public removeListener_args( + RemoveListenerReq req) { this(); this.req = req; } @@ -36640,21 +37178,21 @@ public restoreMeta_args( /** * Performs a deep copy on other. */ - public restoreMeta_args(restoreMeta_args other) { + public removeListener_args(removeListener_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public restoreMeta_args deepCopy() { - return new restoreMeta_args(this); + public removeListener_args deepCopy() { + return new removeListener_args(this); } - public RestoreMetaReq getReq() { + public RemoveListenerReq getReq() { return this.req; } - public restoreMeta_args setReq(RestoreMetaReq req) { + public removeListener_args setReq(RemoveListenerReq req) { this.req = req; return this; } @@ -36680,7 +37218,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RestoreMetaReq)__value); + setReq((RemoveListenerReq)__value); } break; @@ -36705,9 +37243,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof restoreMeta_args)) + if (!(_that instanceof removeListener_args)) return false; - restoreMeta_args that = (restoreMeta_args)_that; + removeListener_args that = (removeListener_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -36720,7 +37258,7 @@ public int hashCode() { } @Override - public int compareTo(restoreMeta_args other) { + public int compareTo(removeListener_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -36755,7 +37293,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RestoreMetaReq(); + this.req = new RemoveListenerReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -36797,7 +37335,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("restoreMeta_args"); + StringBuilder sb = new StringBuilder("removeListener_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -36824,8 +37362,8 @@ public void validate() throws TException { } - public static class restoreMeta_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("restoreMeta_result"); + public static class removeListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeListener_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -36843,13 +37381,13 @@ public static class restoreMeta_result implements TBase, java.io.Serializable, C } static { - FieldMetaData.addStructMetaDataMap(restoreMeta_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeListener_result.class, metaDataMap); } - public restoreMeta_result() { + public removeListener_result() { } - public restoreMeta_result( + public removeListener_result( ExecResp success) { this(); this.success = success; @@ -36858,21 +37396,21 @@ public restoreMeta_result( /** * Performs a deep copy on other. */ - public restoreMeta_result(restoreMeta_result other) { + public removeListener_result(removeListener_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public restoreMeta_result deepCopy() { - return new restoreMeta_result(this); + public removeListener_result deepCopy() { + return new removeListener_result(this); } public ExecResp getSuccess() { return this.success; } - public restoreMeta_result setSuccess(ExecResp success) { + public removeListener_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -36923,9 +37461,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof restoreMeta_result)) + if (!(_that instanceof removeListener_result)) return false; - restoreMeta_result that = (restoreMeta_result)_that; + removeListener_result that = (removeListener_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -36938,7 +37476,7 @@ public int hashCode() { } @Override - public int compareTo(restoreMeta_result other) { + public int compareTo(removeListener_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -37014,7 +37552,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("restoreMeta_result"); + StringBuilder sb = new StringBuilder("removeListener_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -37041,11 +37579,11 @@ public void validate() throws TException { } - public static class addListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addListener_args"); + public static class listListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listListener_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public AddListenerReq req; + public ListListenerReq req; public static final int REQ = 1; // isset id assignments @@ -37055,19 +37593,19 @@ public static class addListener_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, AddListenerReq.class))); + new StructMetaData(TType.STRUCT, ListListenerReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addListener_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listListener_args.class, metaDataMap); } - public addListener_args() { + public listListener_args() { } - public addListener_args( - AddListenerReq req) { + public listListener_args( + ListListenerReq req) { this(); this.req = req; } @@ -37075,21 +37613,21 @@ public addListener_args( /** * Performs a deep copy on other. */ - public addListener_args(addListener_args other) { + public listListener_args(listListener_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public addListener_args deepCopy() { - return new addListener_args(this); + public listListener_args deepCopy() { + return new listListener_args(this); } - public AddListenerReq getReq() { + public ListListenerReq getReq() { return this.req; } - public addListener_args setReq(AddListenerReq req) { + public listListener_args setReq(ListListenerReq req) { this.req = req; return this; } @@ -37115,7 +37653,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((AddListenerReq)__value); + setReq((ListListenerReq)__value); } break; @@ -37140,9 +37678,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addListener_args)) + if (!(_that instanceof listListener_args)) return false; - addListener_args that = (addListener_args)_that; + listListener_args that = (listListener_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -37155,7 +37693,7 @@ public int hashCode() { } @Override - public int compareTo(addListener_args other) { + public int compareTo(listListener_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -37190,7 +37728,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new AddListenerReq(); + this.req = new ListListenerReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -37232,7 +37770,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addListener_args"); + StringBuilder sb = new StringBuilder("listListener_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -37259,11 +37797,11 @@ public void validate() throws TException { } - public static class addListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("addListener_result"); + public static class listListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listListener_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListListenerResp success; public static final int SUCCESS = 0; // isset id assignments @@ -37273,19 +37811,19 @@ public static class addListener_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListListenerResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(addListener_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listListener_result.class, metaDataMap); } - public addListener_result() { + public listListener_result() { } - public addListener_result( - ExecResp success) { + public listListener_result( + ListListenerResp success) { this(); this.success = success; } @@ -37293,21 +37831,21 @@ public addListener_result( /** * Performs a deep copy on other. */ - public addListener_result(addListener_result other) { + public listListener_result(listListener_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public addListener_result deepCopy() { - return new addListener_result(this); + public listListener_result deepCopy() { + return new listListener_result(this); } - public ExecResp getSuccess() { + public ListListenerResp getSuccess() { return this.success; } - public addListener_result setSuccess(ExecResp success) { + public listListener_result setSuccess(ListListenerResp success) { this.success = success; return this; } @@ -37333,7 +37871,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListListenerResp)__value); } break; @@ -37358,9 +37896,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof addListener_result)) + if (!(_that instanceof listListener_result)) return false; - addListener_result that = (addListener_result)_that; + listListener_result that = (listListener_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -37373,7 +37911,7 @@ public int hashCode() { } @Override - public int compareTo(addListener_result other) { + public int compareTo(listListener_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -37408,7 +37946,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListListenerResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -37449,7 +37987,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("addListener_result"); + StringBuilder sb = new StringBuilder("listListener_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -37476,11 +38014,11 @@ public void validate() throws TException { } - public static class removeListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeListener_args"); + public static class getStats_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getStats_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RemoveListenerReq req; + public GetStatsReq req; public static final int REQ = 1; // isset id assignments @@ -37490,19 +38028,19 @@ public static class removeListener_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RemoveListenerReq.class))); + new StructMetaData(TType.STRUCT, GetStatsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(removeListener_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getStats_args.class, metaDataMap); } - public removeListener_args() { + public getStats_args() { } - public removeListener_args( - RemoveListenerReq req) { + public getStats_args( + GetStatsReq req) { this(); this.req = req; } @@ -37510,21 +38048,21 @@ public removeListener_args( /** * Performs a deep copy on other. */ - public removeListener_args(removeListener_args other) { + public getStats_args(getStats_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public removeListener_args deepCopy() { - return new removeListener_args(this); + public getStats_args deepCopy() { + return new getStats_args(this); } - public RemoveListenerReq getReq() { + public GetStatsReq getReq() { return this.req; } - public removeListener_args setReq(RemoveListenerReq req) { + public getStats_args setReq(GetStatsReq req) { this.req = req; return this; } @@ -37550,7 +38088,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RemoveListenerReq)__value); + setReq((GetStatsReq)__value); } break; @@ -37575,9 +38113,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeListener_args)) + if (!(_that instanceof getStats_args)) return false; - removeListener_args that = (removeListener_args)_that; + getStats_args that = (getStats_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -37590,7 +38128,7 @@ public int hashCode() { } @Override - public int compareTo(removeListener_args other) { + public int compareTo(getStats_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -37625,7 +38163,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RemoveListenerReq(); + this.req = new GetStatsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -37667,7 +38205,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeListener_args"); + StringBuilder sb = new StringBuilder("getStats_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -37694,11 +38232,11 @@ public void validate() throws TException { } - public static class removeListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeListener_result"); + public static class getStats_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getStats_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public GetStatsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -37708,19 +38246,19 @@ public static class removeListener_result implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, GetStatsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(removeListener_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getStats_result.class, metaDataMap); } - public removeListener_result() { + public getStats_result() { } - public removeListener_result( - ExecResp success) { + public getStats_result( + GetStatsResp success) { this(); this.success = success; } @@ -37728,21 +38266,21 @@ public removeListener_result( /** * Performs a deep copy on other. */ - public removeListener_result(removeListener_result other) { + public getStats_result(getStats_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public removeListener_result deepCopy() { - return new removeListener_result(this); + public getStats_result deepCopy() { + return new getStats_result(this); } - public ExecResp getSuccess() { + public GetStatsResp getSuccess() { return this.success; } - public removeListener_result setSuccess(ExecResp success) { + public getStats_result setSuccess(GetStatsResp success) { this.success = success; return this; } @@ -37768,7 +38306,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((GetStatsResp)__value); } break; @@ -37793,9 +38331,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeListener_result)) + if (!(_that instanceof getStats_result)) return false; - removeListener_result that = (removeListener_result)_that; + getStats_result that = (getStats_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -37808,7 +38346,7 @@ public int hashCode() { } @Override - public int compareTo(removeListener_result other) { + public int compareTo(getStats_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -37843,7 +38381,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new GetStatsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -37884,7 +38422,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeListener_result"); + StringBuilder sb = new StringBuilder("getStats_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -37911,11 +38449,11 @@ public void validate() throws TException { } - public static class listListener_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listListener_args"); + public static class signInFTService_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("signInFTService_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListListenerReq req; + public SignInFTServiceReq req; public static final int REQ = 1; // isset id assignments @@ -37925,19 +38463,19 @@ public static class listListener_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListListenerReq.class))); + new StructMetaData(TType.STRUCT, SignInFTServiceReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listListener_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(signInFTService_args.class, metaDataMap); } - public listListener_args() { + public signInFTService_args() { } - public listListener_args( - ListListenerReq req) { + public signInFTService_args( + SignInFTServiceReq req) { this(); this.req = req; } @@ -37945,21 +38483,21 @@ public listListener_args( /** * Performs a deep copy on other. */ - public listListener_args(listListener_args other) { + public signInFTService_args(signInFTService_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listListener_args deepCopy() { - return new listListener_args(this); + public signInFTService_args deepCopy() { + return new signInFTService_args(this); } - public ListListenerReq getReq() { + public SignInFTServiceReq getReq() { return this.req; } - public listListener_args setReq(ListListenerReq req) { + public signInFTService_args setReq(SignInFTServiceReq req) { this.req = req; return this; } @@ -37985,7 +38523,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListListenerReq)__value); + setReq((SignInFTServiceReq)__value); } break; @@ -38010,9 +38548,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listListener_args)) + if (!(_that instanceof signInFTService_args)) return false; - listListener_args that = (listListener_args)_that; + signInFTService_args that = (signInFTService_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -38025,7 +38563,7 @@ public int hashCode() { } @Override - public int compareTo(listListener_args other) { + public int compareTo(signInFTService_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38060,7 +38598,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListListenerReq(); + this.req = new SignInFTServiceReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38102,7 +38640,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listListener_args"); + StringBuilder sb = new StringBuilder("signInFTService_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -38129,11 +38667,11 @@ public void validate() throws TException { } - public static class listListener_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listListener_result"); + public static class signInFTService_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("signInFTService_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListListenerResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -38143,19 +38681,19 @@ public static class listListener_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListListenerResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listListener_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(signInFTService_result.class, metaDataMap); } - public listListener_result() { + public signInFTService_result() { } - public listListener_result( - ListListenerResp success) { + public signInFTService_result( + ExecResp success) { this(); this.success = success; } @@ -38163,21 +38701,21 @@ public listListener_result( /** * Performs a deep copy on other. */ - public listListener_result(listListener_result other) { + public signInFTService_result(signInFTService_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listListener_result deepCopy() { - return new listListener_result(this); + public signInFTService_result deepCopy() { + return new signInFTService_result(this); } - public ListListenerResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listListener_result setSuccess(ListListenerResp success) { + public signInFTService_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -38203,7 +38741,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListListenerResp)__value); + setSuccess((ExecResp)__value); } break; @@ -38228,9 +38766,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listListener_result)) + if (!(_that instanceof signInFTService_result)) return false; - listListener_result that = (listListener_result)_that; + signInFTService_result that = (signInFTService_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -38243,7 +38781,7 @@ public int hashCode() { } @Override - public int compareTo(listListener_result other) { + public int compareTo(signInFTService_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38278,7 +38816,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListListenerResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38319,7 +38857,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listListener_result"); + StringBuilder sb = new StringBuilder("signInFTService_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -38346,11 +38884,11 @@ public void validate() throws TException { } - public static class getStats_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getStats_args"); + public static class signOutFTService_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("signOutFTService_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetStatsReq req; + public SignOutFTServiceReq req; public static final int REQ = 1; // isset id assignments @@ -38360,19 +38898,19 @@ public static class getStats_args implements TBase, java.io.Serializable, Clonea static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetStatsReq.class))); + new StructMetaData(TType.STRUCT, SignOutFTServiceReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getStats_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(signOutFTService_args.class, metaDataMap); } - public getStats_args() { + public signOutFTService_args() { } - public getStats_args( - GetStatsReq req) { + public signOutFTService_args( + SignOutFTServiceReq req) { this(); this.req = req; } @@ -38380,21 +38918,21 @@ public getStats_args( /** * Performs a deep copy on other. */ - public getStats_args(getStats_args other) { + public signOutFTService_args(signOutFTService_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getStats_args deepCopy() { - return new getStats_args(this); + public signOutFTService_args deepCopy() { + return new signOutFTService_args(this); } - public GetStatsReq getReq() { + public SignOutFTServiceReq getReq() { return this.req; } - public getStats_args setReq(GetStatsReq req) { + public signOutFTService_args setReq(SignOutFTServiceReq req) { this.req = req; return this; } @@ -38420,7 +38958,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetStatsReq)__value); + setReq((SignOutFTServiceReq)__value); } break; @@ -38445,9 +38983,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getStats_args)) + if (!(_that instanceof signOutFTService_args)) return false; - getStats_args that = (getStats_args)_that; + signOutFTService_args that = (signOutFTService_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -38460,7 +38998,7 @@ public int hashCode() { } @Override - public int compareTo(getStats_args other) { + public int compareTo(signOutFTService_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38495,7 +39033,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetStatsReq(); + this.req = new SignOutFTServiceReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38537,7 +39075,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getStats_args"); + StringBuilder sb = new StringBuilder("signOutFTService_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -38564,11 +39102,11 @@ public void validate() throws TException { } - public static class getStats_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getStats_result"); + public static class signOutFTService_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("signOutFTService_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetStatsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -38578,19 +39116,19 @@ public static class getStats_result implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetStatsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getStats_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(signOutFTService_result.class, metaDataMap); } - public getStats_result() { + public signOutFTService_result() { } - public getStats_result( - GetStatsResp success) { + public signOutFTService_result( + ExecResp success) { this(); this.success = success; } @@ -38598,21 +39136,21 @@ public getStats_result( /** * Performs a deep copy on other. */ - public getStats_result(getStats_result other) { + public signOutFTService_result(signOutFTService_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getStats_result deepCopy() { - return new getStats_result(this); + public signOutFTService_result deepCopy() { + return new signOutFTService_result(this); } - public GetStatsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public getStats_result setSuccess(GetStatsResp success) { + public signOutFTService_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -38638,7 +39176,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetStatsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -38663,9 +39201,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getStats_result)) + if (!(_that instanceof signOutFTService_result)) return false; - getStats_result that = (getStats_result)_that; + signOutFTService_result that = (signOutFTService_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -38678,7 +39216,7 @@ public int hashCode() { } @Override - public int compareTo(getStats_result other) { + public int compareTo(signOutFTService_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38713,7 +39251,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetStatsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38754,7 +39292,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getStats_result"); + StringBuilder sb = new StringBuilder("signOutFTService_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -38781,11 +39319,11 @@ public void validate() throws TException { } - public static class signInFTService_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("signInFTService_args"); + public static class listFTClients_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listFTClients_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public SignInFTServiceReq req; + public ListFTClientsReq req; public static final int REQ = 1; // isset id assignments @@ -38795,19 +39333,19 @@ public static class signInFTService_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, SignInFTServiceReq.class))); + new StructMetaData(TType.STRUCT, ListFTClientsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(signInFTService_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listFTClients_args.class, metaDataMap); } - public signInFTService_args() { + public listFTClients_args() { } - public signInFTService_args( - SignInFTServiceReq req) { + public listFTClients_args( + ListFTClientsReq req) { this(); this.req = req; } @@ -38815,21 +39353,21 @@ public signInFTService_args( /** * Performs a deep copy on other. */ - public signInFTService_args(signInFTService_args other) { + public listFTClients_args(listFTClients_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public signInFTService_args deepCopy() { - return new signInFTService_args(this); + public listFTClients_args deepCopy() { + return new listFTClients_args(this); } - public SignInFTServiceReq getReq() { + public ListFTClientsReq getReq() { return this.req; } - public signInFTService_args setReq(SignInFTServiceReq req) { + public listFTClients_args setReq(ListFTClientsReq req) { this.req = req; return this; } @@ -38855,7 +39393,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((SignInFTServiceReq)__value); + setReq((ListFTClientsReq)__value); } break; @@ -38880,9 +39418,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof signInFTService_args)) + if (!(_that instanceof listFTClients_args)) return false; - signInFTService_args that = (signInFTService_args)_that; + listFTClients_args that = (listFTClients_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -38895,7 +39433,7 @@ public int hashCode() { } @Override - public int compareTo(signInFTService_args other) { + public int compareTo(listFTClients_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -38930,7 +39468,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new SignInFTServiceReq(); + this.req = new ListFTClientsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -38972,7 +39510,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("signInFTService_args"); + StringBuilder sb = new StringBuilder("listFTClients_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -38999,11 +39537,11 @@ public void validate() throws TException { } - public static class signInFTService_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("signInFTService_result"); + public static class listFTClients_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listFTClients_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListFTClientsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -39013,19 +39551,19 @@ public static class signInFTService_result implements TBase, java.io.Serializabl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListFTClientsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(signInFTService_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listFTClients_result.class, metaDataMap); } - public signInFTService_result() { + public listFTClients_result() { } - public signInFTService_result( - ExecResp success) { + public listFTClients_result( + ListFTClientsResp success) { this(); this.success = success; } @@ -39033,21 +39571,21 @@ public signInFTService_result( /** * Performs a deep copy on other. */ - public signInFTService_result(signInFTService_result other) { + public listFTClients_result(listFTClients_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public signInFTService_result deepCopy() { - return new signInFTService_result(this); + public listFTClients_result deepCopy() { + return new listFTClients_result(this); } - public ExecResp getSuccess() { + public ListFTClientsResp getSuccess() { return this.success; } - public signInFTService_result setSuccess(ExecResp success) { + public listFTClients_result setSuccess(ListFTClientsResp success) { this.success = success; return this; } @@ -39073,7 +39611,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListFTClientsResp)__value); } break; @@ -39098,9 +39636,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof signInFTService_result)) + if (!(_that instanceof listFTClients_result)) return false; - signInFTService_result that = (signInFTService_result)_that; + listFTClients_result that = (listFTClients_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -39113,7 +39651,7 @@ public int hashCode() { } @Override - public int compareTo(signInFTService_result other) { + public int compareTo(listFTClients_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -39148,7 +39686,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListFTClientsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -39189,7 +39727,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("signInFTService_result"); + StringBuilder sb = new StringBuilder("listFTClients_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -39216,11 +39754,11 @@ public void validate() throws TException { } - public static class signOutFTService_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("signOutFTService_args"); + public static class createFTIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createFTIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public SignOutFTServiceReq req; + public CreateFTIndexReq req; public static final int REQ = 1; // isset id assignments @@ -39230,19 +39768,19 @@ public static class signOutFTService_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, SignOutFTServiceReq.class))); + new StructMetaData(TType.STRUCT, CreateFTIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(signOutFTService_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createFTIndex_args.class, metaDataMap); } - public signOutFTService_args() { + public createFTIndex_args() { } - public signOutFTService_args( - SignOutFTServiceReq req) { + public createFTIndex_args( + CreateFTIndexReq req) { this(); this.req = req; } @@ -39250,21 +39788,21 @@ public signOutFTService_args( /** * Performs a deep copy on other. */ - public signOutFTService_args(signOutFTService_args other) { + public createFTIndex_args(createFTIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public signOutFTService_args deepCopy() { - return new signOutFTService_args(this); + public createFTIndex_args deepCopy() { + return new createFTIndex_args(this); } - public SignOutFTServiceReq getReq() { + public CreateFTIndexReq getReq() { return this.req; } - public signOutFTService_args setReq(SignOutFTServiceReq req) { + public createFTIndex_args setReq(CreateFTIndexReq req) { this.req = req; return this; } @@ -39290,7 +39828,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((SignOutFTServiceReq)__value); + setReq((CreateFTIndexReq)__value); } break; @@ -39315,9 +39853,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof signOutFTService_args)) + if (!(_that instanceof createFTIndex_args)) return false; - signOutFTService_args that = (signOutFTService_args)_that; + createFTIndex_args that = (createFTIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -39330,7 +39868,7 @@ public int hashCode() { } @Override - public int compareTo(signOutFTService_args other) { + public int compareTo(createFTIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -39365,7 +39903,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new SignOutFTServiceReq(); + this.req = new CreateFTIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -39407,7 +39945,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("signOutFTService_args"); + StringBuilder sb = new StringBuilder("createFTIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -39434,8 +39972,8 @@ public void validate() throws TException { } - public static class signOutFTService_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("signOutFTService_result"); + public static class createFTIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createFTIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -39453,13 +39991,13 @@ public static class signOutFTService_result implements TBase, java.io.Serializab } static { - FieldMetaData.addStructMetaDataMap(signOutFTService_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createFTIndex_result.class, metaDataMap); } - public signOutFTService_result() { + public createFTIndex_result() { } - public signOutFTService_result( + public createFTIndex_result( ExecResp success) { this(); this.success = success; @@ -39468,21 +40006,21 @@ public signOutFTService_result( /** * Performs a deep copy on other. */ - public signOutFTService_result(signOutFTService_result other) { + public createFTIndex_result(createFTIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public signOutFTService_result deepCopy() { - return new signOutFTService_result(this); + public createFTIndex_result deepCopy() { + return new createFTIndex_result(this); } public ExecResp getSuccess() { return this.success; } - public signOutFTService_result setSuccess(ExecResp success) { + public createFTIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -39533,9 +40071,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof signOutFTService_result)) + if (!(_that instanceof createFTIndex_result)) return false; - signOutFTService_result that = (signOutFTService_result)_that; + createFTIndex_result that = (createFTIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -39548,7 +40086,7 @@ public int hashCode() { } @Override - public int compareTo(signOutFTService_result other) { + public int compareTo(createFTIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -39624,7 +40162,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("signOutFTService_result"); + StringBuilder sb = new StringBuilder("createFTIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -39651,11 +40189,11 @@ public void validate() throws TException { } - public static class listFTClients_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listFTClients_args"); + public static class dropFTIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropFTIndex_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListFTClientsReq req; + public DropFTIndexReq req; public static final int REQ = 1; // isset id assignments @@ -39665,19 +40203,19 @@ public static class listFTClients_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListFTClientsReq.class))); + new StructMetaData(TType.STRUCT, DropFTIndexReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listFTClients_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropFTIndex_args.class, metaDataMap); } - public listFTClients_args() { + public dropFTIndex_args() { } - public listFTClients_args( - ListFTClientsReq req) { + public dropFTIndex_args( + DropFTIndexReq req) { this(); this.req = req; } @@ -39685,21 +40223,21 @@ public listFTClients_args( /** * Performs a deep copy on other. */ - public listFTClients_args(listFTClients_args other) { + public dropFTIndex_args(dropFTIndex_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listFTClients_args deepCopy() { - return new listFTClients_args(this); + public dropFTIndex_args deepCopy() { + return new dropFTIndex_args(this); } - public ListFTClientsReq getReq() { + public DropFTIndexReq getReq() { return this.req; } - public listFTClients_args setReq(ListFTClientsReq req) { + public dropFTIndex_args setReq(DropFTIndexReq req) { this.req = req; return this; } @@ -39725,7 +40263,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListFTClientsReq)__value); + setReq((DropFTIndexReq)__value); } break; @@ -39750,9 +40288,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listFTClients_args)) + if (!(_that instanceof dropFTIndex_args)) return false; - listFTClients_args that = (listFTClients_args)_that; + dropFTIndex_args that = (dropFTIndex_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -39765,7 +40303,7 @@ public int hashCode() { } @Override - public int compareTo(listFTClients_args other) { + public int compareTo(dropFTIndex_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -39800,7 +40338,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListFTClientsReq(); + this.req = new DropFTIndexReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -39842,7 +40380,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listFTClients_args"); + StringBuilder sb = new StringBuilder("dropFTIndex_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -39869,11 +40407,11 @@ public void validate() throws TException { } - public static class listFTClients_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listFTClients_result"); + public static class dropFTIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("dropFTIndex_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListFTClientsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -39883,19 +40421,19 @@ public static class listFTClients_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListFTClientsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listFTClients_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(dropFTIndex_result.class, metaDataMap); } - public listFTClients_result() { + public dropFTIndex_result() { } - public listFTClients_result( - ListFTClientsResp success) { + public dropFTIndex_result( + ExecResp success) { this(); this.success = success; } @@ -39903,21 +40441,21 @@ public listFTClients_result( /** * Performs a deep copy on other. */ - public listFTClients_result(listFTClients_result other) { + public dropFTIndex_result(dropFTIndex_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listFTClients_result deepCopy() { - return new listFTClients_result(this); + public dropFTIndex_result deepCopy() { + return new dropFTIndex_result(this); } - public ListFTClientsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listFTClients_result setSuccess(ListFTClientsResp success) { + public dropFTIndex_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -39943,7 +40481,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListFTClientsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -39968,9 +40506,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listFTClients_result)) + if (!(_that instanceof dropFTIndex_result)) return false; - listFTClients_result that = (listFTClients_result)_that; + dropFTIndex_result that = (dropFTIndex_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -39983,7 +40521,7 @@ public int hashCode() { } @Override - public int compareTo(listFTClients_result other) { + public int compareTo(dropFTIndex_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -40018,7 +40556,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListFTClientsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -40059,7 +40597,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listFTClients_result"); + StringBuilder sb = new StringBuilder("dropFTIndex_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -40086,11 +40624,11 @@ public void validate() throws TException { } - public static class createFTIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createFTIndex_args"); + public static class listFTIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listFTIndexes_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateFTIndexReq req; + public ListFTIndexesReq req; public static final int REQ = 1; // isset id assignments @@ -40100,19 +40638,19 @@ public static class createFTIndex_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateFTIndexReq.class))); + new StructMetaData(TType.STRUCT, ListFTIndexesReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createFTIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listFTIndexes_args.class, metaDataMap); } - public createFTIndex_args() { + public listFTIndexes_args() { } - public createFTIndex_args( - CreateFTIndexReq req) { + public listFTIndexes_args( + ListFTIndexesReq req) { this(); this.req = req; } @@ -40120,21 +40658,21 @@ public createFTIndex_args( /** * Performs a deep copy on other. */ - public createFTIndex_args(createFTIndex_args other) { + public listFTIndexes_args(listFTIndexes_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createFTIndex_args deepCopy() { - return new createFTIndex_args(this); + public listFTIndexes_args deepCopy() { + return new listFTIndexes_args(this); } - public CreateFTIndexReq getReq() { + public ListFTIndexesReq getReq() { return this.req; } - public createFTIndex_args setReq(CreateFTIndexReq req) { + public listFTIndexes_args setReq(ListFTIndexesReq req) { this.req = req; return this; } @@ -40160,7 +40698,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateFTIndexReq)__value); + setReq((ListFTIndexesReq)__value); } break; @@ -40185,9 +40723,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createFTIndex_args)) + if (!(_that instanceof listFTIndexes_args)) return false; - createFTIndex_args that = (createFTIndex_args)_that; + listFTIndexes_args that = (listFTIndexes_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -40200,7 +40738,7 @@ public int hashCode() { } @Override - public int compareTo(createFTIndex_args other) { + public int compareTo(listFTIndexes_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -40235,7 +40773,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateFTIndexReq(); + this.req = new ListFTIndexesReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -40277,7 +40815,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createFTIndex_args"); + StringBuilder sb = new StringBuilder("listFTIndexes_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -40304,11 +40842,11 @@ public void validate() throws TException { } - public static class createFTIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createFTIndex_result"); + public static class listFTIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listFTIndexes_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public ListFTIndexesResp success; public static final int SUCCESS = 0; // isset id assignments @@ -40318,19 +40856,19 @@ public static class createFTIndex_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, ListFTIndexesResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createFTIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listFTIndexes_result.class, metaDataMap); } - public createFTIndex_result() { + public listFTIndexes_result() { } - public createFTIndex_result( - ExecResp success) { + public listFTIndexes_result( + ListFTIndexesResp success) { this(); this.success = success; } @@ -40338,21 +40876,21 @@ public createFTIndex_result( /** * Performs a deep copy on other. */ - public createFTIndex_result(createFTIndex_result other) { + public listFTIndexes_result(listFTIndexes_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createFTIndex_result deepCopy() { - return new createFTIndex_result(this); + public listFTIndexes_result deepCopy() { + return new listFTIndexes_result(this); } - public ExecResp getSuccess() { + public ListFTIndexesResp getSuccess() { return this.success; } - public createFTIndex_result setSuccess(ExecResp success) { + public listFTIndexes_result setSuccess(ListFTIndexesResp success) { this.success = success; return this; } @@ -40378,7 +40916,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((ListFTIndexesResp)__value); } break; @@ -40403,9 +40941,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createFTIndex_result)) + if (!(_that instanceof listFTIndexes_result)) return false; - createFTIndex_result that = (createFTIndex_result)_that; + listFTIndexes_result that = (listFTIndexes_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -40418,7 +40956,7 @@ public int hashCode() { } @Override - public int compareTo(createFTIndex_result other) { + public int compareTo(listFTIndexes_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -40453,7 +40991,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new ListFTIndexesResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -40494,7 +41032,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createFTIndex_result"); + StringBuilder sb = new StringBuilder("listFTIndexes_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -40521,11 +41059,11 @@ public void validate() throws TException { } - public static class dropFTIndex_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropFTIndex_args"); + public static class createSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createSession_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public DropFTIndexReq req; + public CreateSessionReq req; public static final int REQ = 1; // isset id assignments @@ -40535,19 +41073,19 @@ public static class dropFTIndex_args implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DropFTIndexReq.class))); + new StructMetaData(TType.STRUCT, CreateSessionReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropFTIndex_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSession_args.class, metaDataMap); } - public dropFTIndex_args() { + public createSession_args() { } - public dropFTIndex_args( - DropFTIndexReq req) { + public createSession_args( + CreateSessionReq req) { this(); this.req = req; } @@ -40555,21 +41093,21 @@ public dropFTIndex_args( /** * Performs a deep copy on other. */ - public dropFTIndex_args(dropFTIndex_args other) { + public createSession_args(createSession_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public dropFTIndex_args deepCopy() { - return new dropFTIndex_args(this); + public createSession_args deepCopy() { + return new createSession_args(this); } - public DropFTIndexReq getReq() { + public CreateSessionReq getReq() { return this.req; } - public dropFTIndex_args setReq(DropFTIndexReq req) { + public createSession_args setReq(CreateSessionReq req) { this.req = req; return this; } @@ -40595,7 +41133,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((DropFTIndexReq)__value); + setReq((CreateSessionReq)__value); } break; @@ -40620,9 +41158,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropFTIndex_args)) + if (!(_that instanceof createSession_args)) return false; - dropFTIndex_args that = (dropFTIndex_args)_that; + createSession_args that = (createSession_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -40635,7 +41173,7 @@ public int hashCode() { } @Override - public int compareTo(dropFTIndex_args other) { + public int compareTo(createSession_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -40670,7 +41208,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new DropFTIndexReq(); + this.req = new CreateSessionReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -40712,7 +41250,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropFTIndex_args"); + StringBuilder sb = new StringBuilder("createSession_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -40739,11 +41277,11 @@ public void validate() throws TException { } - public static class dropFTIndex_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("dropFTIndex_result"); + public static class createSession_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("createSession_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public CreateSessionResp success; public static final int SUCCESS = 0; // isset id assignments @@ -40753,19 +41291,19 @@ public static class dropFTIndex_result implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, CreateSessionResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(dropFTIndex_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createSession_result.class, metaDataMap); } - public dropFTIndex_result() { + public createSession_result() { } - public dropFTIndex_result( - ExecResp success) { + public createSession_result( + CreateSessionResp success) { this(); this.success = success; } @@ -40773,21 +41311,21 @@ public dropFTIndex_result( /** * Performs a deep copy on other. */ - public dropFTIndex_result(dropFTIndex_result other) { + public createSession_result(createSession_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public dropFTIndex_result deepCopy() { - return new dropFTIndex_result(this); + public createSession_result deepCopy() { + return new createSession_result(this); } - public ExecResp getSuccess() { + public CreateSessionResp getSuccess() { return this.success; } - public dropFTIndex_result setSuccess(ExecResp success) { + public createSession_result setSuccess(CreateSessionResp success) { this.success = success; return this; } @@ -40813,7 +41351,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((CreateSessionResp)__value); } break; @@ -40838,9 +41376,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof dropFTIndex_result)) + if (!(_that instanceof createSession_result)) return false; - dropFTIndex_result that = (dropFTIndex_result)_that; + createSession_result that = (createSession_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -40852,29 +41390,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } - @Override - public int compareTo(dropFTIndex_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -40888,7 +41403,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new CreateSessionResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -40929,7 +41444,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("dropFTIndex_result"); + StringBuilder sb = new StringBuilder("createSession_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -40956,11 +41471,11 @@ public void validate() throws TException { } - public static class listFTIndexes_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listFTIndexes_args"); + public static class updateSessions_args implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("updateSessions_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListFTIndexesReq req; + public UpdateSessionsReq req; public static final int REQ = 1; // isset id assignments @@ -40970,19 +41485,19 @@ public static class listFTIndexes_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListFTIndexesReq.class))); + new StructMetaData(TType.STRUCT, UpdateSessionsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listFTIndexes_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(updateSessions_args.class, metaDataMap); } - public listFTIndexes_args() { + public updateSessions_args() { } - public listFTIndexes_args( - ListFTIndexesReq req) { + public updateSessions_args( + UpdateSessionsReq req) { this(); this.req = req; } @@ -40990,21 +41505,21 @@ public listFTIndexes_args( /** * Performs a deep copy on other. */ - public listFTIndexes_args(listFTIndexes_args other) { + public updateSessions_args(updateSessions_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listFTIndexes_args deepCopy() { - return new listFTIndexes_args(this); + public updateSessions_args deepCopy() { + return new updateSessions_args(this); } - public ListFTIndexesReq getReq() { + public UpdateSessionsReq getReq() { return this.req; } - public listFTIndexes_args setReq(ListFTIndexesReq req) { + public updateSessions_args setReq(UpdateSessionsReq req) { this.req = req; return this; } @@ -41030,7 +41545,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListFTIndexesReq)__value); + setReq((UpdateSessionsReq)__value); } break; @@ -41055,9 +41570,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listFTIndexes_args)) + if (!(_that instanceof updateSessions_args)) return false; - listFTIndexes_args that = (listFTIndexes_args)_that; + updateSessions_args that = (updateSessions_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -41069,29 +41584,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } - @Override - public int compareTo(listFTIndexes_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -41105,7 +41597,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListFTIndexesReq(); + this.req = new UpdateSessionsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -41147,7 +41639,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listFTIndexes_args"); + StringBuilder sb = new StringBuilder("updateSessions_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -41174,11 +41666,11 @@ public void validate() throws TException { } - public static class listFTIndexes_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listFTIndexes_result"); + public static class updateSessions_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("updateSessions_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListFTIndexesResp success; + public UpdateSessionsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -41188,19 +41680,19 @@ public static class listFTIndexes_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListFTIndexesResp.class))); + new StructMetaData(TType.STRUCT, UpdateSessionsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listFTIndexes_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(updateSessions_result.class, metaDataMap); } - public listFTIndexes_result() { + public updateSessions_result() { } - public listFTIndexes_result( - ListFTIndexesResp success) { + public updateSessions_result( + UpdateSessionsResp success) { this(); this.success = success; } @@ -41208,21 +41700,21 @@ public listFTIndexes_result( /** * Performs a deep copy on other. */ - public listFTIndexes_result(listFTIndexes_result other) { + public updateSessions_result(updateSessions_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listFTIndexes_result deepCopy() { - return new listFTIndexes_result(this); + public updateSessions_result deepCopy() { + return new updateSessions_result(this); } - public ListFTIndexesResp getSuccess() { + public UpdateSessionsResp getSuccess() { return this.success; } - public listFTIndexes_result setSuccess(ListFTIndexesResp success) { + public updateSessions_result setSuccess(UpdateSessionsResp success) { this.success = success; return this; } @@ -41248,7 +41740,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListFTIndexesResp)__value); + setSuccess((UpdateSessionsResp)__value); } break; @@ -41273,9 +41765,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listFTIndexes_result)) + if (!(_that instanceof updateSessions_result)) return false; - listFTIndexes_result that = (listFTIndexes_result)_that; + updateSessions_result that = (updateSessions_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -41288,7 +41780,7 @@ public int hashCode() { } @Override - public int compareTo(listFTIndexes_result other) { + public int compareTo(updateSessions_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -41323,7 +41815,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListFTIndexesResp(); + this.success = new UpdateSessionsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -41364,7 +41856,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listFTIndexes_result"); + StringBuilder sb = new StringBuilder("updateSessions_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -41391,11 +41883,11 @@ public void validate() throws TException { } - public static class createSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("createSession_args"); + public static class listSessions_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("listSessions_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public CreateSessionReq req; + public ListSessionsReq req; public static final int REQ = 1; // isset id assignments @@ -41405,19 +41897,19 @@ public static class createSession_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateSessionReq.class))); + new StructMetaData(TType.STRUCT, ListSessionsReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSession_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSessions_args.class, metaDataMap); } - public createSession_args() { + public listSessions_args() { } - public createSession_args( - CreateSessionReq req) { + public listSessions_args( + ListSessionsReq req) { this(); this.req = req; } @@ -41425,21 +41917,21 @@ public createSession_args( /** * Performs a deep copy on other. */ - public createSession_args(createSession_args other) { + public listSessions_args(listSessions_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public createSession_args deepCopy() { - return new createSession_args(this); + public listSessions_args deepCopy() { + return new listSessions_args(this); } - public CreateSessionReq getReq() { + public ListSessionsReq getReq() { return this.req; } - public createSession_args setReq(CreateSessionReq req) { + public listSessions_args setReq(ListSessionsReq req) { this.req = req; return this; } @@ -41465,7 +41957,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((CreateSessionReq)__value); + setReq((ListSessionsReq)__value); } break; @@ -41490,9 +41982,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSession_args)) + if (!(_that instanceof listSessions_args)) return false; - createSession_args that = (createSession_args)_that; + listSessions_args that = (listSessions_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -41505,7 +41997,7 @@ public int hashCode() { } @Override - public int compareTo(createSession_args other) { + public int compareTo(listSessions_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -41540,7 +42032,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new CreateSessionReq(); + this.req = new ListSessionsReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -41582,7 +42074,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSession_args"); + StringBuilder sb = new StringBuilder("listSessions_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -41609,11 +42101,11 @@ public void validate() throws TException { } - public static class createSession_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("createSession_result"); + public static class listSessions_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("listSessions_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public CreateSessionResp success; + public ListSessionsResp success; public static final int SUCCESS = 0; // isset id assignments @@ -41623,19 +42115,19 @@ public static class createSession_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, CreateSessionResp.class))); + new StructMetaData(TType.STRUCT, ListSessionsResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(createSession_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(listSessions_result.class, metaDataMap); } - public createSession_result() { + public listSessions_result() { } - public createSession_result( - CreateSessionResp success) { + public listSessions_result( + ListSessionsResp success) { this(); this.success = success; } @@ -41643,21 +42135,21 @@ public createSession_result( /** * Performs a deep copy on other. */ - public createSession_result(createSession_result other) { + public listSessions_result(listSessions_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public createSession_result deepCopy() { - return new createSession_result(this); + public listSessions_result deepCopy() { + return new listSessions_result(this); } - public CreateSessionResp getSuccess() { + public ListSessionsResp getSuccess() { return this.success; } - public createSession_result setSuccess(CreateSessionResp success) { + public listSessions_result setSuccess(ListSessionsResp success) { this.success = success; return this; } @@ -41683,7 +42175,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((CreateSessionResp)__value); + setSuccess((ListSessionsResp)__value); } break; @@ -41708,9 +42200,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof createSession_result)) + if (!(_that instanceof listSessions_result)) return false; - createSession_result that = (createSession_result)_that; + listSessions_result that = (listSessions_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -41735,7 +42227,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new CreateSessionResp(); + this.success = new ListSessionsResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -41776,7 +42268,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("createSession_result"); + StringBuilder sb = new StringBuilder("listSessions_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -41803,11 +42295,11 @@ public void validate() throws TException { } - public static class updateSessions_args implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("updateSessions_args"); + public static class getSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("getSession_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public UpdateSessionsReq req; + public GetSessionReq req; public static final int REQ = 1; // isset id assignments @@ -41817,19 +42309,19 @@ public static class updateSessions_args implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, UpdateSessionsReq.class))); + new StructMetaData(TType.STRUCT, GetSessionReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(updateSessions_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getSession_args.class, metaDataMap); } - public updateSessions_args() { + public getSession_args() { } - public updateSessions_args( - UpdateSessionsReq req) { + public getSession_args( + GetSessionReq req) { this(); this.req = req; } @@ -41837,21 +42329,21 @@ public updateSessions_args( /** * Performs a deep copy on other. */ - public updateSessions_args(updateSessions_args other) { + public getSession_args(getSession_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public updateSessions_args deepCopy() { - return new updateSessions_args(this); + public getSession_args deepCopy() { + return new getSession_args(this); } - public UpdateSessionsReq getReq() { + public GetSessionReq getReq() { return this.req; } - public updateSessions_args setReq(UpdateSessionsReq req) { + public getSession_args setReq(GetSessionReq req) { this.req = req; return this; } @@ -41877,7 +42369,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((UpdateSessionsReq)__value); + setReq((GetSessionReq)__value); } break; @@ -41902,9 +42394,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof updateSessions_args)) + if (!(_that instanceof getSession_args)) return false; - updateSessions_args that = (updateSessions_args)_that; + getSession_args that = (getSession_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -41916,6 +42408,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {req}); } + @Override + public int compareTo(getSession_args other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(req, other.req); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -41929,7 +42444,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new UpdateSessionsReq(); + this.req = new GetSessionReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -41971,7 +42486,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("updateSessions_args"); + StringBuilder sb = new StringBuilder("getSession_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -41998,11 +42513,11 @@ public void validate() throws TException { } - public static class updateSessions_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("updateSessions_result"); + public static class getSession_result implements TBase, java.io.Serializable, Cloneable { + private static final TStruct STRUCT_DESC = new TStruct("getSession_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public UpdateSessionsResp success; + public GetSessionResp success; public static final int SUCCESS = 0; // isset id assignments @@ -42012,19 +42527,19 @@ public static class updateSessions_result implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, UpdateSessionsResp.class))); + new StructMetaData(TType.STRUCT, GetSessionResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(updateSessions_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(getSession_result.class, metaDataMap); } - public updateSessions_result() { + public getSession_result() { } - public updateSessions_result( - UpdateSessionsResp success) { + public getSession_result( + GetSessionResp success) { this(); this.success = success; } @@ -42032,21 +42547,21 @@ public updateSessions_result( /** * Performs a deep copy on other. */ - public updateSessions_result(updateSessions_result other) { + public getSession_result(getSession_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public updateSessions_result deepCopy() { - return new updateSessions_result(this); + public getSession_result deepCopy() { + return new getSession_result(this); } - public UpdateSessionsResp getSuccess() { + public GetSessionResp getSuccess() { return this.success; } - public updateSessions_result setSuccess(UpdateSessionsResp success) { + public getSession_result setSuccess(GetSessionResp success) { this.success = success; return this; } @@ -42072,7 +42587,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((UpdateSessionsResp)__value); + setSuccess((GetSessionResp)__value); } break; @@ -42097,9 +42612,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof updateSessions_result)) + if (!(_that instanceof getSession_result)) return false; - updateSessions_result that = (updateSessions_result)_that; + getSession_result that = (getSession_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -42111,29 +42626,6 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } - @Override - public int compareTo(updateSessions_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -42147,7 +42639,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new UpdateSessionsResp(); + this.success = new GetSessionResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -42188,7 +42680,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("updateSessions_result"); + StringBuilder sb = new StringBuilder("getSession_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -42215,11 +42707,11 @@ public void validate() throws TException { } - public static class listSessions_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listSessions_args"); + public static class removeSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeSession_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ListSessionsReq req; + public RemoveSessionReq req; public static final int REQ = 1; // isset id assignments @@ -42229,19 +42721,19 @@ public static class listSessions_args implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSessionsReq.class))); + new StructMetaData(TType.STRUCT, RemoveSessionReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSessions_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeSession_args.class, metaDataMap); } - public listSessions_args() { + public removeSession_args() { } - public listSessions_args( - ListSessionsReq req) { + public removeSession_args( + RemoveSessionReq req) { this(); this.req = req; } @@ -42249,21 +42741,21 @@ public listSessions_args( /** * Performs a deep copy on other. */ - public listSessions_args(listSessions_args other) { + public removeSession_args(removeSession_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public listSessions_args deepCopy() { - return new listSessions_args(this); + public removeSession_args deepCopy() { + return new removeSession_args(this); } - public ListSessionsReq getReq() { + public RemoveSessionReq getReq() { return this.req; } - public listSessions_args setReq(ListSessionsReq req) { + public removeSession_args setReq(RemoveSessionReq req) { this.req = req; return this; } @@ -42289,7 +42781,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ListSessionsReq)__value); + setReq((RemoveSessionReq)__value); } break; @@ -42314,9 +42806,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSessions_args)) + if (!(_that instanceof removeSession_args)) return false; - listSessions_args that = (listSessions_args)_that; + removeSession_args that = (removeSession_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -42329,7 +42821,7 @@ public int hashCode() { } @Override - public int compareTo(listSessions_args other) { + public int compareTo(removeSession_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -42364,7 +42856,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ListSessionsReq(); + this.req = new RemoveSessionReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -42406,7 +42898,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSessions_args"); + StringBuilder sb = new StringBuilder("removeSession_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -42433,11 +42925,11 @@ public void validate() throws TException { } - public static class listSessions_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("listSessions_result"); + public static class removeSession_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("removeSession_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ListSessionsResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -42447,19 +42939,19 @@ public static class listSessions_result implements TBase, java.io.Serializable, static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListSessionsResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(listSessions_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(removeSession_result.class, metaDataMap); } - public listSessions_result() { + public removeSession_result() { } - public listSessions_result( - ListSessionsResp success) { + public removeSession_result( + ExecResp success) { this(); this.success = success; } @@ -42467,21 +42959,21 @@ public listSessions_result( /** * Performs a deep copy on other. */ - public listSessions_result(listSessions_result other) { + public removeSession_result(removeSession_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public listSessions_result deepCopy() { - return new listSessions_result(this); + public removeSession_result deepCopy() { + return new removeSession_result(this); } - public ListSessionsResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public listSessions_result setSuccess(ListSessionsResp success) { + public removeSession_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -42507,7 +42999,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ListSessionsResp)__value); + setSuccess((ExecResp)__value); } break; @@ -42532,9 +43024,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof listSessions_result)) + if (!(_that instanceof removeSession_result)) return false; - listSessions_result that = (listSessions_result)_that; + removeSession_result that = (removeSession_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -42546,6 +43038,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } + @Override + public int compareTo(removeSession_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -42559,7 +43074,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ListSessionsResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -42600,7 +43115,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listSessions_result"); + StringBuilder sb = new StringBuilder("removeSession_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -42627,11 +43142,11 @@ public void validate() throws TException { } - public static class getSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("getSession_args"); + public static class killQuery_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("killQuery_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public GetSessionReq req; + public KillQueryReq req; public static final int REQ = 1; // isset id assignments @@ -42641,19 +43156,19 @@ public static class getSession_args implements TBase, java.io.Serializable, Clon static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetSessionReq.class))); + new StructMetaData(TType.STRUCT, KillQueryReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getSession_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(killQuery_args.class, metaDataMap); } - public getSession_args() { + public killQuery_args() { } - public getSession_args( - GetSessionReq req) { + public killQuery_args( + KillQueryReq req) { this(); this.req = req; } @@ -42661,21 +43176,21 @@ public getSession_args( /** * Performs a deep copy on other. */ - public getSession_args(getSession_args other) { + public killQuery_args(killQuery_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public getSession_args deepCopy() { - return new getSession_args(this); + public killQuery_args deepCopy() { + return new killQuery_args(this); } - public GetSessionReq getReq() { + public KillQueryReq getReq() { return this.req; } - public getSession_args setReq(GetSessionReq req) { + public killQuery_args setReq(KillQueryReq req) { this.req = req; return this; } @@ -42701,7 +43216,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((GetSessionReq)__value); + setReq((KillQueryReq)__value); } break; @@ -42726,9 +43241,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getSession_args)) + if (!(_that instanceof killQuery_args)) return false; - getSession_args that = (getSession_args)_that; + killQuery_args that = (killQuery_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -42741,7 +43256,7 @@ public int hashCode() { } @Override - public int compareTo(getSession_args other) { + public int compareTo(killQuery_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -42776,7 +43291,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new GetSessionReq(); + this.req = new KillQueryReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -42818,7 +43333,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getSession_args"); + StringBuilder sb = new StringBuilder("killQuery_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -42845,11 +43360,11 @@ public void validate() throws TException { } - public static class getSession_result implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("getSession_result"); + public static class killQuery_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("killQuery_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public GetSessionResp success; + public ExecResp success; public static final int SUCCESS = 0; // isset id assignments @@ -42859,19 +43374,19 @@ public static class getSession_result implements TBase, java.io.Serializable, Cl static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, GetSessionResp.class))); + new StructMetaData(TType.STRUCT, ExecResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(getSession_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(killQuery_result.class, metaDataMap); } - public getSession_result() { + public killQuery_result() { } - public getSession_result( - GetSessionResp success) { + public killQuery_result( + ExecResp success) { this(); this.success = success; } @@ -42879,21 +43394,21 @@ public getSession_result( /** * Performs a deep copy on other. */ - public getSession_result(getSession_result other) { + public killQuery_result(killQuery_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public getSession_result deepCopy() { - return new getSession_result(this); + public killQuery_result deepCopy() { + return new killQuery_result(this); } - public GetSessionResp getSuccess() { + public ExecResp getSuccess() { return this.success; } - public getSession_result setSuccess(GetSessionResp success) { + public killQuery_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -42919,7 +43434,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((GetSessionResp)__value); + setSuccess((ExecResp)__value); } break; @@ -42944,9 +43459,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof getSession_result)) + if (!(_that instanceof killQuery_result)) return false; - getSession_result that = (getSession_result)_that; + killQuery_result that = (killQuery_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -42958,6 +43473,29 @@ public int hashCode() { return Arrays.deepHashCode(new Object[] {success}); } + @Override + public int compareTo(killQuery_result other) { + if (other == null) { + // See java.lang.Comparable docs + throw new NullPointerException(); + } + + if (other == this) { + return 0; + } + int lastComparison = 0; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(success, other.success); + if (lastComparison != 0) { + return lastComparison; + } + return 0; + } + public void read(TProtocol iprot) throws TException { TField __field; iprot.readStructBegin(metaDataMap); @@ -42971,7 +43509,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new GetSessionResp(); + this.success = new ExecResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -43012,7 +43550,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("getSession_result"); + StringBuilder sb = new StringBuilder("killQuery_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -43039,11 +43577,11 @@ public void validate() throws TException { } - public static class removeSession_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeSession_args"); + public static class reportTaskFinish_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("reportTaskFinish_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public RemoveSessionReq req; + public ReportTaskReq req; public static final int REQ = 1; // isset id assignments @@ -43053,19 +43591,19 @@ public static class removeSession_args implements TBase, java.io.Serializable, C static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, RemoveSessionReq.class))); + new StructMetaData(TType.STRUCT, ReportTaskReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(removeSession_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(reportTaskFinish_args.class, metaDataMap); } - public removeSession_args() { + public reportTaskFinish_args() { } - public removeSession_args( - RemoveSessionReq req) { + public reportTaskFinish_args( + ReportTaskReq req) { this(); this.req = req; } @@ -43073,21 +43611,21 @@ public removeSession_args( /** * Performs a deep copy on other. */ - public removeSession_args(removeSession_args other) { + public reportTaskFinish_args(reportTaskFinish_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public removeSession_args deepCopy() { - return new removeSession_args(this); + public reportTaskFinish_args deepCopy() { + return new reportTaskFinish_args(this); } - public RemoveSessionReq getReq() { + public ReportTaskReq getReq() { return this.req; } - public removeSession_args setReq(RemoveSessionReq req) { + public reportTaskFinish_args setReq(ReportTaskReq req) { this.req = req; return this; } @@ -43113,7 +43651,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((RemoveSessionReq)__value); + setReq((ReportTaskReq)__value); } break; @@ -43138,9 +43676,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeSession_args)) + if (!(_that instanceof reportTaskFinish_args)) return false; - removeSession_args that = (removeSession_args)_that; + reportTaskFinish_args that = (reportTaskFinish_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -43153,7 +43691,7 @@ public int hashCode() { } @Override - public int compareTo(removeSession_args other) { + public int compareTo(reportTaskFinish_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -43188,7 +43726,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new RemoveSessionReq(); + this.req = new ReportTaskReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -43230,7 +43768,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeSession_args"); + StringBuilder sb = new StringBuilder("reportTaskFinish_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -43257,8 +43795,8 @@ public void validate() throws TException { } - public static class removeSession_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("removeSession_result"); + public static class reportTaskFinish_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("reportTaskFinish_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -43276,13 +43814,13 @@ public static class removeSession_result implements TBase, java.io.Serializable, } static { - FieldMetaData.addStructMetaDataMap(removeSession_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(reportTaskFinish_result.class, metaDataMap); } - public removeSession_result() { + public reportTaskFinish_result() { } - public removeSession_result( + public reportTaskFinish_result( ExecResp success) { this(); this.success = success; @@ -43291,21 +43829,21 @@ public removeSession_result( /** * Performs a deep copy on other. */ - public removeSession_result(removeSession_result other) { + public reportTaskFinish_result(reportTaskFinish_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public removeSession_result deepCopy() { - return new removeSession_result(this); + public reportTaskFinish_result deepCopy() { + return new reportTaskFinish_result(this); } public ExecResp getSuccess() { return this.success; } - public removeSession_result setSuccess(ExecResp success) { + public reportTaskFinish_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -43356,9 +43894,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof removeSession_result)) + if (!(_that instanceof reportTaskFinish_result)) return false; - removeSession_result that = (removeSession_result)_that; + reportTaskFinish_result that = (reportTaskFinish_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -43371,7 +43909,7 @@ public int hashCode() { } @Override - public int compareTo(removeSession_result other) { + public int compareTo(reportTaskFinish_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -43447,7 +43985,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("removeSession_result"); + StringBuilder sb = new StringBuilder("reportTaskFinish_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -43474,11 +44012,11 @@ public void validate() throws TException { } - public static class killQuery_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("killQuery_args"); + public static class createBackup_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createBackup_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public KillQueryReq req; + public CreateBackupReq req; public static final int REQ = 1; // isset id assignments @@ -43488,19 +44026,19 @@ public static class killQuery_args implements TBase, java.io.Serializable, Clone static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, KillQueryReq.class))); + new StructMetaData(TType.STRUCT, CreateBackupReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(killQuery_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createBackup_args.class, metaDataMap); } - public killQuery_args() { + public createBackup_args() { } - public killQuery_args( - KillQueryReq req) { + public createBackup_args( + CreateBackupReq req) { this(); this.req = req; } @@ -43508,21 +44046,21 @@ public killQuery_args( /** * Performs a deep copy on other. */ - public killQuery_args(killQuery_args other) { + public createBackup_args(createBackup_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public killQuery_args deepCopy() { - return new killQuery_args(this); + public createBackup_args deepCopy() { + return new createBackup_args(this); } - public KillQueryReq getReq() { + public CreateBackupReq getReq() { return this.req; } - public killQuery_args setReq(KillQueryReq req) { + public createBackup_args setReq(CreateBackupReq req) { this.req = req; return this; } @@ -43548,7 +44086,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((KillQueryReq)__value); + setReq((CreateBackupReq)__value); } break; @@ -43573,9 +44111,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof killQuery_args)) + if (!(_that instanceof createBackup_args)) return false; - killQuery_args that = (killQuery_args)_that; + createBackup_args that = (createBackup_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -43588,7 +44126,7 @@ public int hashCode() { } @Override - public int compareTo(killQuery_args other) { + public int compareTo(createBackup_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -43623,7 +44161,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new KillQueryReq(); + this.req = new CreateBackupReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -43665,7 +44203,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("killQuery_args"); + StringBuilder sb = new StringBuilder("createBackup_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -43692,11 +44230,11 @@ public void validate() throws TException { } - public static class killQuery_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("killQuery_result"); + public static class createBackup_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("createBackup_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - public ExecResp success; + public CreateBackupResp success; public static final int SUCCESS = 0; // isset id assignments @@ -43706,19 +44244,19 @@ public static class killQuery_result implements TBase, java.io.Serializable, Clo static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResp.class))); + new StructMetaData(TType.STRUCT, CreateBackupResp.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(killQuery_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(createBackup_result.class, metaDataMap); } - public killQuery_result() { + public createBackup_result() { } - public killQuery_result( - ExecResp success) { + public createBackup_result( + CreateBackupResp success) { this(); this.success = success; } @@ -43726,21 +44264,21 @@ public killQuery_result( /** * Performs a deep copy on other. */ - public killQuery_result(killQuery_result other) { + public createBackup_result(createBackup_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public killQuery_result deepCopy() { - return new killQuery_result(this); + public createBackup_result deepCopy() { + return new createBackup_result(this); } - public ExecResp getSuccess() { + public CreateBackupResp getSuccess() { return this.success; } - public killQuery_result setSuccess(ExecResp success) { + public createBackup_result setSuccess(CreateBackupResp success) { this.success = success; return this; } @@ -43766,7 +44304,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetSuccess(); } else { - setSuccess((ExecResp)__value); + setSuccess((CreateBackupResp)__value); } break; @@ -43791,9 +44329,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof killQuery_result)) + if (!(_that instanceof createBackup_result)) return false; - killQuery_result that = (killQuery_result)_that; + createBackup_result that = (createBackup_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -43806,7 +44344,7 @@ public int hashCode() { } @Override - public int compareTo(killQuery_result other) { + public int compareTo(createBackup_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -43841,7 +44379,7 @@ public void read(TProtocol iprot) throws TException { { case SUCCESS: if (__field.type == TType.STRUCT) { - this.success = new ExecResp(); + this.success = new CreateBackupResp(); this.success.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -43882,7 +44420,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("killQuery_result"); + StringBuilder sb = new StringBuilder("createBackup_result"); sb.append(space); sb.append("("); sb.append(newLine); @@ -43909,11 +44447,11 @@ public void validate() throws TException { } - public static class reportTaskFinish_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("reportTaskFinish_args"); + public static class restoreMeta_args implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("restoreMeta_args"); private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - public ReportTaskReq req; + public RestoreMetaReq req; public static final int REQ = 1; // isset id assignments @@ -43923,19 +44461,19 @@ public static class reportTaskFinish_args implements TBase, java.io.Serializable static { Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ReportTaskReq.class))); + new StructMetaData(TType.STRUCT, RestoreMetaReq.class))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(reportTaskFinish_args.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(restoreMeta_args.class, metaDataMap); } - public reportTaskFinish_args() { + public restoreMeta_args() { } - public reportTaskFinish_args( - ReportTaskReq req) { + public restoreMeta_args( + RestoreMetaReq req) { this(); this.req = req; } @@ -43943,21 +44481,21 @@ public reportTaskFinish_args( /** * Performs a deep copy on other. */ - public reportTaskFinish_args(reportTaskFinish_args other) { + public restoreMeta_args(restoreMeta_args other) { if (other.isSetReq()) { this.req = TBaseHelper.deepCopy(other.req); } } - public reportTaskFinish_args deepCopy() { - return new reportTaskFinish_args(this); + public restoreMeta_args deepCopy() { + return new restoreMeta_args(this); } - public ReportTaskReq getReq() { + public RestoreMetaReq getReq() { return this.req; } - public reportTaskFinish_args setReq(ReportTaskReq req) { + public restoreMeta_args setReq(RestoreMetaReq req) { this.req = req; return this; } @@ -43983,7 +44521,7 @@ public void setFieldValue(int fieldID, Object __value) { if (__value == null) { unsetReq(); } else { - setReq((ReportTaskReq)__value); + setReq((RestoreMetaReq)__value); } break; @@ -44008,9 +44546,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof reportTaskFinish_args)) + if (!(_that instanceof restoreMeta_args)) return false; - reportTaskFinish_args that = (reportTaskFinish_args)_that; + restoreMeta_args that = (restoreMeta_args)_that; if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } @@ -44023,7 +44561,7 @@ public int hashCode() { } @Override - public int compareTo(reportTaskFinish_args other) { + public int compareTo(restoreMeta_args other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -44058,7 +44596,7 @@ public void read(TProtocol iprot) throws TException { { case REQ: if (__field.type == TType.STRUCT) { - this.req = new ReportTaskReq(); + this.req = new RestoreMetaReq(); this.req.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); @@ -44100,7 +44638,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("reportTaskFinish_args"); + StringBuilder sb = new StringBuilder("restoreMeta_args"); sb.append(space); sb.append("("); sb.append(newLine); @@ -44127,8 +44665,8 @@ public void validate() throws TException { } - public static class reportTaskFinish_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("reportTaskFinish_result"); + public static class restoreMeta_result implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("restoreMeta_result"); private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); public ExecResp success; @@ -44146,13 +44684,13 @@ public static class reportTaskFinish_result implements TBase, java.io.Serializab } static { - FieldMetaData.addStructMetaDataMap(reportTaskFinish_result.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(restoreMeta_result.class, metaDataMap); } - public reportTaskFinish_result() { + public restoreMeta_result() { } - public reportTaskFinish_result( + public restoreMeta_result( ExecResp success) { this(); this.success = success; @@ -44161,21 +44699,21 @@ public reportTaskFinish_result( /** * Performs a deep copy on other. */ - public reportTaskFinish_result(reportTaskFinish_result other) { + public restoreMeta_result(restoreMeta_result other) { if (other.isSetSuccess()) { this.success = TBaseHelper.deepCopy(other.success); } } - public reportTaskFinish_result deepCopy() { - return new reportTaskFinish_result(this); + public restoreMeta_result deepCopy() { + return new restoreMeta_result(this); } public ExecResp getSuccess() { return this.success; } - public reportTaskFinish_result setSuccess(ExecResp success) { + public restoreMeta_result setSuccess(ExecResp success) { this.success = success; return this; } @@ -44226,9 +44764,9 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof reportTaskFinish_result)) + if (!(_that instanceof restoreMeta_result)) return false; - reportTaskFinish_result that = (reportTaskFinish_result)_that; + restoreMeta_result that = (restoreMeta_result)_that; if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } @@ -44241,7 +44779,7 @@ public int hashCode() { } @Override - public int compareTo(reportTaskFinish_result other) { + public int compareTo(restoreMeta_result other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -44317,7 +44855,7 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("reportTaskFinish_result"); + StringBuilder sb = new StringBuilder("restoreMeta_result"); sb.append(space); sb.append("("); sb.append(newLine); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java b/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java deleted file mode 100644 index fc77cc24b..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/PropertyType.java +++ /dev/null @@ -1,88 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - - -import com.facebook.thrift.IntRangeSet; -import java.util.Map; -import java.util.HashMap; - -@SuppressWarnings({ "unused" }) -public enum PropertyType implements com.facebook.thrift.TEnum { - UNKNOWN(0), - BOOL(1), - INT64(2), - VID(3), - FLOAT(4), - DOUBLE(5), - STRING(6), - FIXED_STRING(7), - INT8(8), - INT16(9), - INT32(10), - TIMESTAMP(21), - DATE(24), - DATETIME(25), - TIME(26), - GEOGRAPHY(31); - - private final int value; - - private PropertyType(int value) { - this.value = value; - } - - /** - * Get the integer value of this enum value, as defined in the Thrift IDL. - */ - public int getValue() { - return value; - } - - /** - * Find a the enum type by its integer value, as defined in the Thrift IDL. - * @return null if the value is not found. - */ - public static PropertyType findByValue(int value) { - switch (value) { - case 0: - return UNKNOWN; - case 1: - return BOOL; - case 2: - return INT64; - case 3: - return VID; - case 4: - return FLOAT; - case 5: - return DOUBLE; - case 6: - return STRING; - case 7: - return FIXED_STRING; - case 8: - return INT8; - case 9: - return INT16; - case 10: - return INT32; - case 21: - return TIMESTAMP; - case 24: - return DATE; - case 25: - return DATETIME; - case 26: - return TIME; - case 31: - return GEOGRAPHY; - default: - return null; - } - } -} diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java index dabc1b017..374fa601d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RegConfigReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case ITEMS: if (__field.type == TType.LIST) { { - TList _list200 = iprot.readListBegin(); - this.items = new ArrayList(Math.max(0, _list200.size)); - for (int _i201 = 0; - (_list200.size < 0) ? iprot.peekList() : (_i201 < _list200.size); - ++_i201) + TList _list204 = iprot.readListBegin(); + this.items = new ArrayList(Math.max(0, _list204.size)); + for (int _i205 = 0; + (_list204.size < 0) ? iprot.peekList() : (_i205 < _list204.size); + ++_i205) { - ConfigItem _elem202; - _elem202 = new ConfigItem(); - _elem202.read(iprot); - this.items.add(_elem202); + ConfigItem _elem206; + _elem206 = new ConfigItem(); + _elem206.read(iprot); + this.items.add(_elem206); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(ITEMS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.items.size())); - for (ConfigItem _iter203 : this.items) { - _iter203.write(oprot); + for (ConfigItem _iter207 : this.items) { + _iter207.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java index 647b86cf3..eefe51bd3 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/RestoreMetaReq.java @@ -261,15 +261,15 @@ public void read(TProtocol iprot) throws TException { case FILES: if (__field.type == TType.LIST) { { - TList _list269 = iprot.readListBegin(); - this.files = new ArrayList(Math.max(0, _list269.size)); - for (int _i270 = 0; - (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); - ++_i270) + TList _list273 = iprot.readListBegin(); + this.files = new ArrayList(Math.max(0, _list273.size)); + for (int _i274 = 0; + (_list273.size < 0) ? iprot.peekList() : (_i274 < _list273.size); + ++_i274) { - byte[] _elem271; - _elem271 = iprot.readBinary(); - this.files.add(_elem271); + byte[] _elem275; + _elem275 = iprot.readBinary(); + this.files.add(_elem275); } iprot.readListEnd(); } @@ -280,16 +280,16 @@ public void read(TProtocol iprot) throws TException { case HOSTS: if (__field.type == TType.LIST) { { - TList _list272 = iprot.readListBegin(); - this.hosts = new ArrayList(Math.max(0, _list272.size)); - for (int _i273 = 0; - (_list272.size < 0) ? iprot.peekList() : (_i273 < _list272.size); - ++_i273) + TList _list276 = iprot.readListBegin(); + this.hosts = new ArrayList(Math.max(0, _list276.size)); + for (int _i277 = 0; + (_list276.size < 0) ? iprot.peekList() : (_i277 < _list276.size); + ++_i277) { - HostPair _elem274; - _elem274 = new HostPair(); - _elem274.read(iprot); - this.hosts.add(_elem274); + HostPair _elem278; + _elem278 = new HostPair(); + _elem278.read(iprot); + this.hosts.add(_elem278); } iprot.readListEnd(); } @@ -318,8 +318,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(FILES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.files.size())); - for (byte[] _iter275 : this.files) { - oprot.writeBinary(_iter275); + for (byte[] _iter279 : this.files) { + oprot.writeBinary(_iter279); } oprot.writeListEnd(); } @@ -329,8 +329,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(HOSTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.hosts.size())); - for (HostPair _iter276 : this.hosts) { - _iter276.write(oprot); + for (HostPair _iter280 : this.hosts) { + _iter280.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java b/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java deleted file mode 100644 index 7f4a2d88e..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/SchemaID.java +++ /dev/null @@ -1,239 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial", "unchecked" }) -public class SchemaID extends TUnion implements Comparable { - private static final TStruct STRUCT_DESC = new TStruct("SchemaID"); - private static final TField TAG_ID_FIELD_DESC = new TField("tag_id", TType.I32, (short)1); - private static final TField EDGE_TYPE_FIELD_DESC = new TField("edge_type", TType.I32, (short)2); - - public static final int TAG_ID = 1; - public static final int EDGE_TYPE = 2; - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(TAG_ID, new FieldMetaData("tag_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(EDGE_TYPE, new FieldMetaData("edge_type", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - public SchemaID() { - super(); - } - - public SchemaID(int setField, Object __value) { - super(setField, __value); - } - - public SchemaID(SchemaID other) { - super(other); - } - - public SchemaID deepCopy() { - return new SchemaID(this); - } - - public static SchemaID tag_id(int __value) { - SchemaID x = new SchemaID(); - x.setTag_id(__value); - return x; - } - - public static SchemaID edge_type(int __value) { - SchemaID x = new SchemaID(); - x.setEdge_type(__value); - return x; - } - - - @Override - protected void checkType(short setField, Object __value) throws ClassCastException { - switch (setField) { - case TAG_ID: - if (__value instanceof Integer) { - break; - } - throw new ClassCastException("Was expecting value of type Integer for field 'tag_id', but got " + __value.getClass().getSimpleName()); - case EDGE_TYPE: - if (__value instanceof Integer) { - break; - } - throw new ClassCastException("Was expecting value of type Integer for field 'edge_type', but got " + __value.getClass().getSimpleName()); - default: - throw new IllegalArgumentException("Unknown field id " + setField); - } - } - - @Override - public void read(TProtocol iprot) throws TException { - setField_ = 0; - value_ = null; - iprot.readStructBegin(metaDataMap); - TField __field = iprot.readFieldBegin(); - if (__field.type != TType.STOP) - { - value_ = readValue(iprot, __field); - if (value_ != null) - { - switch (__field.id) { - case TAG_ID: - if (__field.type == TAG_ID_FIELD_DESC.type) { - setField_ = __field.id; - } - break; - case EDGE_TYPE: - if (__field.type == EDGE_TYPE_FIELD_DESC.type) { - setField_ = __field.id; - } - break; - } - } - iprot.readFieldEnd(); - TField __stopField = iprot.readFieldBegin(); - if (__stopField.type != TType.STOP) { - throw new TProtocolException(TProtocolException.INVALID_DATA, "Union 'SchemaID' is missing a STOP byte"); - } - } - iprot.readStructEnd(); - } - - @Override - protected Object readValue(TProtocol iprot, TField __field) throws TException { - switch (__field.id) { - case TAG_ID: - if (__field.type == TAG_ID_FIELD_DESC.type) { - Integer tag_id; - tag_id = iprot.readI32(); - return tag_id; - } - break; - case EDGE_TYPE: - if (__field.type == EDGE_TYPE_FIELD_DESC.type) { - Integer edge_type; - edge_type = iprot.readI32(); - return edge_type; - } - break; - } - TProtocolUtil.skip(iprot, __field.type); - return null; - } - - @Override - protected void writeValue(TProtocol oprot, short setField, Object __value) throws TException { - switch (setField) { - case TAG_ID: - Integer tag_id = (Integer)getFieldValue(); - oprot.writeI32(tag_id); - return; - case EDGE_TYPE: - Integer edge_type = (Integer)getFieldValue(); - oprot.writeI32(edge_type); - return; - default: - throw new IllegalStateException("Cannot write union with unknown field " + setField); - } - } - - @Override - protected TField getFieldDesc(int setField) { - switch (setField) { - case TAG_ID: - return TAG_ID_FIELD_DESC; - case EDGE_TYPE: - return EDGE_TYPE_FIELD_DESC; - default: - throw new IllegalArgumentException("Unknown field id " + setField); - } - } - - @Override - protected TStruct getStructDesc() { - return STRUCT_DESC; - } - - @Override - protected Map getMetaDataMap() { return metaDataMap; } - - private Object __getValue(int expectedFieldId) { - if (getSetField() == expectedFieldId) { - return getFieldValue(); - } else { - throw new RuntimeException("Cannot get field '" + getFieldDesc(expectedFieldId).name + "' because union is currently set to " + getFieldDesc(getSetField()).name); - } - } - - private void __setValue(int fieldId, Object __value) { - if (__value == null) throw new NullPointerException(); - setField_ = fieldId; - value_ = __value; - } - - public int getTag_id() { - return (Integer) __getValue(TAG_ID); - } - - public void setTag_id(int __value) { - setField_ = TAG_ID; - value_ = __value; - } - - public int getEdge_type() { - return (Integer) __getValue(EDGE_TYPE); - } - - public void setEdge_type(int __value) { - setField_ = EDGE_TYPE; - value_ = __value; - } - - public boolean equals(Object other) { - if (other instanceof SchemaID) { - return equals((SchemaID)other); - } else { - return false; - } - } - - public boolean equals(SchemaID other) { - return equalsNobinaryImpl(other); - } - - @Override - public int compareTo(SchemaID other) { - return compareToImpl(other); - } - - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {getSetField(), getFieldValue()}); - } - -} diff --git a/client/src/main/generated/com/vesoft/nebula/NodeInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/ServiceInfo.java similarity index 50% rename from client/src/main/generated/com/vesoft/nebula/NodeInfo.java rename to client/src/main/generated/com/vesoft/nebula/meta/ServiceInfo.java index ad7fa8b35..ed762871e 100644 --- a/client/src/main/generated/com/vesoft/nebula/NodeInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/ServiceInfo.java @@ -4,7 +4,7 @@ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ -package com.vesoft.nebula; +package com.vesoft.nebula.meta; import java.util.List; import java.util.ArrayList; @@ -24,15 +24,22 @@ import com.facebook.thrift.protocol.*; @SuppressWarnings({ "unused", "serial" }) -public class NodeInfo implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("NodeInfo"); - private static final TField HOST_FIELD_DESC = new TField("host", TType.STRUCT, (short)1); - private static final TField DIR_FIELD_DESC = new TField("dir", TType.STRUCT, (short)2); - - public HostAddr host; - public DirInfo dir; - public static final int HOST = 1; - public static final int DIR = 2; +public class ServiceInfo implements TBase, java.io.Serializable, Cloneable, Comparable { + private static final TStruct STRUCT_DESC = new TStruct("ServiceInfo"); + private static final TField DIR_FIELD_DESC = new TField("dir", TType.STRUCT, (short)1); + private static final TField ADDR_FIELD_DESC = new TField("addr", TType.STRUCT, (short)2); + private static final TField ROLE_FIELD_DESC = new TField("role", TType.I32, (short)3); + + public com.vesoft.nebula.DirInfo dir; + public com.vesoft.nebula.HostAddr addr; + /** + * + * @see HostRole + */ + public HostRole role; + public static final int DIR = 1; + public static final int ADDR = 2; + public static final int ROLE = 3; // isset id assignments @@ -40,49 +47,60 @@ public class NodeInfo implements TBase, java.io.Serializable, Cloneable, Compara static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(HOST, new FieldMetaData("host", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, HostAddr.class))); tmpMetaDataMap.put(DIR, new FieldMetaData("dir", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, DirInfo.class))); + new StructMetaData(TType.STRUCT, com.vesoft.nebula.DirInfo.class))); + tmpMetaDataMap.put(ADDR, new FieldMetaData("addr", TFieldRequirementType.DEFAULT, + new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); + tmpMetaDataMap.put(ROLE, new FieldMetaData("role", TFieldRequirementType.DEFAULT, + new FieldValueMetaData(TType.I32))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } static { - FieldMetaData.addStructMetaDataMap(NodeInfo.class, metaDataMap); + FieldMetaData.addStructMetaDataMap(ServiceInfo.class, metaDataMap); } - public NodeInfo() { + public ServiceInfo() { } - public NodeInfo( - HostAddr host, - DirInfo dir) { + public ServiceInfo( + com.vesoft.nebula.DirInfo dir, + com.vesoft.nebula.HostAddr addr, + HostRole role) { this(); - this.host = host; this.dir = dir; + this.addr = addr; + this.role = role; } public static class Builder { - private HostAddr host; - private DirInfo dir; + private com.vesoft.nebula.DirInfo dir; + private com.vesoft.nebula.HostAddr addr; + private HostRole role; public Builder() { } - public Builder setHost(final HostAddr host) { - this.host = host; + public Builder setDir(final com.vesoft.nebula.DirInfo dir) { + this.dir = dir; return this; } - public Builder setDir(final DirInfo dir) { - this.dir = dir; + public Builder setAddr(final com.vesoft.nebula.HostAddr addr) { + this.addr = addr; return this; } - public NodeInfo build() { - NodeInfo result = new NodeInfo(); - result.setHost(this.host); + public Builder setRole(final HostRole role) { + this.role = role; + return this; + } + + public ServiceInfo build() { + ServiceInfo result = new ServiceInfo(); result.setDir(this.dir); + result.setAddr(this.addr); + result.setRole(this.role); return result; } } @@ -94,82 +112,125 @@ public static Builder builder() { /** * Performs a deep copy on other. */ - public NodeInfo(NodeInfo other) { - if (other.isSetHost()) { - this.host = TBaseHelper.deepCopy(other.host); - } + public ServiceInfo(ServiceInfo other) { if (other.isSetDir()) { this.dir = TBaseHelper.deepCopy(other.dir); } + if (other.isSetAddr()) { + this.addr = TBaseHelper.deepCopy(other.addr); + } + if (other.isSetRole()) { + this.role = TBaseHelper.deepCopy(other.role); + } } - public NodeInfo deepCopy() { - return new NodeInfo(this); + public ServiceInfo deepCopy() { + return new ServiceInfo(this); } - public HostAddr getHost() { - return this.host; + public com.vesoft.nebula.DirInfo getDir() { + return this.dir; } - public NodeInfo setHost(HostAddr host) { - this.host = host; + public ServiceInfo setDir(com.vesoft.nebula.DirInfo dir) { + this.dir = dir; return this; } - public void unsetHost() { - this.host = null; + public void unsetDir() { + this.dir = null; } - // Returns true if field host is set (has been assigned a value) and false otherwise - public boolean isSetHost() { - return this.host != null; + // Returns true if field dir is set (has been assigned a value) and false otherwise + public boolean isSetDir() { + return this.dir != null; } - public void setHostIsSet(boolean __value) { + public void setDirIsSet(boolean __value) { if (!__value) { - this.host = null; + this.dir = null; } } - public DirInfo getDir() { - return this.dir; + public com.vesoft.nebula.HostAddr getAddr() { + return this.addr; } - public NodeInfo setDir(DirInfo dir) { - this.dir = dir; + public ServiceInfo setAddr(com.vesoft.nebula.HostAddr addr) { + this.addr = addr; return this; } - public void unsetDir() { - this.dir = null; + public void unsetAddr() { + this.addr = null; } - // Returns true if field dir is set (has been assigned a value) and false otherwise - public boolean isSetDir() { - return this.dir != null; + // Returns true if field addr is set (has been assigned a value) and false otherwise + public boolean isSetAddr() { + return this.addr != null; } - public void setDirIsSet(boolean __value) { + public void setAddrIsSet(boolean __value) { if (!__value) { - this.dir = null; + this.addr = null; + } + } + + /** + * + * @see HostRole + */ + public HostRole getRole() { + return this.role; + } + + /** + * + * @see HostRole + */ + public ServiceInfo setRole(HostRole role) { + this.role = role; + return this; + } + + public void unsetRole() { + this.role = null; + } + + // Returns true if field role is set (has been assigned a value) and false otherwise + public boolean isSetRole() { + return this.role != null; + } + + public void setRoleIsSet(boolean __value) { + if (!__value) { + this.role = null; } } public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case HOST: + case DIR: if (__value == null) { - unsetHost(); + unsetDir(); } else { - setHost((HostAddr)__value); + setDir((com.vesoft.nebula.DirInfo)__value); } break; - case DIR: + case ADDR: if (__value == null) { - unsetDir(); + unsetAddr(); } else { - setDir((DirInfo)__value); + setAddr((com.vesoft.nebula.HostAddr)__value); + } + break; + + case ROLE: + if (__value == null) { + unsetRole(); + } else { + setRole((HostRole)__value); } break; @@ -180,12 +241,15 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case HOST: - return getHost(); - case DIR: return getDir(); + case ADDR: + return getAddr(); + + case ROLE: + return getRole(); + default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); } @@ -197,24 +261,26 @@ public boolean equals(Object _that) { return false; if (this == _that) return true; - if (!(_that instanceof NodeInfo)) + if (!(_that instanceof ServiceInfo)) return false; - NodeInfo that = (NodeInfo)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetHost(), that.isSetHost(), this.host, that.host)) { return false; } + ServiceInfo that = (ServiceInfo)_that; if (!TBaseHelper.equalsNobinary(this.isSetDir(), that.isSetDir(), this.dir, that.dir)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetAddr(), that.isSetAddr(), this.addr, that.addr)) { return false; } + + if (!TBaseHelper.equalsNobinary(this.isSetRole(), that.isSetRole(), this.role, that.role)) { return false; } + return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {host, dir}); + return Arrays.deepHashCode(new Object[] {dir, addr, role}); } @Override - public int compareTo(NodeInfo other) { + public int compareTo(ServiceInfo other) { if (other == null) { // See java.lang.Comparable docs throw new NullPointerException(); @@ -225,19 +291,27 @@ public int compareTo(NodeInfo other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetHost()).compareTo(other.isSetHost()); + lastComparison = Boolean.valueOf(isSetDir()).compareTo(other.isSetDir()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(host, other.host); + lastComparison = TBaseHelper.compareTo(dir, other.dir); if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetDir()).compareTo(other.isSetDir()); + lastComparison = Boolean.valueOf(isSetAddr()).compareTo(other.isSetAddr()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(dir, other.dir); + lastComparison = TBaseHelper.compareTo(addr, other.addr); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = Boolean.valueOf(isSetRole()).compareTo(other.isSetRole()); + if (lastComparison != 0) { + return lastComparison; + } + lastComparison = TBaseHelper.compareTo(role, other.role); if (lastComparison != 0) { return lastComparison; } @@ -255,18 +329,25 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case HOST: + case DIR: if (__field.type == TType.STRUCT) { - this.host = new HostAddr(); - this.host.read(iprot); + this.dir = new com.vesoft.nebula.DirInfo(); + this.dir.read(iprot); } else { TProtocolUtil.skip(iprot, __field.type); } break; - case DIR: + case ADDR: if (__field.type == TType.STRUCT) { - this.dir = new DirInfo(); - this.dir.read(iprot); + this.addr = new com.vesoft.nebula.HostAddr(); + this.addr.read(iprot); + } else { + TProtocolUtil.skip(iprot, __field.type); + } + break; + case ROLE: + if (__field.type == TType.I32) { + this.role = HostRole.findByValue(iprot.readI32()); } else { TProtocolUtil.skip(iprot, __field.type); } @@ -288,16 +369,21 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - if (this.host != null) { - oprot.writeFieldBegin(HOST_FIELD_DESC); - this.host.write(oprot); - oprot.writeFieldEnd(); - } if (this.dir != null) { oprot.writeFieldBegin(DIR_FIELD_DESC); this.dir.write(oprot); oprot.writeFieldEnd(); } + if (this.addr != null) { + oprot.writeFieldBegin(ADDR_FIELD_DESC); + this.addr.write(oprot); + oprot.writeFieldEnd(); + } + if (this.role != null) { + oprot.writeFieldBegin(ROLE_FIELD_DESC); + oprot.writeI32(this.role == null ? 0 : this.role.getValue()); + oprot.writeFieldEnd(); + } oprot.writeFieldStop(); oprot.writeStructEnd(); } @@ -312,31 +398,50 @@ public String toString(int indent, boolean prettyPrint) { String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; String newLine = prettyPrint ? "\n" : ""; String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("NodeInfo"); + StringBuilder sb = new StringBuilder("ServiceInfo"); sb.append(space); sb.append("("); sb.append(newLine); boolean first = true; sb.append(indentStr); - sb.append("host"); + sb.append("dir"); sb.append(space); sb.append(":").append(space); - if (this.getHost() == null) { + if (this.getDir() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getHost(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getDir(), indent + 1, prettyPrint)); } first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("dir"); + sb.append("addr"); sb.append(space); sb.append(":").append(space); - if (this.getDir() == null) { + if (this.getAddr() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getDir(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getAddr(), indent + 1, prettyPrint)); + } + first = false; + if (!first) sb.append("," + newLine); + sb.append(indentStr); + sb.append("role"); + sb.append(space); + sb.append(":").append(space); + if (this.getRole() == null) { + sb.append("null"); + } else { + String role_name = this.getRole() == null ? "null" : this.getRole().name(); + if (role_name != null) { + sb.append(role_name); + sb.append(" ("); + } + sb.append(this.getRole()); + if (role_name != null) { + sb.append(")"); + } } first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Session.java b/client/src/main/generated/com/vesoft/nebula/meta/Session.java index 3477ee02a..3609413ba 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Session.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Session.java @@ -738,18 +738,18 @@ public void read(TProtocol iprot) throws TException { case CONFIGS: if (__field.type == TType.MAP) { { - TMap _map294 = iprot.readMapBegin(); - this.configs = new HashMap(Math.max(0, 2*_map294.size)); - for (int _i295 = 0; - (_map294.size < 0) ? iprot.peekMap() : (_i295 < _map294.size); - ++_i295) + TMap _map298 = iprot.readMapBegin(); + this.configs = new HashMap(Math.max(0, 2*_map298.size)); + for (int _i299 = 0; + (_map298.size < 0) ? iprot.peekMap() : (_i299 < _map298.size); + ++_i299) { - byte[] _key296; - com.vesoft.nebula.Value _val297; - _key296 = iprot.readBinary(); - _val297 = new com.vesoft.nebula.Value(); - _val297.read(iprot); - this.configs.put(_key296, _val297); + byte[] _key300; + com.vesoft.nebula.Value _val301; + _key300 = iprot.readBinary(); + _val301 = new com.vesoft.nebula.Value(); + _val301.read(iprot); + this.configs.put(_key300, _val301); } iprot.readMapEnd(); } @@ -760,18 +760,18 @@ public void read(TProtocol iprot) throws TException { case QUERIES: if (__field.type == TType.MAP) { { - TMap _map298 = iprot.readMapBegin(); - this.queries = new HashMap(Math.max(0, 2*_map298.size)); - for (int _i299 = 0; - (_map298.size < 0) ? iprot.peekMap() : (_i299 < _map298.size); - ++_i299) + TMap _map302 = iprot.readMapBegin(); + this.queries = new HashMap(Math.max(0, 2*_map302.size)); + for (int _i303 = 0; + (_map302.size < 0) ? iprot.peekMap() : (_i303 < _map302.size); + ++_i303) { - long _key300; - QueryDesc _val301; - _key300 = iprot.readI64(); - _val301 = new QueryDesc(); - _val301.read(iprot); - this.queries.put(_key300, _val301); + long _key304; + QueryDesc _val305; + _key304 = iprot.readI64(); + _val305 = new QueryDesc(); + _val305.read(iprot); + this.queries.put(_key304, _val305); } iprot.readMapEnd(); } @@ -832,9 +832,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CONFIGS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.configs.size())); - for (Map.Entry _iter302 : this.configs.entrySet()) { - oprot.writeBinary(_iter302.getKey()); - _iter302.getValue().write(oprot); + for (Map.Entry _iter306 : this.configs.entrySet()) { + oprot.writeBinary(_iter306.getKey()); + _iter306.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -844,9 +844,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, this.queries.size())); - for (Map.Entry _iter303 : this.queries.entrySet()) { - oprot.writeI64(_iter303.getKey()); - _iter303.getValue().write(oprot); + for (Map.Entry _iter307 : this.queries.entrySet()) { + oprot.writeI64(_iter307.getKey()); + _iter307.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java b/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java deleted file mode 100644 index 979afd30a..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/SessionContext.java +++ /dev/null @@ -1,839 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class SessionContext implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("SessionContext"); - private static final TField SESSION_ID_FIELD_DESC = new TField("session_id", TType.I64, (short)1); - private static final TField USER_NAME_FIELD_DESC = new TField("user_name", TType.STRING, (short)2); - private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)3); - private static final TField SCHEMA_FIELD_DESC = new TField("schema", TType.STRUCT, (short)4); - private static final TField SPACE_NAME_FIELD_DESC = new TField("space_name", TType.STRING, (short)5); - private static final TField PARAM_DICT_FIELD_DESC = new TField("param_dict", TType.MAP, (short)6); - private static final TField PARAM_FALGS_FIELD_DESC = new TField("param_falgs", TType.MAP, (short)7); - private static final TField IS_TERMINATED_FIELD_DESC = new TField("is_terminated", TType.BOOL, (short)8); - - public long session_id; - public byte[] user_name; - public int timezone; - public SessionSchema schema; - public byte[] space_name; - public Map param_dict; - public Map param_falgs; - public boolean is_terminated; - public static final int SESSION_ID = 1; - public static final int USER_NAME = 2; - public static final int TIMEZONE = 3; - public static final int SCHEMA = 4; - public static final int SPACE_NAME = 5; - public static final int PARAM_DICT = 6; - public static final int PARAM_FALGS = 7; - public static final int IS_TERMINATED = 8; - - // isset id assignments - private static final int __SESSION_ID_ISSET_ID = 0; - private static final int __TIMEZONE_ISSET_ID = 1; - private static final int __IS_TERMINATED_ISSET_ID = 2; - private BitSet __isset_bit_vector = new BitSet(3); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SESSION_ID, new FieldMetaData("session_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(USER_NAME, new FieldMetaData("user_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(SCHEMA, new FieldMetaData("schema", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, SessionSchema.class))); - tmpMetaDataMap.put(SPACE_NAME, new FieldMetaData("space_name", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - tmpMetaDataMap.put(PARAM_DICT, new FieldMetaData("param_dict", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.STRING), - new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); - tmpMetaDataMap.put(PARAM_FALGS, new FieldMetaData("param_falgs", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.STRING), - new StructMetaData(TType.STRUCT, com.vesoft.nebula.Value.class)))); - tmpMetaDataMap.put(IS_TERMINATED, new FieldMetaData("is_terminated", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.BOOL))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(SessionContext.class, metaDataMap); - } - - public SessionContext() { - this.is_terminated = false; - - } - - public SessionContext( - long session_id, - byte[] user_name, - int timezone, - SessionSchema schema, - byte[] space_name, - Map param_dict, - Map param_falgs, - boolean is_terminated) { - this(); - this.session_id = session_id; - setSession_idIsSet(true); - this.user_name = user_name; - this.timezone = timezone; - setTimezoneIsSet(true); - this.schema = schema; - this.space_name = space_name; - this.param_dict = param_dict; - this.param_falgs = param_falgs; - this.is_terminated = is_terminated; - setIs_terminatedIsSet(true); - } - - public static class Builder { - private long session_id; - private byte[] user_name; - private int timezone; - private SessionSchema schema; - private byte[] space_name; - private Map param_dict; - private Map param_falgs; - private boolean is_terminated; - - BitSet __optional_isset = new BitSet(3); - - public Builder() { - } - - public Builder setSession_id(final long session_id) { - this.session_id = session_id; - __optional_isset.set(__SESSION_ID_ISSET_ID, true); - return this; - } - - public Builder setUser_name(final byte[] user_name) { - this.user_name = user_name; - return this; - } - - public Builder setTimezone(final int timezone) { - this.timezone = timezone; - __optional_isset.set(__TIMEZONE_ISSET_ID, true); - return this; - } - - public Builder setSchema(final SessionSchema schema) { - this.schema = schema; - return this; - } - - public Builder setSpace_name(final byte[] space_name) { - this.space_name = space_name; - return this; - } - - public Builder setParam_dict(final Map param_dict) { - this.param_dict = param_dict; - return this; - } - - public Builder setParam_falgs(final Map param_falgs) { - this.param_falgs = param_falgs; - return this; - } - - public Builder setIs_terminated(final boolean is_terminated) { - this.is_terminated = is_terminated; - __optional_isset.set(__IS_TERMINATED_ISSET_ID, true); - return this; - } - - public SessionContext build() { - SessionContext result = new SessionContext(); - if (__optional_isset.get(__SESSION_ID_ISSET_ID)) { - result.setSession_id(this.session_id); - } - result.setUser_name(this.user_name); - if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { - result.setTimezone(this.timezone); - } - result.setSchema(this.schema); - result.setSpace_name(this.space_name); - result.setParam_dict(this.param_dict); - result.setParam_falgs(this.param_falgs); - if (__optional_isset.get(__IS_TERMINATED_ISSET_ID)) { - result.setIs_terminated(this.is_terminated); - } - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public SessionContext(SessionContext other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.session_id = TBaseHelper.deepCopy(other.session_id); - if (other.isSetUser_name()) { - this.user_name = TBaseHelper.deepCopy(other.user_name); - } - this.timezone = TBaseHelper.deepCopy(other.timezone); - if (other.isSetSchema()) { - this.schema = TBaseHelper.deepCopy(other.schema); - } - if (other.isSetSpace_name()) { - this.space_name = TBaseHelper.deepCopy(other.space_name); - } - if (other.isSetParam_dict()) { - this.param_dict = TBaseHelper.deepCopy(other.param_dict); - } - if (other.isSetParam_falgs()) { - this.param_falgs = TBaseHelper.deepCopy(other.param_falgs); - } - this.is_terminated = TBaseHelper.deepCopy(other.is_terminated); - } - - public SessionContext deepCopy() { - return new SessionContext(this); - } - - public long getSession_id() { - return this.session_id; - } - - public SessionContext setSession_id(long session_id) { - this.session_id = session_id; - setSession_idIsSet(true); - return this; - } - - public void unsetSession_id() { - __isset_bit_vector.clear(__SESSION_ID_ISSET_ID); - } - - // Returns true if field session_id is set (has been assigned a value) and false otherwise - public boolean isSetSession_id() { - return __isset_bit_vector.get(__SESSION_ID_ISSET_ID); - } - - public void setSession_idIsSet(boolean __value) { - __isset_bit_vector.set(__SESSION_ID_ISSET_ID, __value); - } - - public byte[] getUser_name() { - return this.user_name; - } - - public SessionContext setUser_name(byte[] user_name) { - this.user_name = user_name; - return this; - } - - public void unsetUser_name() { - this.user_name = null; - } - - // Returns true if field user_name is set (has been assigned a value) and false otherwise - public boolean isSetUser_name() { - return this.user_name != null; - } - - public void setUser_nameIsSet(boolean __value) { - if (!__value) { - this.user_name = null; - } - } - - public int getTimezone() { - return this.timezone; - } - - public SessionContext setTimezone(int timezone) { - this.timezone = timezone; - setTimezoneIsSet(true); - return this; - } - - public void unsetTimezone() { - __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); - } - - // Returns true if field timezone is set (has been assigned a value) and false otherwise - public boolean isSetTimezone() { - return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); - } - - public void setTimezoneIsSet(boolean __value) { - __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); - } - - public SessionSchema getSchema() { - return this.schema; - } - - public SessionContext setSchema(SessionSchema schema) { - this.schema = schema; - return this; - } - - public void unsetSchema() { - this.schema = null; - } - - // Returns true if field schema is set (has been assigned a value) and false otherwise - public boolean isSetSchema() { - return this.schema != null; - } - - public void setSchemaIsSet(boolean __value) { - if (!__value) { - this.schema = null; - } - } - - public byte[] getSpace_name() { - return this.space_name; - } - - public SessionContext setSpace_name(byte[] space_name) { - this.space_name = space_name; - return this; - } - - public void unsetSpace_name() { - this.space_name = null; - } - - // Returns true if field space_name is set (has been assigned a value) and false otherwise - public boolean isSetSpace_name() { - return this.space_name != null; - } - - public void setSpace_nameIsSet(boolean __value) { - if (!__value) { - this.space_name = null; - } - } - - public Map getParam_dict() { - return this.param_dict; - } - - public SessionContext setParam_dict(Map param_dict) { - this.param_dict = param_dict; - return this; - } - - public void unsetParam_dict() { - this.param_dict = null; - } - - // Returns true if field param_dict is set (has been assigned a value) and false otherwise - public boolean isSetParam_dict() { - return this.param_dict != null; - } - - public void setParam_dictIsSet(boolean __value) { - if (!__value) { - this.param_dict = null; - } - } - - public Map getParam_falgs() { - return this.param_falgs; - } - - public SessionContext setParam_falgs(Map param_falgs) { - this.param_falgs = param_falgs; - return this; - } - - public void unsetParam_falgs() { - this.param_falgs = null; - } - - // Returns true if field param_falgs is set (has been assigned a value) and false otherwise - public boolean isSetParam_falgs() { - return this.param_falgs != null; - } - - public void setParam_falgsIsSet(boolean __value) { - if (!__value) { - this.param_falgs = null; - } - } - - public boolean isIs_terminated() { - return this.is_terminated; - } - - public SessionContext setIs_terminated(boolean is_terminated) { - this.is_terminated = is_terminated; - setIs_terminatedIsSet(true); - return this; - } - - public void unsetIs_terminated() { - __isset_bit_vector.clear(__IS_TERMINATED_ISSET_ID); - } - - // Returns true if field is_terminated is set (has been assigned a value) and false otherwise - public boolean isSetIs_terminated() { - return __isset_bit_vector.get(__IS_TERMINATED_ISSET_ID); - } - - public void setIs_terminatedIsSet(boolean __value) { - __isset_bit_vector.set(__IS_TERMINATED_ISSET_ID, __value); - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SESSION_ID: - if (__value == null) { - unsetSession_id(); - } else { - setSession_id((Long)__value); - } - break; - - case USER_NAME: - if (__value == null) { - unsetUser_name(); - } else { - setUser_name((byte[])__value); - } - break; - - case TIMEZONE: - if (__value == null) { - unsetTimezone(); - } else { - setTimezone((Integer)__value); - } - break; - - case SCHEMA: - if (__value == null) { - unsetSchema(); - } else { - setSchema((SessionSchema)__value); - } - break; - - case SPACE_NAME: - if (__value == null) { - unsetSpace_name(); - } else { - setSpace_name((byte[])__value); - } - break; - - case PARAM_DICT: - if (__value == null) { - unsetParam_dict(); - } else { - setParam_dict((Map)__value); - } - break; - - case PARAM_FALGS: - if (__value == null) { - unsetParam_falgs(); - } else { - setParam_falgs((Map)__value); - } - break; - - case IS_TERMINATED: - if (__value == null) { - unsetIs_terminated(); - } else { - setIs_terminated((Boolean)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SESSION_ID: - return new Long(getSession_id()); - - case USER_NAME: - return getUser_name(); - - case TIMEZONE: - return new Integer(getTimezone()); - - case SCHEMA: - return getSchema(); - - case SPACE_NAME: - return getSpace_name(); - - case PARAM_DICT: - return getParam_dict(); - - case PARAM_FALGS: - return getParam_falgs(); - - case IS_TERMINATED: - return new Boolean(isIs_terminated()); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof SessionContext)) - return false; - SessionContext that = (SessionContext)_that; - - if (!TBaseHelper.equalsNobinary(this.session_id, that.session_id)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetUser_name(), that.isSetUser_name(), this.user_name, that.user_name)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetSchema(), that.isSetSchema(), this.schema, that.schema)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetSpace_name(), that.isSetSpace_name(), this.space_name, that.space_name)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetParam_dict(), that.isSetParam_dict(), this.param_dict, that.param_dict)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetParam_falgs(), that.isSetParam_falgs(), this.param_falgs, that.param_falgs)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.is_terminated, that.is_terminated)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {session_id, user_name, timezone, schema, space_name, param_dict, param_falgs, is_terminated}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SESSION_ID: - if (__field.type == TType.I64) { - this.session_id = iprot.readI64(); - setSession_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case USER_NAME: - if (__field.type == TType.STRING) { - this.user_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case TIMEZONE: - if (__field.type == TType.I32) { - this.timezone = iprot.readI32(); - setTimezoneIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SCHEMA: - if (__field.type == TType.STRUCT) { - this.schema = new SessionSchema(); - this.schema.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SPACE_NAME: - if (__field.type == TType.STRING) { - this.space_name = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case PARAM_DICT: - if (__field.type == TType.MAP) { - { - TMap _map304 = iprot.readMapBegin(); - this.param_dict = new HashMap(Math.max(0, 2*_map304.size)); - for (int _i305 = 0; - (_map304.size < 0) ? iprot.peekMap() : (_i305 < _map304.size); - ++_i305) - { - byte[] _key306; - com.vesoft.nebula.Value _val307; - _key306 = iprot.readBinary(); - _val307 = new com.vesoft.nebula.Value(); - _val307.read(iprot); - this.param_dict.put(_key306, _val307); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case PARAM_FALGS: - if (__field.type == TType.MAP) { - { - TMap _map308 = iprot.readMapBegin(); - this.param_falgs = new HashMap(Math.max(0, 2*_map308.size)); - for (int _i309 = 0; - (_map308.size < 0) ? iprot.peekMap() : (_i309 < _map308.size); - ++_i309) - { - byte[] _key310; - com.vesoft.nebula.Value _val311; - _key310 = iprot.readBinary(); - _val311 = new com.vesoft.nebula.Value(); - _val311.read(iprot); - this.param_falgs.put(_key310, _val311); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case IS_TERMINATED: - if (__field.type == TType.BOOL) { - this.is_terminated = iprot.readBool(); - setIs_terminatedIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SESSION_ID_FIELD_DESC); - oprot.writeI64(this.session_id); - oprot.writeFieldEnd(); - if (this.user_name != null) { - oprot.writeFieldBegin(USER_NAME_FIELD_DESC); - oprot.writeBinary(this.user_name); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); - oprot.writeI32(this.timezone); - oprot.writeFieldEnd(); - if (this.schema != null) { - oprot.writeFieldBegin(SCHEMA_FIELD_DESC); - this.schema.write(oprot); - oprot.writeFieldEnd(); - } - if (this.space_name != null) { - oprot.writeFieldBegin(SPACE_NAME_FIELD_DESC); - oprot.writeBinary(this.space_name); - oprot.writeFieldEnd(); - } - if (this.param_dict != null) { - oprot.writeFieldBegin(PARAM_DICT_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.param_dict.size())); - for (Map.Entry _iter312 : this.param_dict.entrySet()) { - oprot.writeBinary(_iter312.getKey()); - _iter312.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - if (this.param_falgs != null) { - oprot.writeFieldBegin(PARAM_FALGS_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.STRING, TType.STRUCT, this.param_falgs.size())); - for (Map.Entry _iter313 : this.param_falgs.entrySet()) { - oprot.writeBinary(_iter313.getKey()); - _iter313.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(IS_TERMINATED_FIELD_DESC); - oprot.writeBool(this.is_terminated); - oprot.writeFieldEnd(); - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("SessionContext"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("session_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSession_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("user_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getUser_name() == null) { - sb.append("null"); - } else { - int __user_name_size = Math.min(this.getUser_name().length, 128); - for (int i = 0; i < __user_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getUser_name()[i]).length() > 1 ? Integer.toHexString(this.getUser_name()[i]).substring(Integer.toHexString(this.getUser_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getUser_name()[i]).toUpperCase()); - } - if (this.getUser_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("timezone"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("schema"); - sb.append(space); - sb.append(":").append(space); - if (this.getSchema() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSchema(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("space_name"); - sb.append(space); - sb.append(":").append(space); - if (this.getSpace_name() == null) { - sb.append("null"); - } else { - int __space_name_size = Math.min(this.getSpace_name().length, 128); - for (int i = 0; i < __space_name_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getSpace_name()[i]).length() > 1 ? Integer.toHexString(this.getSpace_name()[i]).substring(Integer.toHexString(this.getSpace_name()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getSpace_name()[i]).toUpperCase()); - } - if (this.getSpace_name().length > 128) sb.append(" ..."); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("param_dict"); - sb.append(space); - sb.append(":").append(space); - if (this.getParam_dict() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getParam_dict(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("param_falgs"); - sb.append(space); - sb.append(":").append(space); - if (this.getParam_falgs() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getParam_falgs(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("is_terminated"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.isIs_terminated(), indent + 1, prettyPrint)); - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java b/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java deleted file mode 100644 index 2f4520787..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/SessionSchema.java +++ /dev/null @@ -1,607 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class SessionSchema implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("SessionSchema"); - private static final TField CREATE_TIME_FIELD_DESC = new TField("create_time", TType.I64, (short)1); - private static final TField UPDATE_TIME_FIELD_DESC = new TField("update_time", TType.I64, (short)2); - private static final TField GRAPH_ADDR_FIELD_DESC = new TField("graph_addr", TType.STRUCT, (short)3); - private static final TField TIMEZONE_FIELD_DESC = new TField("timezone", TType.I32, (short)4); - private static final TField CLIENT_IP_FIELD_DESC = new TField("client_ip", TType.STRING, (short)5); - - public long create_time; - public long update_time; - public com.vesoft.nebula.HostAddr graph_addr; - public int timezone; - public byte[] client_ip; - public static final int CREATE_TIME = 1; - public static final int UPDATE_TIME = 2; - public static final int GRAPH_ADDR = 3; - public static final int TIMEZONE = 4; - public static final int CLIENT_IP = 5; - - // isset id assignments - private static final int __CREATE_TIME_ISSET_ID = 0; - private static final int __UPDATE_TIME_ISSET_ID = 1; - private static final int __TIMEZONE_ISSET_ID = 2; - private BitSet __isset_bit_vector = new BitSet(3); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(CREATE_TIME, new FieldMetaData("create_time", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(UPDATE_TIME, new FieldMetaData("update_time", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(GRAPH_ADDR, new FieldMetaData("graph_addr", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.HostAddr.class))); - tmpMetaDataMap.put(TIMEZONE, new FieldMetaData("timezone", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(CLIENT_IP, new FieldMetaData("client_ip", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(SessionSchema.class, metaDataMap); - } - - public SessionSchema() { - } - - public SessionSchema( - long create_time, - long update_time, - com.vesoft.nebula.HostAddr graph_addr, - int timezone, - byte[] client_ip) { - this(); - this.create_time = create_time; - setCreate_timeIsSet(true); - this.update_time = update_time; - setUpdate_timeIsSet(true); - this.graph_addr = graph_addr; - this.timezone = timezone; - setTimezoneIsSet(true); - this.client_ip = client_ip; - } - - public static class Builder { - private long create_time; - private long update_time; - private com.vesoft.nebula.HostAddr graph_addr; - private int timezone; - private byte[] client_ip; - - BitSet __optional_isset = new BitSet(3); - - public Builder() { - } - - public Builder setCreate_time(final long create_time) { - this.create_time = create_time; - __optional_isset.set(__CREATE_TIME_ISSET_ID, true); - return this; - } - - public Builder setUpdate_time(final long update_time) { - this.update_time = update_time; - __optional_isset.set(__UPDATE_TIME_ISSET_ID, true); - return this; - } - - public Builder setGraph_addr(final com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public Builder setTimezone(final int timezone) { - this.timezone = timezone; - __optional_isset.set(__TIMEZONE_ISSET_ID, true); - return this; - } - - public Builder setClient_ip(final byte[] client_ip) { - this.client_ip = client_ip; - return this; - } - - public SessionSchema build() { - SessionSchema result = new SessionSchema(); - if (__optional_isset.get(__CREATE_TIME_ISSET_ID)) { - result.setCreate_time(this.create_time); - } - if (__optional_isset.get(__UPDATE_TIME_ISSET_ID)) { - result.setUpdate_time(this.update_time); - } - result.setGraph_addr(this.graph_addr); - if (__optional_isset.get(__TIMEZONE_ISSET_ID)) { - result.setTimezone(this.timezone); - } - result.setClient_ip(this.client_ip); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public SessionSchema(SessionSchema other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.create_time = TBaseHelper.deepCopy(other.create_time); - this.update_time = TBaseHelper.deepCopy(other.update_time); - if (other.isSetGraph_addr()) { - this.graph_addr = TBaseHelper.deepCopy(other.graph_addr); - } - this.timezone = TBaseHelper.deepCopy(other.timezone); - if (other.isSetClient_ip()) { - this.client_ip = TBaseHelper.deepCopy(other.client_ip); - } - } - - public SessionSchema deepCopy() { - return new SessionSchema(this); - } - - public long getCreate_time() { - return this.create_time; - } - - public SessionSchema setCreate_time(long create_time) { - this.create_time = create_time; - setCreate_timeIsSet(true); - return this; - } - - public void unsetCreate_time() { - __isset_bit_vector.clear(__CREATE_TIME_ISSET_ID); - } - - // Returns true if field create_time is set (has been assigned a value) and false otherwise - public boolean isSetCreate_time() { - return __isset_bit_vector.get(__CREATE_TIME_ISSET_ID); - } - - public void setCreate_timeIsSet(boolean __value) { - __isset_bit_vector.set(__CREATE_TIME_ISSET_ID, __value); - } - - public long getUpdate_time() { - return this.update_time; - } - - public SessionSchema setUpdate_time(long update_time) { - this.update_time = update_time; - setUpdate_timeIsSet(true); - return this; - } - - public void unsetUpdate_time() { - __isset_bit_vector.clear(__UPDATE_TIME_ISSET_ID); - } - - // Returns true if field update_time is set (has been assigned a value) and false otherwise - public boolean isSetUpdate_time() { - return __isset_bit_vector.get(__UPDATE_TIME_ISSET_ID); - } - - public void setUpdate_timeIsSet(boolean __value) { - __isset_bit_vector.set(__UPDATE_TIME_ISSET_ID, __value); - } - - public com.vesoft.nebula.HostAddr getGraph_addr() { - return this.graph_addr; - } - - public SessionSchema setGraph_addr(com.vesoft.nebula.HostAddr graph_addr) { - this.graph_addr = graph_addr; - return this; - } - - public void unsetGraph_addr() { - this.graph_addr = null; - } - - // Returns true if field graph_addr is set (has been assigned a value) and false otherwise - public boolean isSetGraph_addr() { - return this.graph_addr != null; - } - - public void setGraph_addrIsSet(boolean __value) { - if (!__value) { - this.graph_addr = null; - } - } - - public int getTimezone() { - return this.timezone; - } - - public SessionSchema setTimezone(int timezone) { - this.timezone = timezone; - setTimezoneIsSet(true); - return this; - } - - public void unsetTimezone() { - __isset_bit_vector.clear(__TIMEZONE_ISSET_ID); - } - - // Returns true if field timezone is set (has been assigned a value) and false otherwise - public boolean isSetTimezone() { - return __isset_bit_vector.get(__TIMEZONE_ISSET_ID); - } - - public void setTimezoneIsSet(boolean __value) { - __isset_bit_vector.set(__TIMEZONE_ISSET_ID, __value); - } - - public byte[] getClient_ip() { - return this.client_ip; - } - - public SessionSchema setClient_ip(byte[] client_ip) { - this.client_ip = client_ip; - return this; - } - - public void unsetClient_ip() { - this.client_ip = null; - } - - // Returns true if field client_ip is set (has been assigned a value) and false otherwise - public boolean isSetClient_ip() { - return this.client_ip != null; - } - - public void setClient_ipIsSet(boolean __value) { - if (!__value) { - this.client_ip = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case CREATE_TIME: - if (__value == null) { - unsetCreate_time(); - } else { - setCreate_time((Long)__value); - } - break; - - case UPDATE_TIME: - if (__value == null) { - unsetUpdate_time(); - } else { - setUpdate_time((Long)__value); - } - break; - - case GRAPH_ADDR: - if (__value == null) { - unsetGraph_addr(); - } else { - setGraph_addr((com.vesoft.nebula.HostAddr)__value); - } - break; - - case TIMEZONE: - if (__value == null) { - unsetTimezone(); - } else { - setTimezone((Integer)__value); - } - break; - - case CLIENT_IP: - if (__value == null) { - unsetClient_ip(); - } else { - setClient_ip((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case CREATE_TIME: - return new Long(getCreate_time()); - - case UPDATE_TIME: - return new Long(getUpdate_time()); - - case GRAPH_ADDR: - return getGraph_addr(); - - case TIMEZONE: - return new Integer(getTimezone()); - - case CLIENT_IP: - return getClient_ip(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof SessionSchema)) - return false; - SessionSchema that = (SessionSchema)_that; - - if (!TBaseHelper.equalsNobinary(this.create_time, that.create_time)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.update_time, that.update_time)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetGraph_addr(), that.isSetGraph_addr(), this.graph_addr, that.graph_addr)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.timezone, that.timezone)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetClient_ip(), that.isSetClient_ip(), this.client_ip, that.client_ip)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {create_time, update_time, graph_addr, timezone, client_ip}); - } - - @Override - public int compareTo(SessionSchema other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetCreate_time()).compareTo(other.isSetCreate_time()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(create_time, other.create_time); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetUpdate_time()).compareTo(other.isSetUpdate_time()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(update_time, other.update_time); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetGraph_addr()).compareTo(other.isSetGraph_addr()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(graph_addr, other.graph_addr); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetTimezone()).compareTo(other.isSetTimezone()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(timezone, other.timezone); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetClient_ip()).compareTo(other.isSetClient_ip()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(client_ip, other.client_ip); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case CREATE_TIME: - if (__field.type == TType.I64) { - this.create_time = iprot.readI64(); - setCreate_timeIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case UPDATE_TIME: - if (__field.type == TType.I64) { - this.update_time = iprot.readI64(); - setUpdate_timeIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case GRAPH_ADDR: - if (__field.type == TType.STRUCT) { - this.graph_addr = new com.vesoft.nebula.HostAddr(); - this.graph_addr.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case TIMEZONE: - if (__field.type == TType.I32) { - this.timezone = iprot.readI32(); - setTimezoneIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CLIENT_IP: - if (__field.type == TType.STRING) { - this.client_ip = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); - oprot.writeI64(this.create_time); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(UPDATE_TIME_FIELD_DESC); - oprot.writeI64(this.update_time); - oprot.writeFieldEnd(); - if (this.graph_addr != null) { - oprot.writeFieldBegin(GRAPH_ADDR_FIELD_DESC); - this.graph_addr.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(TIMEZONE_FIELD_DESC); - oprot.writeI32(this.timezone); - oprot.writeFieldEnd(); - if (this.client_ip != null) { - oprot.writeFieldBegin(CLIENT_IP_FIELD_DESC); - oprot.writeBinary(this.client_ip); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("SessionSchema"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("create_time"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getCreate_time(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("update_time"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getUpdate_time(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("graph_addr"); - sb.append(space); - sb.append(":").append(space); - if (this.getGraph_addr() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getGraph_addr(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("timezone"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getTimezone(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("client_ip"); - sb.append(space); - sb.append(":").append(space); - if (this.getClient_ip() == null) { - sb.append("null"); - } else { - int __client_ip_size = Math.min(this.getClient_ip().length, 128); - for (int i = 0; i < __client_ip_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getClient_ip()[i]).length() > 1 ? Integer.toHexString(this.getClient_ip()[i]).substring(Integer.toHexString(this.getClient_ip()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getClient_ip()[i]).toUpperCase()); - } - if (this.getClient_ip().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java index d06d03b39..5b3572b58 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SignInFTServiceReq.java @@ -279,16 +279,16 @@ public void read(TProtocol iprot) throws TException { case CLIENTS: if (__field.type == TType.LIST) { { - TList _list277 = iprot.readListBegin(); - this.clients = new ArrayList(Math.max(0, _list277.size)); - for (int _i278 = 0; - (_list277.size < 0) ? iprot.peekList() : (_i278 < _list277.size); - ++_i278) + TList _list281 = iprot.readListBegin(); + this.clients = new ArrayList(Math.max(0, _list281.size)); + for (int _i282 = 0; + (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); + ++_i282) { - FTClient _elem279; - _elem279 = new FTClient(); - _elem279.read(iprot); - this.clients.add(_elem279); + FTClient _elem283; + _elem283 = new FTClient(); + _elem283.read(iprot); + this.clients.add(_elem283); } iprot.readListEnd(); } @@ -322,8 +322,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(CLIENTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.clients.size())); - for (FTClient _iter280 : this.clients) { - _iter280.write(oprot); + for (FTClient _iter284 : this.clients) { + _iter284.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java index ce9e76060..21ab2eb81 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/SpaceBackupInfo.java @@ -27,12 +27,12 @@ public class SpaceBackupInfo implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("SpaceBackupInfo"); private static final TField SPACE_FIELD_DESC = new TField("space", TType.STRUCT, (short)1); - private static final TField INFO_FIELD_DESC = new TField("info", TType.LIST, (short)2); + private static final TField HOST_BACKUPS_FIELD_DESC = new TField("host_backups", TType.LIST, (short)2); public SpaceDesc space; - public List info; + public List host_backups; public static final int SPACE = 1; - public static final int INFO = 2; + public static final int HOST_BACKUPS = 2; // isset id assignments @@ -42,9 +42,9 @@ public class SpaceBackupInfo implements TBase, java.io.Serializable, Cloneable, Map tmpMetaDataMap = new HashMap(); tmpMetaDataMap.put(SPACE, new FieldMetaData("space", TFieldRequirementType.DEFAULT, new StructMetaData(TType.STRUCT, SpaceDesc.class))); - tmpMetaDataMap.put(INFO, new FieldMetaData("info", TFieldRequirementType.DEFAULT, + tmpMetaDataMap.put(HOST_BACKUPS, new FieldMetaData("host_backups", TFieldRequirementType.DEFAULT, new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, BackupInfo.class)))); + new StructMetaData(TType.STRUCT, HostBackupInfo.class)))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); } @@ -57,15 +57,15 @@ public SpaceBackupInfo() { public SpaceBackupInfo( SpaceDesc space, - List info) { + List host_backups) { this(); this.space = space; - this.info = info; + this.host_backups = host_backups; } public static class Builder { private SpaceDesc space; - private List info; + private List host_backups; public Builder() { } @@ -75,15 +75,15 @@ public Builder setSpace(final SpaceDesc space) { return this; } - public Builder setInfo(final List info) { - this.info = info; + public Builder setHost_backups(final List host_backups) { + this.host_backups = host_backups; return this; } public SpaceBackupInfo build() { SpaceBackupInfo result = new SpaceBackupInfo(); result.setSpace(this.space); - result.setInfo(this.info); + result.setHost_backups(this.host_backups); return result; } } @@ -99,8 +99,8 @@ public SpaceBackupInfo(SpaceBackupInfo other) { if (other.isSetSpace()) { this.space = TBaseHelper.deepCopy(other.space); } - if (other.isSetInfo()) { - this.info = TBaseHelper.deepCopy(other.info); + if (other.isSetHost_backups()) { + this.host_backups = TBaseHelper.deepCopy(other.host_backups); } } @@ -132,27 +132,27 @@ public void setSpaceIsSet(boolean __value) { } } - public List getInfo() { - return this.info; + public List getHost_backups() { + return this.host_backups; } - public SpaceBackupInfo setInfo(List info) { - this.info = info; + public SpaceBackupInfo setHost_backups(List host_backups) { + this.host_backups = host_backups; return this; } - public void unsetInfo() { - this.info = null; + public void unsetHost_backups() { + this.host_backups = null; } - // Returns true if field info is set (has been assigned a value) and false otherwise - public boolean isSetInfo() { - return this.info != null; + // Returns true if field host_backups is set (has been assigned a value) and false otherwise + public boolean isSetHost_backups() { + return this.host_backups != null; } - public void setInfoIsSet(boolean __value) { + public void setHost_backupsIsSet(boolean __value) { if (!__value) { - this.info = null; + this.host_backups = null; } } @@ -167,11 +167,11 @@ public void setFieldValue(int fieldID, Object __value) { } break; - case INFO: + case HOST_BACKUPS: if (__value == null) { - unsetInfo(); + unsetHost_backups(); } else { - setInfo((List)__value); + setHost_backups((List)__value); } break; @@ -185,8 +185,8 @@ public Object getFieldValue(int fieldID) { case SPACE: return getSpace(); - case INFO: - return getInfo(); + case HOST_BACKUPS: + return getHost_backups(); default: throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); @@ -205,14 +205,14 @@ public boolean equals(Object _that) { if (!TBaseHelper.equalsNobinary(this.isSetSpace(), that.isSetSpace(), this.space, that.space)) { return false; } - if (!TBaseHelper.equalsNobinary(this.isSetInfo(), that.isSetInfo(), this.info, that.info)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetHost_backups(), that.isSetHost_backups(), this.host_backups, that.host_backups)) { return false; } return true; } @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space, info}); + return Arrays.deepHashCode(new Object[] {space, host_backups}); } @Override @@ -235,11 +235,11 @@ public int compareTo(SpaceBackupInfo other) { if (lastComparison != 0) { return lastComparison; } - lastComparison = Boolean.valueOf(isSetInfo()).compareTo(other.isSetInfo()); + lastComparison = Boolean.valueOf(isSetHost_backups()).compareTo(other.isSetHost_backups()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(info, other.info); + lastComparison = TBaseHelper.compareTo(host_backups, other.host_backups); if (lastComparison != 0) { return lastComparison; } @@ -265,19 +265,19 @@ public void read(TProtocol iprot) throws TException { TProtocolUtil.skip(iprot, __field.type); } break; - case INFO: + case HOST_BACKUPS: if (__field.type == TType.LIST) { { - TList _list252 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list252.size)); - for (int _i253 = 0; - (_list252.size < 0) ? iprot.peekList() : (_i253 < _list252.size); - ++_i253) + TList _list256 = iprot.readListBegin(); + this.host_backups = new ArrayList(Math.max(0, _list256.size)); + for (int _i257 = 0; + (_list256.size < 0) ? iprot.peekList() : (_i257 < _list256.size); + ++_i257) { - BackupInfo _elem254; - _elem254 = new BackupInfo(); - _elem254.read(iprot); - this.info.add(_elem254); + HostBackupInfo _elem258; + _elem258 = new HostBackupInfo(); + _elem258.read(iprot); + this.host_backups.add(_elem258); } iprot.readListEnd(); } @@ -307,12 +307,12 @@ public void write(TProtocol oprot) throws TException { this.space.write(oprot); oprot.writeFieldEnd(); } - if (this.info != null) { - oprot.writeFieldBegin(INFO_FIELD_DESC); + if (this.host_backups != null) { + oprot.writeFieldBegin(HOST_BACKUPS_FIELD_DESC); { - oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (BackupInfo _iter255 : this.info) { - _iter255.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, this.host_backups.size())); + for (HostBackupInfo _iter259 : this.host_backups) { + _iter259.write(oprot); } oprot.writeListEnd(); } @@ -350,13 +350,13 @@ public String toString(int indent, boolean prettyPrint) { first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); - sb.append("info"); + sb.append("host_backups"); sb.append(space); sb.append(":").append(space); - if (this.getInfo() == null) { + if (this.getHost_backups() == null) { sb.append("null"); } else { - sb.append(TBaseHelper.toString(this.getInfo(), indent + 1, prettyPrint)); + sb.append(TBaseHelper.toString(this.getHost_backups(), indent + 1, prettyPrint)); } first = false; sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); diff --git a/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java b/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java deleted file mode 100644 index 850f16215..000000000 --- a/client/src/main/generated/com/vesoft/nebula/meta/StatisItem.java +++ /dev/null @@ -1,927 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.meta; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class StatisItem implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("StatisItem"); - private static final TField TAG_VERTICES_FIELD_DESC = new TField("tag_vertices", TType.MAP, (short)1); - private static final TField EDGES_FIELD_DESC = new TField("edges", TType.MAP, (short)2); - private static final TField SPACE_VERTICES_FIELD_DESC = new TField("space_vertices", TType.I64, (short)3); - private static final TField SPACE_EDGES_FIELD_DESC = new TField("space_edges", TType.I64, (short)4); - private static final TField POSITIVE_PART_CORRELATIVITY_FIELD_DESC = new TField("positive_part_correlativity", TType.MAP, (short)5); - private static final TField NEGATIVE_PART_CORRELATIVITY_FIELD_DESC = new TField("negative_part_correlativity", TType.MAP, (short)6); - private static final TField STATUS_FIELD_DESC = new TField("status", TType.I32, (short)7); - - public Map tag_vertices; - public Map edges; - public long space_vertices; - public long space_edges; - public Map> positive_part_correlativity; - public Map> negative_part_correlativity; - /** - * - * @see JobStatus - */ - public JobStatus status; - public static final int TAG_VERTICES = 1; - public static final int EDGES = 2; - public static final int SPACE_VERTICES = 3; - public static final int SPACE_EDGES = 4; - public static final int POSITIVE_PART_CORRELATIVITY = 5; - public static final int NEGATIVE_PART_CORRELATIVITY = 6; - public static final int STATUS = 7; - - // isset id assignments - private static final int __SPACE_VERTICES_ISSET_ID = 0; - private static final int __SPACE_EDGES_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(TAG_VERTICES, new FieldMetaData("tag_vertices", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.STRING), - new FieldValueMetaData(TType.I64)))); - tmpMetaDataMap.put(EDGES, new FieldMetaData("edges", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.STRING), - new FieldValueMetaData(TType.I64)))); - tmpMetaDataMap.put(SPACE_VERTICES, new FieldMetaData("space_vertices", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(SPACE_EDGES, new FieldMetaData("space_edges", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I64))); - tmpMetaDataMap.put(POSITIVE_PART_CORRELATIVITY, new FieldMetaData("positive_part_correlativity", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I32), - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Correlativity.class))))); - tmpMetaDataMap.put(NEGATIVE_PART_CORRELATIVITY, new FieldMetaData("negative_part_correlativity", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I32), - new ListMetaData(TType.LIST, - new StructMetaData(TType.STRUCT, Correlativity.class))))); - tmpMetaDataMap.put(STATUS, new FieldMetaData("status", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(StatisItem.class, metaDataMap); - } - - public StatisItem() { - } - - public StatisItem( - Map tag_vertices, - Map edges, - long space_vertices, - long space_edges, - Map> positive_part_correlativity, - Map> negative_part_correlativity, - JobStatus status) { - this(); - this.tag_vertices = tag_vertices; - this.edges = edges; - this.space_vertices = space_vertices; - setSpace_verticesIsSet(true); - this.space_edges = space_edges; - setSpace_edgesIsSet(true); - this.positive_part_correlativity = positive_part_correlativity; - this.negative_part_correlativity = negative_part_correlativity; - this.status = status; - } - - public static class Builder { - private Map tag_vertices; - private Map edges; - private long space_vertices; - private long space_edges; - private Map> positive_part_correlativity; - private Map> negative_part_correlativity; - private JobStatus status; - - BitSet __optional_isset = new BitSet(2); - - public Builder() { - } - - public Builder setTag_vertices(final Map tag_vertices) { - this.tag_vertices = tag_vertices; - return this; - } - - public Builder setEdges(final Map edges) { - this.edges = edges; - return this; - } - - public Builder setSpace_vertices(final long space_vertices) { - this.space_vertices = space_vertices; - __optional_isset.set(__SPACE_VERTICES_ISSET_ID, true); - return this; - } - - public Builder setSpace_edges(final long space_edges) { - this.space_edges = space_edges; - __optional_isset.set(__SPACE_EDGES_ISSET_ID, true); - return this; - } - - public Builder setPositive_part_correlativity(final Map> positive_part_correlativity) { - this.positive_part_correlativity = positive_part_correlativity; - return this; - } - - public Builder setNegative_part_correlativity(final Map> negative_part_correlativity) { - this.negative_part_correlativity = negative_part_correlativity; - return this; - } - - public Builder setStatus(final JobStatus status) { - this.status = status; - return this; - } - - public StatisItem build() { - StatisItem result = new StatisItem(); - result.setTag_vertices(this.tag_vertices); - result.setEdges(this.edges); - if (__optional_isset.get(__SPACE_VERTICES_ISSET_ID)) { - result.setSpace_vertices(this.space_vertices); - } - if (__optional_isset.get(__SPACE_EDGES_ISSET_ID)) { - result.setSpace_edges(this.space_edges); - } - result.setPositive_part_correlativity(this.positive_part_correlativity); - result.setNegative_part_correlativity(this.negative_part_correlativity); - result.setStatus(this.status); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public StatisItem(StatisItem other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - if (other.isSetTag_vertices()) { - this.tag_vertices = TBaseHelper.deepCopy(other.tag_vertices); - } - if (other.isSetEdges()) { - this.edges = TBaseHelper.deepCopy(other.edges); - } - this.space_vertices = TBaseHelper.deepCopy(other.space_vertices); - this.space_edges = TBaseHelper.deepCopy(other.space_edges); - if (other.isSetPositive_part_correlativity()) { - this.positive_part_correlativity = TBaseHelper.deepCopy(other.positive_part_correlativity); - } - if (other.isSetNegative_part_correlativity()) { - this.negative_part_correlativity = TBaseHelper.deepCopy(other.negative_part_correlativity); - } - if (other.isSetStatus()) { - this.status = TBaseHelper.deepCopy(other.status); - } - } - - public StatisItem deepCopy() { - return new StatisItem(this); - } - - public Map getTag_vertices() { - return this.tag_vertices; - } - - public StatisItem setTag_vertices(Map tag_vertices) { - this.tag_vertices = tag_vertices; - return this; - } - - public void unsetTag_vertices() { - this.tag_vertices = null; - } - - // Returns true if field tag_vertices is set (has been assigned a value) and false otherwise - public boolean isSetTag_vertices() { - return this.tag_vertices != null; - } - - public void setTag_verticesIsSet(boolean __value) { - if (!__value) { - this.tag_vertices = null; - } - } - - public Map getEdges() { - return this.edges; - } - - public StatisItem setEdges(Map edges) { - this.edges = edges; - return this; - } - - public void unsetEdges() { - this.edges = null; - } - - // Returns true if field edges is set (has been assigned a value) and false otherwise - public boolean isSetEdges() { - return this.edges != null; - } - - public void setEdgesIsSet(boolean __value) { - if (!__value) { - this.edges = null; - } - } - - public long getSpace_vertices() { - return this.space_vertices; - } - - public StatisItem setSpace_vertices(long space_vertices) { - this.space_vertices = space_vertices; - setSpace_verticesIsSet(true); - return this; - } - - public void unsetSpace_vertices() { - __isset_bit_vector.clear(__SPACE_VERTICES_ISSET_ID); - } - - // Returns true if field space_vertices is set (has been assigned a value) and false otherwise - public boolean isSetSpace_vertices() { - return __isset_bit_vector.get(__SPACE_VERTICES_ISSET_ID); - } - - public void setSpace_verticesIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_VERTICES_ISSET_ID, __value); - } - - public long getSpace_edges() { - return this.space_edges; - } - - public StatisItem setSpace_edges(long space_edges) { - this.space_edges = space_edges; - setSpace_edgesIsSet(true); - return this; - } - - public void unsetSpace_edges() { - __isset_bit_vector.clear(__SPACE_EDGES_ISSET_ID); - } - - // Returns true if field space_edges is set (has been assigned a value) and false otherwise - public boolean isSetSpace_edges() { - return __isset_bit_vector.get(__SPACE_EDGES_ISSET_ID); - } - - public void setSpace_edgesIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_EDGES_ISSET_ID, __value); - } - - public Map> getPositive_part_correlativity() { - return this.positive_part_correlativity; - } - - public StatisItem setPositive_part_correlativity(Map> positive_part_correlativity) { - this.positive_part_correlativity = positive_part_correlativity; - return this; - } - - public void unsetPositive_part_correlativity() { - this.positive_part_correlativity = null; - } - - // Returns true if field positive_part_correlativity is set (has been assigned a value) and false otherwise - public boolean isSetPositive_part_correlativity() { - return this.positive_part_correlativity != null; - } - - public void setPositive_part_correlativityIsSet(boolean __value) { - if (!__value) { - this.positive_part_correlativity = null; - } - } - - public Map> getNegative_part_correlativity() { - return this.negative_part_correlativity; - } - - public StatisItem setNegative_part_correlativity(Map> negative_part_correlativity) { - this.negative_part_correlativity = negative_part_correlativity; - return this; - } - - public void unsetNegative_part_correlativity() { - this.negative_part_correlativity = null; - } - - // Returns true if field negative_part_correlativity is set (has been assigned a value) and false otherwise - public boolean isSetNegative_part_correlativity() { - return this.negative_part_correlativity != null; - } - - public void setNegative_part_correlativityIsSet(boolean __value) { - if (!__value) { - this.negative_part_correlativity = null; - } - } - - /** - * - * @see JobStatus - */ - public JobStatus getStatus() { - return this.status; - } - - /** - * - * @see JobStatus - */ - public StatisItem setStatus(JobStatus status) { - this.status = status; - return this; - } - - public void unsetStatus() { - this.status = null; - } - - // Returns true if field status is set (has been assigned a value) and false otherwise - public boolean isSetStatus() { - return this.status != null; - } - - public void setStatusIsSet(boolean __value) { - if (!__value) { - this.status = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case TAG_VERTICES: - if (__value == null) { - unsetTag_vertices(); - } else { - setTag_vertices((Map)__value); - } - break; - - case EDGES: - if (__value == null) { - unsetEdges(); - } else { - setEdges((Map)__value); - } - break; - - case SPACE_VERTICES: - if (__value == null) { - unsetSpace_vertices(); - } else { - setSpace_vertices((Long)__value); - } - break; - - case SPACE_EDGES: - if (__value == null) { - unsetSpace_edges(); - } else { - setSpace_edges((Long)__value); - } - break; - - case POSITIVE_PART_CORRELATIVITY: - if (__value == null) { - unsetPositive_part_correlativity(); - } else { - setPositive_part_correlativity((Map>)__value); - } - break; - - case NEGATIVE_PART_CORRELATIVITY: - if (__value == null) { - unsetNegative_part_correlativity(); - } else { - setNegative_part_correlativity((Map>)__value); - } - break; - - case STATUS: - if (__value == null) { - unsetStatus(); - } else { - setStatus((JobStatus)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case TAG_VERTICES: - return getTag_vertices(); - - case EDGES: - return getEdges(); - - case SPACE_VERTICES: - return new Long(getSpace_vertices()); - - case SPACE_EDGES: - return new Long(getSpace_edges()); - - case POSITIVE_PART_CORRELATIVITY: - return getPositive_part_correlativity(); - - case NEGATIVE_PART_CORRELATIVITY: - return getNegative_part_correlativity(); - - case STATUS: - return getStatus(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof StatisItem)) - return false; - StatisItem that = (StatisItem)_that; - - if (!TBaseHelper.equalsSlow(this.isSetTag_vertices(), that.isSetTag_vertices(), this.tag_vertices, that.tag_vertices)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetEdges(), that.isSetEdges(), this.edges, that.edges)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.space_vertices, that.space_vertices)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.space_edges, that.space_edges)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetPositive_part_correlativity(), that.isSetPositive_part_correlativity(), this.positive_part_correlativity, that.positive_part_correlativity)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetNegative_part_correlativity(), that.isSetNegative_part_correlativity(), this.negative_part_correlativity, that.negative_part_correlativity)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetStatus(), that.isSetStatus(), this.status, that.status)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {tag_vertices, edges, space_vertices, space_edges, positive_part_correlativity, negative_part_correlativity, status}); - } - - @Override - public int compareTo(StatisItem other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetTag_vertices()).compareTo(other.isSetTag_vertices()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(tag_vertices, other.tag_vertices); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetEdges()).compareTo(other.isSetEdges()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(edges, other.edges); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetSpace_vertices()).compareTo(other.isSetSpace_vertices()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_vertices, other.space_vertices); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetSpace_edges()).compareTo(other.isSetSpace_edges()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_edges, other.space_edges); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetPositive_part_correlativity()).compareTo(other.isSetPositive_part_correlativity()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(positive_part_correlativity, other.positive_part_correlativity); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetNegative_part_correlativity()).compareTo(other.isSetNegative_part_correlativity()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(negative_part_correlativity, other.negative_part_correlativity); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(status, other.status); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case TAG_VERTICES: - if (__field.type == TType.MAP) { - { - TMap _map42 = iprot.readMapBegin(); - this.tag_vertices = new HashMap(Math.max(0, 2*_map42.size)); - for (int _i43 = 0; - (_map42.size < 0) ? iprot.peekMap() : (_i43 < _map42.size); - ++_i43) - { - byte[] _key44; - long _val45; - _key44 = iprot.readBinary(); - _val45 = iprot.readI64(); - this.tag_vertices.put(_key44, _val45); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case EDGES: - if (__field.type == TType.MAP) { - { - TMap _map46 = iprot.readMapBegin(); - this.edges = new HashMap(Math.max(0, 2*_map46.size)); - for (int _i47 = 0; - (_map46.size < 0) ? iprot.peekMap() : (_i47 < _map46.size); - ++_i47) - { - byte[] _key48; - long _val49; - _key48 = iprot.readBinary(); - _val49 = iprot.readI64(); - this.edges.put(_key48, _val49); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SPACE_VERTICES: - if (__field.type == TType.I64) { - this.space_vertices = iprot.readI64(); - setSpace_verticesIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case SPACE_EDGES: - if (__field.type == TType.I64) { - this.space_edges = iprot.readI64(); - setSpace_edgesIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case POSITIVE_PART_CORRELATIVITY: - if (__field.type == TType.MAP) { - { - TMap _map50 = iprot.readMapBegin(); - this.positive_part_correlativity = new HashMap>(Math.max(0, 2*_map50.size)); - for (int _i51 = 0; - (_map50.size < 0) ? iprot.peekMap() : (_i51 < _map50.size); - ++_i51) - { - int _key52; - List _val53; - _key52 = iprot.readI32(); - { - TList _list54 = iprot.readListBegin(); - _val53 = new ArrayList(Math.max(0, _list54.size)); - for (int _i55 = 0; - (_list54.size < 0) ? iprot.peekList() : (_i55 < _list54.size); - ++_i55) - { - Correlativity _elem56; - _elem56 = new Correlativity(); - _elem56.read(iprot); - _val53.add(_elem56); - } - iprot.readListEnd(); - } - this.positive_part_correlativity.put(_key52, _val53); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case NEGATIVE_PART_CORRELATIVITY: - if (__field.type == TType.MAP) { - { - TMap _map57 = iprot.readMapBegin(); - this.negative_part_correlativity = new HashMap>(Math.max(0, 2*_map57.size)); - for (int _i58 = 0; - (_map57.size < 0) ? iprot.peekMap() : (_i58 < _map57.size); - ++_i58) - { - int _key59; - List _val60; - _key59 = iprot.readI32(); - { - TList _list61 = iprot.readListBegin(); - _val60 = new ArrayList(Math.max(0, _list61.size)); - for (int _i62 = 0; - (_list61.size < 0) ? iprot.peekList() : (_i62 < _list61.size); - ++_i62) - { - Correlativity _elem63; - _elem63 = new Correlativity(); - _elem63.read(iprot); - _val60.add(_elem63); - } - iprot.readListEnd(); - } - this.negative_part_correlativity.put(_key59, _val60); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case STATUS: - if (__field.type == TType.I32) { - this.status = JobStatus.findByValue(iprot.readI32()); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.tag_vertices != null) { - oprot.writeFieldBegin(TAG_VERTICES_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.tag_vertices.size())); - for (Map.Entry _iter64 : this.tag_vertices.entrySet()) { - oprot.writeBinary(_iter64.getKey()); - oprot.writeI64(_iter64.getValue()); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - if (this.edges != null) { - oprot.writeFieldBegin(EDGES_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.edges.size())); - for (Map.Entry _iter65 : this.edges.entrySet()) { - oprot.writeBinary(_iter65.getKey()); - oprot.writeI64(_iter65.getValue()); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(SPACE_VERTICES_FIELD_DESC); - oprot.writeI64(this.space_vertices); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(SPACE_EDGES_FIELD_DESC); - oprot.writeI64(this.space_edges); - oprot.writeFieldEnd(); - if (this.positive_part_correlativity != null) { - oprot.writeFieldBegin(POSITIVE_PART_CORRELATIVITY_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.positive_part_correlativity.size())); - for (Map.Entry> _iter66 : this.positive_part_correlativity.entrySet()) { - oprot.writeI32(_iter66.getKey()); - { - oprot.writeListBegin(new TList(TType.STRUCT, _iter66.getValue().size())); - for (Correlativity _iter67 : _iter66.getValue()) { - _iter67.write(oprot); - } - oprot.writeListEnd(); - } - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - if (this.negative_part_correlativity != null) { - oprot.writeFieldBegin(NEGATIVE_PART_CORRELATIVITY_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.negative_part_correlativity.size())); - for (Map.Entry> _iter68 : this.negative_part_correlativity.entrySet()) { - oprot.writeI32(_iter68.getKey()); - { - oprot.writeListBegin(new TList(TType.STRUCT, _iter68.getValue().size())); - for (Correlativity _iter69 : _iter68.getValue()) { - _iter69.write(oprot); - } - oprot.writeListEnd(); - } - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - if (this.status != null) { - oprot.writeFieldBegin(STATUS_FIELD_DESC); - oprot.writeI32(this.status == null ? 0 : this.status.getValue()); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("StatisItem"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("tag_vertices"); - sb.append(space); - sb.append(":").append(space); - if (this.getTag_vertices() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getTag_vertices(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("edges"); - sb.append(space); - sb.append(":").append(space); - if (this.getEdges() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getEdges(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("space_vertices"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_vertices(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("space_edges"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_edges(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("positive_part_correlativity"); - sb.append(space); - sb.append(":").append(space); - if (this.getPositive_part_correlativity() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getPositive_part_correlativity(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("negative_part_correlativity"); - sb.append(space); - sb.append(":").append(space); - if (this.getNegative_part_correlativity() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getNegative_part_correlativity(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("status"); - sb.append(space); - sb.append(":").append(space); - if (this.getStatus() == null) { - sb.append("null"); - } else { - String status_name = this.getStatus() == null ? "null" : this.getStatus().name(); - if (status_name != null) { - sb.append(status_name); - sb.append(" ("); - } - sb.append(this.getStatus()); - if (status_name != null) { - sb.append(")"); - } - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java index 53d108957..6b5e25131 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsReq.java @@ -175,16 +175,16 @@ public void read(TProtocol iprot) throws TException { case SESSIONS: if (__field.type == TType.LIST) { { - TList _list304 = iprot.readListBegin(); - this.sessions = new ArrayList(Math.max(0, _list304.size)); - for (int _i305 = 0; - (_list304.size < 0) ? iprot.peekList() : (_i305 < _list304.size); - ++_i305) + TList _list308 = iprot.readListBegin(); + this.sessions = new ArrayList(Math.max(0, _list308.size)); + for (int _i309 = 0; + (_list308.size < 0) ? iprot.peekList() : (_i309 < _list308.size); + ++_i309) { - Session _elem306; - _elem306 = new Session(); - _elem306.read(iprot); - this.sessions.add(_elem306); + Session _elem310; + _elem310 = new Session(); + _elem310.read(iprot); + this.sessions.add(_elem310); } iprot.readListEnd(); } @@ -213,8 +213,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(SESSIONS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.sessions.size())); - for (Session _iter307 : this.sessions) { - _iter307.write(oprot); + for (Session _iter311 : this.sessions) { + _iter311.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java index f39ae4113..fb74f8e51 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/UpdateSessionsResp.java @@ -352,32 +352,32 @@ public void read(TProtocol iprot) throws TException { case KILLED_QUERIES: if (__field.type == TType.MAP) { { - TMap _map308 = iprot.readMapBegin(); - this.killed_queries = new HashMap>(Math.max(0, 2*_map308.size)); - for (int _i309 = 0; - (_map308.size < 0) ? iprot.peekMap() : (_i309 < _map308.size); - ++_i309) + TMap _map312 = iprot.readMapBegin(); + this.killed_queries = new HashMap>(Math.max(0, 2*_map312.size)); + for (int _i313 = 0; + (_map312.size < 0) ? iprot.peekMap() : (_i313 < _map312.size); + ++_i313) { - long _key310; - Map _val311; - _key310 = iprot.readI64(); + long _key314; + Map _val315; + _key314 = iprot.readI64(); { - TMap _map312 = iprot.readMapBegin(); - _val311 = new HashMap(Math.max(0, 2*_map312.size)); - for (int _i313 = 0; - (_map312.size < 0) ? iprot.peekMap() : (_i313 < _map312.size); - ++_i313) + TMap _map316 = iprot.readMapBegin(); + _val315 = new HashMap(Math.max(0, 2*_map316.size)); + for (int _i317 = 0; + (_map316.size < 0) ? iprot.peekMap() : (_i317 < _map316.size); + ++_i317) { - long _key314; - QueryDesc _val315; - _key314 = iprot.readI64(); - _val315 = new QueryDesc(); - _val315.read(iprot); - _val311.put(_key314, _val315); + long _key318; + QueryDesc _val319; + _key318 = iprot.readI64(); + _val319 = new QueryDesc(); + _val319.read(iprot); + _val315.put(_key318, _val319); } iprot.readMapEnd(); } - this.killed_queries.put(_key310, _val311); + this.killed_queries.put(_key314, _val315); } iprot.readMapEnd(); } @@ -416,13 +416,13 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(KILLED_QUERIES_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I64, TType.MAP, this.killed_queries.size())); - for (Map.Entry> _iter316 : this.killed_queries.entrySet()) { - oprot.writeI64(_iter316.getKey()); + for (Map.Entry> _iter320 : this.killed_queries.entrySet()) { + oprot.writeI64(_iter320.getKey()); { - oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter316.getValue().size())); - for (Map.Entry _iter317 : _iter316.getValue().entrySet()) { - oprot.writeI64(_iter317.getKey()); - _iter317.getValue().write(oprot); + oprot.writeMapBegin(new TMap(TType.I64, TType.STRUCT, _iter320.getValue().size())); + for (Map.Entry _iter321 : _iter320.getValue().entrySet()) { + oprot.writeI64(_iter321.getKey()); + _iter321.getValue().write(oprot); } oprot.writeMapEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java index f221c07af..79cb6dc9d 100644 --- a/client/src/main/generated/com/vesoft/nebula/meta/Zone.java +++ b/client/src/main/generated/com/vesoft/nebula/meta/Zone.java @@ -267,16 +267,16 @@ public void read(TProtocol iprot) throws TException { case NODES: if (__field.type == TType.LIST) { { - TList _list232 = iprot.readListBegin(); - this.nodes = new ArrayList(Math.max(0, _list232.size)); - for (int _i233 = 0; - (_list232.size < 0) ? iprot.peekList() : (_i233 < _list232.size); - ++_i233) + TList _list236 = iprot.readListBegin(); + this.nodes = new ArrayList(Math.max(0, _list236.size)); + for (int _i237 = 0; + (_list236.size < 0) ? iprot.peekList() : (_i237 < _list236.size); + ++_i237) { - com.vesoft.nebula.HostAddr _elem234; - _elem234 = new com.vesoft.nebula.HostAddr(); - _elem234.read(iprot); - this.nodes.add(_elem234); + com.vesoft.nebula.HostAddr _elem238; + _elem238 = new com.vesoft.nebula.HostAddr(); + _elem238.read(iprot); + this.nodes.add(_elem238); } iprot.readListEnd(); } @@ -310,8 +310,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(NODES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.nodes.size())); - for (com.vesoft.nebula.HostAddr _iter235 : this.nodes) { - _iter235.write(oprot); + for (com.vesoft.nebula.HostAddr _iter239 : this.nodes) { + _iter239.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/BlockingSignRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/BlockingSignRequest.java index 08acac096..2025b5fdd 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/BlockingSignRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/BlockingSignRequest.java @@ -26,28 +26,27 @@ @SuppressWarnings({ "unused", "serial" }) public class BlockingSignRequest implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("BlockingSignRequest"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField SPACE_IDS_FIELD_DESC = new TField("space_ids", TType.LIST, (short)1); private static final TField SIGN_FIELD_DESC = new TField("sign", TType.I32, (short)2); - public int space_id; + public List space_ids; /** * * @see EngineSignType */ public EngineSignType sign; - public static final int SPACE_ID = 1; + public static final int SPACE_IDS = 1; public static final int SIGN = 2; // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(SPACE_IDS, new FieldMetaData("space_ids", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.I32)))); tmpMetaDataMap.put(SIGN, new FieldMetaData("sign", TFieldRequirementType.REQUIRED, new FieldValueMetaData(TType.I32))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -67,26 +66,22 @@ public BlockingSignRequest( } public BlockingSignRequest( - int space_id, + List space_ids, EngineSignType sign) { this(); - this.space_id = space_id; - setSpace_idIsSet(true); + this.space_ids = space_ids; this.sign = sign; } public static class Builder { - private int space_id; + private List space_ids; private EngineSignType sign; - BitSet __optional_isset = new BitSet(1); - public Builder() { } - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); + public Builder setSpace_ids(final List space_ids) { + this.space_ids = space_ids; return this; } @@ -97,9 +92,7 @@ public Builder setSign(final EngineSignType sign) { public BlockingSignRequest build() { BlockingSignRequest result = new BlockingSignRequest(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } + result.setSpace_ids(this.space_ids); result.setSign(this.sign); return result; } @@ -113,9 +106,9 @@ public static Builder builder() { * Performs a deep copy on other. */ public BlockingSignRequest(BlockingSignRequest other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetSpace_ids()) { + this.space_ids = TBaseHelper.deepCopy(other.space_ids); + } if (other.isSetSign()) { this.sign = TBaseHelper.deepCopy(other.sign); } @@ -125,27 +118,28 @@ public BlockingSignRequest deepCopy() { return new BlockingSignRequest(this); } - public int getSpace_id() { - return this.space_id; + public List getSpace_ids() { + return this.space_ids; } - public BlockingSignRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); + public BlockingSignRequest setSpace_ids(List space_ids) { + this.space_ids = space_ids; return this; } - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + public void unsetSpace_ids() { + this.space_ids = null; } - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + // Returns true if field space_ids is set (has been assigned a value) and false otherwise + public boolean isSetSpace_ids() { + return this.space_ids != null; } - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + public void setSpace_idsIsSet(boolean __value) { + if (!__value) { + this.space_ids = null; + } } /** @@ -180,13 +174,14 @@ public void setSignIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case SPACE_ID: + case SPACE_IDS: if (__value == null) { - unsetSpace_id(); + unsetSpace_ids(); } else { - setSpace_id((Integer)__value); + setSpace_ids((List)__value); } break; @@ -205,8 +200,8 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); + case SPACE_IDS: + return getSpace_ids(); case SIGN: return getSign(); @@ -226,7 +221,7 @@ public boolean equals(Object _that) { return false; BlockingSignRequest that = (BlockingSignRequest)_that; - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetSpace_ids(), that.isSetSpace_ids(), this.space_ids, that.space_ids)) { return false; } if (!TBaseHelper.equalsNobinary(this.isSetSign(), that.isSetSign(), this.sign, that.sign)) { return false; } @@ -235,7 +230,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, sign}); + return Arrays.deepHashCode(new Object[] {space_ids, sign}); } @Override @@ -250,11 +245,11 @@ public int compareTo(BlockingSignRequest other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + lastComparison = Boolean.valueOf(isSetSpace_ids()).compareTo(other.isSetSpace_ids()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + lastComparison = TBaseHelper.compareTo(space_ids, other.space_ids); if (lastComparison != 0) { return lastComparison; } @@ -280,10 +275,21 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); + case SPACE_IDS: + if (__field.type == TType.LIST) { + { + TList _list264 = iprot.readListBegin(); + this.space_ids = new ArrayList(Math.max(0, _list264.size)); + for (int _i265 = 0; + (_list264.size < 0) ? iprot.peekList() : (_i265 < _list264.size); + ++_i265) + { + int _elem266; + _elem266 = iprot.readI32(); + this.space_ids.add(_elem266); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -312,9 +318,17 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); + if (this.space_ids != null) { + oprot.writeFieldBegin(SPACE_IDS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.I32, this.space_ids.size())); + for (int _iter267 : this.space_ids) { + oprot.writeI32(_iter267); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } if (this.sign != null) { oprot.writeFieldBegin(SIGN_FIELD_DESC); oprot.writeI32(this.sign == null ? 0 : this.sign.getValue()); @@ -341,10 +355,14 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("space_id"); + sb.append("space_ids"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + if (this.getSpace_ids() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSpace_ids(), indent + 1, prettyPrint)); + } first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java index 35d79c774..69fc61b04 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainAddEdgesRequest.java @@ -486,30 +486,30 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.MAP) { { - TMap _map291 = iprot.readMapBegin(); - this.parts = new HashMap>(Math.max(0, 2*_map291.size)); - for (int _i292 = 0; - (_map291.size < 0) ? iprot.peekMap() : (_i292 < _map291.size); - ++_i292) + TMap _map303 = iprot.readMapBegin(); + this.parts = new HashMap>(Math.max(0, 2*_map303.size)); + for (int _i304 = 0; + (_map303.size < 0) ? iprot.peekMap() : (_i304 < _map303.size); + ++_i304) { - int _key293; - List _val294; - _key293 = iprot.readI32(); + int _key305; + List _val306; + _key305 = iprot.readI32(); { - TList _list295 = iprot.readListBegin(); - _val294 = new ArrayList(Math.max(0, _list295.size)); - for (int _i296 = 0; - (_list295.size < 0) ? iprot.peekList() : (_i296 < _list295.size); - ++_i296) + TList _list307 = iprot.readListBegin(); + _val306 = new ArrayList(Math.max(0, _list307.size)); + for (int _i308 = 0; + (_list307.size < 0) ? iprot.peekList() : (_i308 < _list307.size); + ++_i308) { - NewEdge _elem297; - _elem297 = new NewEdge(); - _elem297.read(iprot); - _val294.add(_elem297); + NewEdge _elem309; + _elem309 = new NewEdge(); + _elem309.read(iprot); + _val306.add(_elem309); } iprot.readListEnd(); } - this.parts.put(_key293, _val294); + this.parts.put(_key305, _val306); } iprot.readMapEnd(); } @@ -520,15 +520,15 @@ public void read(TProtocol iprot) throws TException { case PROP_NAMES: if (__field.type == TType.LIST) { { - TList _list298 = iprot.readListBegin(); - this.prop_names = new ArrayList(Math.max(0, _list298.size)); - for (int _i299 = 0; - (_list298.size < 0) ? iprot.peekList() : (_i299 < _list298.size); - ++_i299) + TList _list310 = iprot.readListBegin(); + this.prop_names = new ArrayList(Math.max(0, _list310.size)); + for (int _i311 = 0; + (_list310.size < 0) ? iprot.peekList() : (_i311 < _list310.size); + ++_i311) { - byte[] _elem300; - _elem300 = iprot.readBinary(); - this.prop_names.add(_elem300); + byte[] _elem312; + _elem312 = iprot.readBinary(); + this.prop_names.add(_elem312); } iprot.readListEnd(); } @@ -584,12 +584,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.parts.size())); - for (Map.Entry> _iter301 : this.parts.entrySet()) { - oprot.writeI32(_iter301.getKey()); + for (Map.Entry> _iter313 : this.parts.entrySet()) { + oprot.writeI32(_iter313.getKey()); { - oprot.writeListBegin(new TList(TType.STRUCT, _iter301.getValue().size())); - for (NewEdge _iter302 : _iter301.getValue()) { - _iter302.write(oprot); + oprot.writeListBegin(new TList(TType.STRUCT, _iter313.getValue().size())); + for (NewEdge _iter314 : _iter313.getValue()) { + _iter314.write(oprot); } oprot.writeListEnd(); } @@ -602,8 +602,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PROP_NAMES_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRING, this.prop_names.size())); - for (byte[] _iter303 : this.prop_names) { - oprot.writeBinary(_iter303); + for (byte[] _iter315 : this.prop_names) { + oprot.writeBinary(_iter315); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java index b02f2c92b..59e1faf9c 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/ChainUpdateEdgeRequest.java @@ -454,15 +454,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list304 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list304.size)); - for (int _i305 = 0; - (_list304.size < 0) ? iprot.peekList() : (_i305 < _list304.size); - ++_i305) + TList _list316 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list316.size)); + for (int _i317 = 0; + (_list316.size < 0) ? iprot.peekList() : (_i317 < _list316.size); + ++_i317) { - int _elem306; - _elem306 = iprot.readI32(); - this.parts.add(_elem306); + int _elem318; + _elem318 = iprot.readI32(); + this.parts.add(_elem318); } iprot.readListEnd(); } @@ -507,8 +507,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter307 : this.parts) { - oprot.writeI32(_iter307); + for (int _iter319 : this.parts) { + oprot.writeI32(_iter319); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java index 9cb193b9b..7f045d702 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CheckPeersReq.java @@ -347,16 +347,16 @@ public void read(TProtocol iprot) throws TException { case PEERS: if (__field.type == TType.LIST) { { - TList _list265 = iprot.readListBegin(); - this.peers = new ArrayList(Math.max(0, _list265.size)); - for (int _i266 = 0; - (_list265.size < 0) ? iprot.peekList() : (_i266 < _list265.size); - ++_i266) + TList _list277 = iprot.readListBegin(); + this.peers = new ArrayList(Math.max(0, _list277.size)); + for (int _i278 = 0; + (_list277.size < 0) ? iprot.peekList() : (_i278 < _list277.size); + ++_i278) { - com.vesoft.nebula.HostAddr _elem267; - _elem267 = new com.vesoft.nebula.HostAddr(); - _elem267.read(iprot); - this.peers.add(_elem267); + com.vesoft.nebula.HostAddr _elem279; + _elem279 = new com.vesoft.nebula.HostAddr(); + _elem279.read(iprot); + this.peers.add(_elem279); } iprot.readListEnd(); } @@ -391,8 +391,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PEERS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.peers.size())); - for (com.vesoft.nebula.HostAddr _iter268 : this.peers) { - _iter268.write(oprot); + for (com.vesoft.nebula.HostAddr _iter280 : this.peers) { + _iter280.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPRequest.java index 2fa3f399d..527116345 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPRequest.java @@ -26,24 +26,23 @@ @SuppressWarnings({ "unused", "serial" }) public class CreateCPRequest implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("CreateCPRequest"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField SPACE_IDS_FIELD_DESC = new TField("space_ids", TType.LIST, (short)1); private static final TField NAME_FIELD_DESC = new TField("name", TType.STRING, (short)2); - public int space_id; + public List space_ids; public byte[] name; - public static final int SPACE_ID = 1; + public static final int SPACE_IDS = 1; public static final int NAME = 2; // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(SPACE_IDS, new FieldMetaData("space_ids", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.I32)))); tmpMetaDataMap.put(NAME, new FieldMetaData("name", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -57,26 +56,22 @@ public CreateCPRequest() { } public CreateCPRequest( - int space_id, + List space_ids, byte[] name) { this(); - this.space_id = space_id; - setSpace_idIsSet(true); + this.space_ids = space_ids; this.name = name; } public static class Builder { - private int space_id; + private List space_ids; private byte[] name; - BitSet __optional_isset = new BitSet(1); - public Builder() { } - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); + public Builder setSpace_ids(final List space_ids) { + this.space_ids = space_ids; return this; } @@ -87,9 +82,7 @@ public Builder setName(final byte[] name) { public CreateCPRequest build() { CreateCPRequest result = new CreateCPRequest(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } + result.setSpace_ids(this.space_ids); result.setName(this.name); return result; } @@ -103,9 +96,9 @@ public static Builder builder() { * Performs a deep copy on other. */ public CreateCPRequest(CreateCPRequest other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetSpace_ids()) { + this.space_ids = TBaseHelper.deepCopy(other.space_ids); + } if (other.isSetName()) { this.name = TBaseHelper.deepCopy(other.name); } @@ -115,27 +108,28 @@ public CreateCPRequest deepCopy() { return new CreateCPRequest(this); } - public int getSpace_id() { - return this.space_id; + public List getSpace_ids() { + return this.space_ids; } - public CreateCPRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); + public CreateCPRequest setSpace_ids(List space_ids) { + this.space_ids = space_ids; return this; } - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + public void unsetSpace_ids() { + this.space_ids = null; } - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + // Returns true if field space_ids is set (has been assigned a value) and false otherwise + public boolean isSetSpace_ids() { + return this.space_ids != null; } - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + public void setSpace_idsIsSet(boolean __value) { + if (!__value) { + this.space_ids = null; + } } public byte[] getName() { @@ -162,13 +156,14 @@ public void setNameIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case SPACE_ID: + case SPACE_IDS: if (__value == null) { - unsetSpace_id(); + unsetSpace_ids(); } else { - setSpace_id((Integer)__value); + setSpace_ids((List)__value); } break; @@ -187,8 +182,8 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); + case SPACE_IDS: + return getSpace_ids(); case NAME: return getName(); @@ -208,7 +203,7 @@ public boolean equals(Object _that) { return false; CreateCPRequest that = (CreateCPRequest)_that; - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetSpace_ids(), that.isSetSpace_ids(), this.space_ids, that.space_ids)) { return false; } if (!TBaseHelper.equalsSlow(this.isSetName(), that.isSetName(), this.name, that.name)) { return false; } @@ -217,7 +212,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, name}); + return Arrays.deepHashCode(new Object[] {space_ids, name}); } @Override @@ -232,11 +227,11 @@ public int compareTo(CreateCPRequest other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + lastComparison = Boolean.valueOf(isSetSpace_ids()).compareTo(other.isSetSpace_ids()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + lastComparison = TBaseHelper.compareTo(space_ids, other.space_ids); if (lastComparison != 0) { return lastComparison; } @@ -262,10 +257,21 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); + case SPACE_IDS: + if (__field.type == TType.LIST) { + { + TList _list256 = iprot.readListBegin(); + this.space_ids = new ArrayList(Math.max(0, _list256.size)); + for (int _i257 = 0; + (_list256.size < 0) ? iprot.peekList() : (_i257 < _list256.size); + ++_i257) + { + int _elem258; + _elem258 = iprot.readI32(); + this.space_ids.add(_elem258); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -294,9 +300,17 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); + if (this.space_ids != null) { + oprot.writeFieldBegin(SPACE_IDS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.I32, this.space_ids.size())); + for (int _iter259 : this.space_ids) { + oprot.writeI32(_iter259); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } if (this.name != null) { oprot.writeFieldBegin(NAME_FIELD_DESC); oprot.writeBinary(this.name); @@ -323,10 +337,14 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("space_id"); + sb.append("space_ids"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + if (this.getSpace_ids() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSpace_ids(), indent + 1, prettyPrint)); + } first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java index e26defcb8..f2b35a176 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/CreateCPResp.java @@ -274,16 +274,16 @@ public void read(TProtocol iprot) throws TException { case INFO: if (__field.type == TType.LIST) { { - TList _list273 = iprot.readListBegin(); - this.info = new ArrayList(Math.max(0, _list273.size)); - for (int _i274 = 0; - (_list273.size < 0) ? iprot.peekList() : (_i274 < _list273.size); - ++_i274) + TList _list285 = iprot.readListBegin(); + this.info = new ArrayList(Math.max(0, _list285.size)); + for (int _i286 = 0; + (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); + ++_i286) { - com.vesoft.nebula.CheckpointInfo _elem275; - _elem275 = new com.vesoft.nebula.CheckpointInfo(); - _elem275.read(iprot); - this.info.add(_elem275); + com.vesoft.nebula.CheckpointInfo _elem287; + _elem287 = new com.vesoft.nebula.CheckpointInfo(); + _elem287.read(iprot); + this.info.add(_elem287); } iprot.readListEnd(); } @@ -317,8 +317,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(INFO_FIELD_DESC); { oprot.writeListBegin(new TList(TType.STRUCT, this.info.size())); - for (com.vesoft.nebula.CheckpointInfo _iter276 : this.info) { - _iter276.write(oprot); + for (com.vesoft.nebula.CheckpointInfo _iter288 : this.info) { + _iter288.write(oprot); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/DropCPRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/DropCPRequest.java index 5d3b5a938..5edabff28 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/DropCPRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/DropCPRequest.java @@ -26,24 +26,23 @@ @SuppressWarnings({ "unused", "serial" }) public class DropCPRequest implements TBase, java.io.Serializable, Cloneable, Comparable { private static final TStruct STRUCT_DESC = new TStruct("DropCPRequest"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); + private static final TField SPACE_IDS_FIELD_DESC = new TField("space_ids", TType.LIST, (short)1); private static final TField NAME_FIELD_DESC = new TField("name", TType.STRING, (short)2); - public int space_id; + public List space_ids; public byte[] name; - public static final int SPACE_ID = 1; + public static final int SPACE_IDS = 1; public static final int NAME = 2; // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private BitSet __isset_bit_vector = new BitSet(1); public static final Map metaDataMap; static { Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); + tmpMetaDataMap.put(SPACE_IDS, new FieldMetaData("space_ids", TFieldRequirementType.DEFAULT, + new ListMetaData(TType.LIST, + new FieldValueMetaData(TType.I32)))); tmpMetaDataMap.put(NAME, new FieldMetaData("name", TFieldRequirementType.DEFAULT, new FieldValueMetaData(TType.STRING))); metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); @@ -57,26 +56,22 @@ public DropCPRequest() { } public DropCPRequest( - int space_id, + List space_ids, byte[] name) { this(); - this.space_id = space_id; - setSpace_idIsSet(true); + this.space_ids = space_ids; this.name = name; } public static class Builder { - private int space_id; + private List space_ids; private byte[] name; - BitSet __optional_isset = new BitSet(1); - public Builder() { } - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); + public Builder setSpace_ids(final List space_ids) { + this.space_ids = space_ids; return this; } @@ -87,9 +82,7 @@ public Builder setName(final byte[] name) { public DropCPRequest build() { DropCPRequest result = new DropCPRequest(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } + result.setSpace_ids(this.space_ids); result.setName(this.name); return result; } @@ -103,9 +96,9 @@ public static Builder builder() { * Performs a deep copy on other. */ public DropCPRequest(DropCPRequest other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); + if (other.isSetSpace_ids()) { + this.space_ids = TBaseHelper.deepCopy(other.space_ids); + } if (other.isSetName()) { this.name = TBaseHelper.deepCopy(other.name); } @@ -115,27 +108,28 @@ public DropCPRequest deepCopy() { return new DropCPRequest(this); } - public int getSpace_id() { - return this.space_id; + public List getSpace_ids() { + return this.space_ids; } - public DropCPRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); + public DropCPRequest setSpace_ids(List space_ids) { + this.space_ids = space_ids; return this; } - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); + public void unsetSpace_ids() { + this.space_ids = null; } - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); + // Returns true if field space_ids is set (has been assigned a value) and false otherwise + public boolean isSetSpace_ids() { + return this.space_ids != null; } - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); + public void setSpace_idsIsSet(boolean __value) { + if (!__value) { + this.space_ids = null; + } } public byte[] getName() { @@ -162,13 +156,14 @@ public void setNameIsSet(boolean __value) { } } + @SuppressWarnings("unchecked") public void setFieldValue(int fieldID, Object __value) { switch (fieldID) { - case SPACE_ID: + case SPACE_IDS: if (__value == null) { - unsetSpace_id(); + unsetSpace_ids(); } else { - setSpace_id((Integer)__value); + setSpace_ids((List)__value); } break; @@ -187,8 +182,8 @@ public void setFieldValue(int fieldID, Object __value) { public Object getFieldValue(int fieldID) { switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); + case SPACE_IDS: + return getSpace_ids(); case NAME: return getName(); @@ -208,7 +203,7 @@ public boolean equals(Object _that) { return false; DropCPRequest that = (DropCPRequest)_that; - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } + if (!TBaseHelper.equalsNobinary(this.isSetSpace_ids(), that.isSetSpace_ids(), this.space_ids, that.space_ids)) { return false; } if (!TBaseHelper.equalsSlow(this.isSetName(), that.isSetName(), this.name, that.name)) { return false; } @@ -217,7 +212,7 @@ public boolean equals(Object _that) { @Override public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, name}); + return Arrays.deepHashCode(new Object[] {space_ids, name}); } @Override @@ -232,11 +227,11 @@ public int compareTo(DropCPRequest other) { } int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); + lastComparison = Boolean.valueOf(isSetSpace_ids()).compareTo(other.isSetSpace_ids()); if (lastComparison != 0) { return lastComparison; } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); + lastComparison = TBaseHelper.compareTo(space_ids, other.space_ids); if (lastComparison != 0) { return lastComparison; } @@ -262,10 +257,21 @@ public void read(TProtocol iprot) throws TException { } switch (__field.id) { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); + case SPACE_IDS: + if (__field.type == TType.LIST) { + { + TList _list260 = iprot.readListBegin(); + this.space_ids = new ArrayList(Math.max(0, _list260.size)); + for (int _i261 = 0; + (_list260.size < 0) ? iprot.peekList() : (_i261 < _list260.size); + ++_i261) + { + int _elem262; + _elem262 = iprot.readI32(); + this.space_ids.add(_elem262); + } + iprot.readListEnd(); + } } else { TProtocolUtil.skip(iprot, __field.type); } @@ -294,9 +300,17 @@ public void write(TProtocol oprot) throws TException { validate(); oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); + if (this.space_ids != null) { + oprot.writeFieldBegin(SPACE_IDS_FIELD_DESC); + { + oprot.writeListBegin(new TList(TType.I32, this.space_ids.size())); + for (int _iter263 : this.space_ids) { + oprot.writeI32(_iter263); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } if (this.name != null) { oprot.writeFieldBegin(NAME_FIELD_DESC); oprot.writeBinary(this.name); @@ -323,10 +337,14 @@ public String toString(int indent, boolean prettyPrint) { boolean first = true; sb.append(indentStr); - sb.append("space_id"); + sb.append("space_ids"); sb.append(space); sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); + if (this.getSpace_ids() == null) { + sb.append("null"); + } else { + sb.append(TBaseHelper.toString(this.getSpace_ids(), indent + 1, prettyPrint)); + } first = false; if (!first) sb.append("," + newLine); sb.append(indentStr); diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java deleted file mode 100644 index 752c8b08e..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/GeneralStorageService.java +++ /dev/null @@ -1,1743 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GeneralStorageService { - - public interface Iface { - - public KVGetResponse get(KVGetRequest req) throws TException; - - public ExecResponse put(KVPutRequest req) throws TException; - - public ExecResponse remove(KVRemoveRequest req) throws TException; - - } - - public interface AsyncIface { - - public void get(KVGetRequest req, AsyncMethodCallback resultHandler) throws TException; - - public void put(KVPutRequest req, AsyncMethodCallback resultHandler) throws TException; - - public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler) throws TException; - - } - - public static class Client extends EventHandlerBase implements Iface, TClientIf { - public Client(TProtocol prot) - { - this(prot, prot); - } - - public Client(TProtocol iprot, TProtocol oprot) - { - iprot_ = iprot; - oprot_ = oprot; - } - - protected TProtocol iprot_; - protected TProtocol oprot_; - - protected int seqid_; - - @Override - public TProtocol getInputProtocol() - { - return this.iprot_; - } - - @Override - public TProtocol getOutputProtocol() - { - return this.oprot_; - } - - public KVGetResponse get(KVGetRequest req) throws TException - { - ContextStack ctx = getContextStack("GeneralStorageService.get", null); - this.setContextStack(ctx); - send_get(req); - return recv_get(); - } - - public void send_get(KVGetRequest req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "GeneralStorageService.get", null); - oprot_.writeMessageBegin(new TMessage("get", TMessageType.CALL, seqid_)); - get_args args = new get_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "GeneralStorageService.get", args); - return; - } - - public KVGetResponse recv_get() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "GeneralStorageService.get"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - get_result result = new get_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "GeneralStorageService.get", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "get failed: unknown result"); - } - - public ExecResponse put(KVPutRequest req) throws TException - { - ContextStack ctx = getContextStack("GeneralStorageService.put", null); - this.setContextStack(ctx); - send_put(req); - return recv_put(); - } - - public void send_put(KVPutRequest req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "GeneralStorageService.put", null); - oprot_.writeMessageBegin(new TMessage("put", TMessageType.CALL, seqid_)); - put_args args = new put_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "GeneralStorageService.put", args); - return; - } - - public ExecResponse recv_put() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "GeneralStorageService.put"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - put_result result = new put_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "GeneralStorageService.put", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "put failed: unknown result"); - } - - public ExecResponse remove(KVRemoveRequest req) throws TException - { - ContextStack ctx = getContextStack("GeneralStorageService.remove", null); - this.setContextStack(ctx); - send_remove(req); - return recv_remove(); - } - - public void send_remove(KVRemoveRequest req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "GeneralStorageService.remove", null); - oprot_.writeMessageBegin(new TMessage("remove", TMessageType.CALL, seqid_)); - remove_args args = new remove_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "GeneralStorageService.remove", args); - return; - } - - public ExecResponse recv_remove() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "GeneralStorageService.remove"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - remove_result result = new remove_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "GeneralStorageService.remove", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "remove failed: unknown result"); - } - - } - public static class AsyncClient extends TAsyncClient implements AsyncIface { - public static class Factory implements TAsyncClientFactory { - private TAsyncClientManager clientManager; - private TProtocolFactory protocolFactory; - public Factory(TAsyncClientManager clientManager, TProtocolFactory protocolFactory) { - this.clientManager = clientManager; - this.protocolFactory = protocolFactory; - } - public AsyncClient getAsyncClient(TNonblockingTransport transport) { - return new AsyncClient(protocolFactory, clientManager, transport); - } - } - - public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientManager, TNonblockingTransport transport) { - super(protocolFactory, clientManager, transport); - } - - public void get(KVGetRequest req, AsyncMethodCallback resultHandler507) throws TException { - checkReady(); - get_call method_call = new get_call(req, resultHandler507, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class get_call extends TAsyncMethodCall { - private KVGetRequest req; - public get_call(KVGetRequest req, AsyncMethodCallback resultHandler508, TAsyncClient client504, TProtocolFactory protocolFactory505, TNonblockingTransport transport506) throws TException { - super(client504, protocolFactory505, transport506, resultHandler508, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("get", TMessageType.CALL, 0)); - get_args args = new get_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public KVGetResponse getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_get(); - } - } - - public void put(KVPutRequest req, AsyncMethodCallback resultHandler512) throws TException { - checkReady(); - put_call method_call = new put_call(req, resultHandler512, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class put_call extends TAsyncMethodCall { - private KVPutRequest req; - public put_call(KVPutRequest req, AsyncMethodCallback resultHandler513, TAsyncClient client509, TProtocolFactory protocolFactory510, TNonblockingTransport transport511) throws TException { - super(client509, protocolFactory510, transport511, resultHandler513, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("put", TMessageType.CALL, 0)); - put_args args = new put_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResponse getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_put(); - } - } - - public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler517) throws TException { - checkReady(); - remove_call method_call = new remove_call(req, resultHandler517, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class remove_call extends TAsyncMethodCall { - private KVRemoveRequest req; - public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler518, TAsyncClient client514, TProtocolFactory protocolFactory515, TNonblockingTransport transport516) throws TException { - super(client514, protocolFactory515, transport516, resultHandler518, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("remove", TMessageType.CALL, 0)); - remove_args args = new remove_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ExecResponse getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_remove(); - } - } - - } - - public static class Processor implements TProcessor { - private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName()); - public Processor(Iface iface) - { - iface_ = iface; - event_handler_ = new TProcessorEventHandler(); // Empty handler - processMap_.put("get", new get()); - processMap_.put("put", new put()); - processMap_.put("remove", new remove()); - } - - protected static interface ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException; - } - - public void setEventHandler(TProcessorEventHandler handler) { - this.event_handler_ = handler; - } - - private Iface iface_; - protected TProcessorEventHandler event_handler_; - protected final HashMap processMap_ = new HashMap(); - - public boolean process(TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - TMessage msg = iprot.readMessageBegin(); - ProcessFunction fn = processMap_.get(msg.name); - if (fn == null) { - TProtocolUtil.skip(iprot, TType.STRUCT); - iprot.readMessageEnd(); - TApplicationException x = new TApplicationException(TApplicationException.UNKNOWN_METHOD, "Invalid method name: '"+msg.name+"'"); - oprot.writeMessageBegin(new TMessage(msg.name, TMessageType.EXCEPTION, msg.seqid)); - x.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - return true; - } - fn.process(msg.seqid, iprot, oprot, server_ctx); - return true; - } - - private class get implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("GeneralStorageService.get", server_ctx); - get_args args = new get_args(); - event_handler_.preRead(handler_ctx, "GeneralStorageService.get"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "GeneralStorageService.get", args); - get_result result = new get_result(); - result.success = iface_.get(args.req); - event_handler_.preWrite(handler_ctx, "GeneralStorageService.get", result); - oprot.writeMessageBegin(new TMessage("get", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "GeneralStorageService.get", result); - } - - } - - private class put implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("GeneralStorageService.put", server_ctx); - put_args args = new put_args(); - event_handler_.preRead(handler_ctx, "GeneralStorageService.put"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "GeneralStorageService.put", args); - put_result result = new put_result(); - result.success = iface_.put(args.req); - event_handler_.preWrite(handler_ctx, "GeneralStorageService.put", result); - oprot.writeMessageBegin(new TMessage("put", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "GeneralStorageService.put", result); - } - - } - - private class remove implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("GeneralStorageService.remove", server_ctx); - remove_args args = new remove_args(); - event_handler_.preRead(handler_ctx, "GeneralStorageService.remove"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "GeneralStorageService.remove", args); - remove_result result = new remove_result(); - result.success = iface_.remove(args.req); - event_handler_.preWrite(handler_ctx, "GeneralStorageService.remove", result); - oprot.writeMessageBegin(new TMessage("remove", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "GeneralStorageService.remove", result); - } - - } - - } - - public static class get_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("get_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public KVGetRequest req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, KVGetRequest.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(get_args.class, metaDataMap); - } - - public get_args() { - } - - public get_args( - KVGetRequest req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public get_args(get_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public get_args deepCopy() { - return new get_args(this); - } - - public KVGetRequest getReq() { - return this.req; - } - - public get_args setReq(KVGetRequest req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((KVGetRequest)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof get_args)) - return false; - get_args that = (get_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(get_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new KVGetRequest(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("get_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class get_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("get_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public KVGetResponse success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, KVGetResponse.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(get_result.class, metaDataMap); - } - - public get_result() { - } - - public get_result( - KVGetResponse success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public get_result(get_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public get_result deepCopy() { - return new get_result(this); - } - - public KVGetResponse getSuccess() { - return this.success; - } - - public get_result setSuccess(KVGetResponse success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((KVGetResponse)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof get_result)) - return false; - get_result that = (get_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(get_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new KVGetResponse(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("get_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class put_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("put_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public KVPutRequest req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, KVPutRequest.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(put_args.class, metaDataMap); - } - - public put_args() { - } - - public put_args( - KVPutRequest req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public put_args(put_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public put_args deepCopy() { - return new put_args(this); - } - - public KVPutRequest getReq() { - return this.req; - } - - public put_args setReq(KVPutRequest req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((KVPutRequest)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof put_args)) - return false; - put_args that = (put_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(put_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new KVPutRequest(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("put_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class put_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("put_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResponse success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResponse.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(put_result.class, metaDataMap); - } - - public put_result() { - } - - public put_result( - ExecResponse success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public put_result(put_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public put_result deepCopy() { - return new put_result(this); - } - - public ExecResponse getSuccess() { - return this.success; - } - - public put_result setSuccess(ExecResponse success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResponse)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof put_result)) - return false; - put_result that = (put_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(put_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResponse(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("put_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class remove_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("remove_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public KVRemoveRequest req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, KVRemoveRequest.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(remove_args.class, metaDataMap); - } - - public remove_args() { - } - - public remove_args( - KVRemoveRequest req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public remove_args(remove_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public remove_args deepCopy() { - return new remove_args(this); - } - - public KVRemoveRequest getReq() { - return this.req; - } - - public remove_args setReq(KVRemoveRequest req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((KVRemoveRequest)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof remove_args)) - return false; - remove_args that = (remove_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(remove_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new KVRemoveRequest(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("remove_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class remove_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("remove_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ExecResponse success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ExecResponse.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(remove_result.class, metaDataMap); - } - - public remove_result() { - } - - public remove_result( - ExecResponse success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public remove_result(remove_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public remove_result deepCopy() { - return new remove_result(this); - } - - public ExecResponse getSuccess() { - return this.success; - } - - public remove_result setSuccess(ExecResponse success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ExecResponse)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof remove_result)) - return false; - remove_result that = (remove_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(remove_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ExecResponse(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("remove_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - -} diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java index 28e298ee6..aa4c9b533 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GetLeaderPartsResp.java @@ -276,29 +276,29 @@ public void read(TProtocol iprot) throws TException { case LEADER_PARTS: if (__field.type == TType.MAP) { { - TMap _map256 = iprot.readMapBegin(); - this.leader_parts = new HashMap>(Math.max(0, 2*_map256.size)); - for (int _i257 = 0; - (_map256.size < 0) ? iprot.peekMap() : (_i257 < _map256.size); - ++_i257) + TMap _map268 = iprot.readMapBegin(); + this.leader_parts = new HashMap>(Math.max(0, 2*_map268.size)); + for (int _i269 = 0; + (_map268.size < 0) ? iprot.peekMap() : (_i269 < _map268.size); + ++_i269) { - int _key258; - List _val259; - _key258 = iprot.readI32(); + int _key270; + List _val271; + _key270 = iprot.readI32(); { - TList _list260 = iprot.readListBegin(); - _val259 = new ArrayList(Math.max(0, _list260.size)); - for (int _i261 = 0; - (_list260.size < 0) ? iprot.peekList() : (_i261 < _list260.size); - ++_i261) + TList _list272 = iprot.readListBegin(); + _val271 = new ArrayList(Math.max(0, _list272.size)); + for (int _i273 = 0; + (_list272.size < 0) ? iprot.peekList() : (_i273 < _list272.size); + ++_i273) { - int _elem262; - _elem262 = iprot.readI32(); - _val259.add(_elem262); + int _elem274; + _elem274 = iprot.readI32(); + _val271.add(_elem274); } iprot.readListEnd(); } - this.leader_parts.put(_key258, _val259); + this.leader_parts.put(_key270, _val271); } iprot.readMapEnd(); } @@ -332,12 +332,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(LEADER_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.leader_parts.size())); - for (Map.Entry> _iter263 : this.leader_parts.entrySet()) { - oprot.writeI32(_iter263.getKey()); + for (Map.Entry> _iter275 : this.leader_parts.entrySet()) { + oprot.writeI32(_iter275.getKey()); { - oprot.writeListBegin(new TList(TType.I32, _iter263.getValue().size())); - for (int _iter264 : _iter263.getValue()) { - oprot.writeI32(_iter264); + oprot.writeListBegin(new TList(TType.I32, _iter275.getValue().size())); + for (int _iter276 : _iter275.getValue()) { + oprot.writeI32(_iter276); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java deleted file mode 100644 index 4712c0e7f..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetValueRequest.java +++ /dev/null @@ -1,439 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetValueRequest implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetValueRequest"); - private static final TField SPACE_ID_FIELD_DESC = new TField("space_id", TType.I32, (short)1); - private static final TField PART_ID_FIELD_DESC = new TField("part_id", TType.I32, (short)2); - private static final TField KEY_FIELD_DESC = new TField("key", TType.STRING, (short)3); - - public int space_id; - public int part_id; - public byte[] key; - public static final int SPACE_ID = 1; - public static final int PART_ID = 2; - public static final int KEY = 3; - - // isset id assignments - private static final int __SPACE_ID_ISSET_ID = 0; - private static final int __PART_ID_ISSET_ID = 1; - private BitSet __isset_bit_vector = new BitSet(2); - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SPACE_ID, new FieldMetaData("space_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(PART_ID, new FieldMetaData("part_id", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.I32))); - tmpMetaDataMap.put(KEY, new FieldMetaData("key", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetValueRequest.class, metaDataMap); - } - - public GetValueRequest() { - } - - public GetValueRequest( - int space_id, - int part_id, - byte[] key) { - this(); - this.space_id = space_id; - setSpace_idIsSet(true); - this.part_id = part_id; - setPart_idIsSet(true); - this.key = key; - } - - public static class Builder { - private int space_id; - private int part_id; - private byte[] key; - - BitSet __optional_isset = new BitSet(2); - - public Builder() { - } - - public Builder setSpace_id(final int space_id) { - this.space_id = space_id; - __optional_isset.set(__SPACE_ID_ISSET_ID, true); - return this; - } - - public Builder setPart_id(final int part_id) { - this.part_id = part_id; - __optional_isset.set(__PART_ID_ISSET_ID, true); - return this; - } - - public Builder setKey(final byte[] key) { - this.key = key; - return this; - } - - public GetValueRequest build() { - GetValueRequest result = new GetValueRequest(); - if (__optional_isset.get(__SPACE_ID_ISSET_ID)) { - result.setSpace_id(this.space_id); - } - if (__optional_isset.get(__PART_ID_ISSET_ID)) { - result.setPart_id(this.part_id); - } - result.setKey(this.key); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetValueRequest(GetValueRequest other) { - __isset_bit_vector.clear(); - __isset_bit_vector.or(other.__isset_bit_vector); - this.space_id = TBaseHelper.deepCopy(other.space_id); - this.part_id = TBaseHelper.deepCopy(other.part_id); - if (other.isSetKey()) { - this.key = TBaseHelper.deepCopy(other.key); - } - } - - public GetValueRequest deepCopy() { - return new GetValueRequest(this); - } - - public int getSpace_id() { - return this.space_id; - } - - public GetValueRequest setSpace_id(int space_id) { - this.space_id = space_id; - setSpace_idIsSet(true); - return this; - } - - public void unsetSpace_id() { - __isset_bit_vector.clear(__SPACE_ID_ISSET_ID); - } - - // Returns true if field space_id is set (has been assigned a value) and false otherwise - public boolean isSetSpace_id() { - return __isset_bit_vector.get(__SPACE_ID_ISSET_ID); - } - - public void setSpace_idIsSet(boolean __value) { - __isset_bit_vector.set(__SPACE_ID_ISSET_ID, __value); - } - - public int getPart_id() { - return this.part_id; - } - - public GetValueRequest setPart_id(int part_id) { - this.part_id = part_id; - setPart_idIsSet(true); - return this; - } - - public void unsetPart_id() { - __isset_bit_vector.clear(__PART_ID_ISSET_ID); - } - - // Returns true if field part_id is set (has been assigned a value) and false otherwise - public boolean isSetPart_id() { - return __isset_bit_vector.get(__PART_ID_ISSET_ID); - } - - public void setPart_idIsSet(boolean __value) { - __isset_bit_vector.set(__PART_ID_ISSET_ID, __value); - } - - public byte[] getKey() { - return this.key; - } - - public GetValueRequest setKey(byte[] key) { - this.key = key; - return this; - } - - public void unsetKey() { - this.key = null; - } - - // Returns true if field key is set (has been assigned a value) and false otherwise - public boolean isSetKey() { - return this.key != null; - } - - public void setKeyIsSet(boolean __value) { - if (!__value) { - this.key = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SPACE_ID: - if (__value == null) { - unsetSpace_id(); - } else { - setSpace_id((Integer)__value); - } - break; - - case PART_ID: - if (__value == null) { - unsetPart_id(); - } else { - setPart_id((Integer)__value); - } - break; - - case KEY: - if (__value == null) { - unsetKey(); - } else { - setKey((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SPACE_ID: - return new Integer(getSpace_id()); - - case PART_ID: - return new Integer(getPart_id()); - - case KEY: - return getKey(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetValueRequest)) - return false; - GetValueRequest that = (GetValueRequest)_that; - - if (!TBaseHelper.equalsNobinary(this.space_id, that.space_id)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.part_id, that.part_id)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetKey(), that.isSetKey(), this.key, that.key)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {space_id, part_id, key}); - } - - @Override - public int compareTo(GetValueRequest other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSpace_id()).compareTo(other.isSetSpace_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(space_id, other.space_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetPart_id()).compareTo(other.isSetPart_id()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(part_id, other.part_id); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetKey()).compareTo(other.isSetKey()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(key, other.key); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SPACE_ID: - if (__field.type == TType.I32) { - this.space_id = iprot.readI32(); - setSpace_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case PART_ID: - if (__field.type == TType.I32) { - this.part_id = iprot.readI32(); - setPart_idIsSet(true); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case KEY: - if (__field.type == TType.STRING) { - this.key = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - oprot.writeFieldBegin(SPACE_ID_FIELD_DESC); - oprot.writeI32(this.space_id); - oprot.writeFieldEnd(); - oprot.writeFieldBegin(PART_ID_FIELD_DESC); - oprot.writeI32(this.part_id); - oprot.writeFieldEnd(); - if (this.key != null) { - oprot.writeFieldBegin(KEY_FIELD_DESC); - oprot.writeBinary(this.key); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetValueRequest"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("space_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getSpace_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("part_id"); - sb.append(space); - sb.append(":").append(space); - sb.append(TBaseHelper.toString(this.getPart_id(), indent + 1, prettyPrint)); - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("key"); - sb.append(space); - sb.append(":").append(space); - if (this.getKey() == null) { - sb.append("null"); - } else { - int __key_size = Math.min(this.getKey().length, 128); - for (int i = 0; i < __key_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getKey()[i]).length() > 1 ? Integer.toHexString(this.getKey()[i]).substring(Integer.toHexString(this.getKey()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getKey()[i]).toUpperCase()); - } - if (this.getKey().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java deleted file mode 100644 index 8a0b704b8..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/GetValueResponse.java +++ /dev/null @@ -1,365 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class GetValueResponse implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("GetValueResponse"); - private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); - private static final TField VALUE_FIELD_DESC = new TField("value", TType.STRING, (short)2); - - public ResponseCommon result; - public byte[] value; - public static final int RESULT = 1; - public static final int VALUE = 2; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, - new StructMetaData(TType.STRUCT, ResponseCommon.class))); - tmpMetaDataMap.put(VALUE, new FieldMetaData("value", TFieldRequirementType.DEFAULT, - new FieldValueMetaData(TType.STRING))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(GetValueResponse.class, metaDataMap); - } - - public GetValueResponse() { - } - - public GetValueResponse( - ResponseCommon result) { - this(); - this.result = result; - } - - public GetValueResponse( - ResponseCommon result, - byte[] value) { - this(); - this.result = result; - this.value = value; - } - - public static class Builder { - private ResponseCommon result; - private byte[] value; - - public Builder() { - } - - public Builder setResult(final ResponseCommon result) { - this.result = result; - return this; - } - - public Builder setValue(final byte[] value) { - this.value = value; - return this; - } - - public GetValueResponse build() { - GetValueResponse result = new GetValueResponse(); - result.setResult(this.result); - result.setValue(this.value); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public GetValueResponse(GetValueResponse other) { - if (other.isSetResult()) { - this.result = TBaseHelper.deepCopy(other.result); - } - if (other.isSetValue()) { - this.value = TBaseHelper.deepCopy(other.value); - } - } - - public GetValueResponse deepCopy() { - return new GetValueResponse(this); - } - - public ResponseCommon getResult() { - return this.result; - } - - public GetValueResponse setResult(ResponseCommon result) { - this.result = result; - return this; - } - - public void unsetResult() { - this.result = null; - } - - // Returns true if field result is set (has been assigned a value) and false otherwise - public boolean isSetResult() { - return this.result != null; - } - - public void setResultIsSet(boolean __value) { - if (!__value) { - this.result = null; - } - } - - public byte[] getValue() { - return this.value; - } - - public GetValueResponse setValue(byte[] value) { - this.value = value; - return this; - } - - public void unsetValue() { - this.value = null; - } - - // Returns true if field value is set (has been assigned a value) and false otherwise - public boolean isSetValue() { - return this.value != null; - } - - public void setValueIsSet(boolean __value) { - if (!__value) { - this.value = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case RESULT: - if (__value == null) { - unsetResult(); - } else { - setResult((ResponseCommon)__value); - } - break; - - case VALUE: - if (__value == null) { - unsetValue(); - } else { - setValue((byte[])__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case RESULT: - return getResult(); - - case VALUE: - return getValue(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof GetValueResponse)) - return false; - GetValueResponse that = (GetValueResponse)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } - - if (!TBaseHelper.equalsSlow(this.isSetValue(), that.isSetValue(), this.value, that.value)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, value}); - } - - @Override - public int compareTo(GetValueResponse other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(result, other.result); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(value, other.value); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case RESULT: - if (__field.type == TType.STRUCT) { - this.result = new ResponseCommon(); - this.result.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case VALUE: - if (__field.type == TType.STRING) { - this.value = iprot.readBinary(); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.result != null) { - oprot.writeFieldBegin(RESULT_FIELD_DESC); - this.result.write(oprot); - oprot.writeFieldEnd(); - } - if (this.value != null) { - oprot.writeFieldBegin(VALUE_FIELD_DESC); - oprot.writeBinary(this.value); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("GetValueResponse"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("result"); - sb.append(space); - sb.append(":").append(space); - if (this.getResult() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("value"); - sb.append(space); - sb.append(":").append(space); - if (this.getValue() == null) { - sb.append("null"); - } else { - int __value_size = Math.min(this.getValue().length, 128); - for (int i = 0; i < __value_size; i++) { - if (i != 0) sb.append(" "); - sb.append(Integer.toHexString(this.getValue()[i]).length() > 1 ? Integer.toHexString(this.getValue()[i]).substring(Integer.toHexString(this.getValue()[i]).length() - 2).toUpperCase() : "0" + Integer.toHexString(this.getValue()[i]).toUpperCase()); - } - if (this.getValue().length > 128) sb.append(" ..."); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - if (result == null) { - throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); - } - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java index 3cfcc78f6..0ecb6bdf2 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/GraphStorageService.java @@ -1015,17 +1015,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler330) throws TException { + public void getNeighbors(GetNeighborsRequest req, AsyncMethodCallback resultHandler342) throws TException { checkReady(); - getNeighbors_call method_call = new getNeighbors_call(req, resultHandler330, this, ___protocolFactory, ___transport); + getNeighbors_call method_call = new getNeighbors_call(req, resultHandler342, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getNeighbors_call extends TAsyncMethodCall { private GetNeighborsRequest req; - public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler331, TAsyncClient client327, TProtocolFactory protocolFactory328, TNonblockingTransport transport329) throws TException { - super(client327, protocolFactory328, transport329, resultHandler331, false); + public getNeighbors_call(GetNeighborsRequest req, AsyncMethodCallback resultHandler343, TAsyncClient client339, TProtocolFactory protocolFactory340, TNonblockingTransport transport341) throws TException { + super(client339, protocolFactory340, transport341, resultHandler343, false); this.req = req; } @@ -1047,17 +1047,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler335) throws TException { + public void getProps(GetPropRequest req, AsyncMethodCallback resultHandler347) throws TException { checkReady(); - getProps_call method_call = new getProps_call(req, resultHandler335, this, ___protocolFactory, ___transport); + getProps_call method_call = new getProps_call(req, resultHandler347, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getProps_call extends TAsyncMethodCall { private GetPropRequest req; - public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler336, TAsyncClient client332, TProtocolFactory protocolFactory333, TNonblockingTransport transport334) throws TException { - super(client332, protocolFactory333, transport334, resultHandler336, false); + public getProps_call(GetPropRequest req, AsyncMethodCallback resultHandler348, TAsyncClient client344, TProtocolFactory protocolFactory345, TNonblockingTransport transport346) throws TException { + super(client344, protocolFactory345, transport346, resultHandler348, false); this.req = req; } @@ -1079,17 +1079,17 @@ public GetPropResponse getResult() throws TException { } } - public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler340) throws TException { + public void addVertices(AddVerticesRequest req, AsyncMethodCallback resultHandler352) throws TException { checkReady(); - addVertices_call method_call = new addVertices_call(req, resultHandler340, this, ___protocolFactory, ___transport); + addVertices_call method_call = new addVertices_call(req, resultHandler352, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addVertices_call extends TAsyncMethodCall { private AddVerticesRequest req; - public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler341, TAsyncClient client337, TProtocolFactory protocolFactory338, TNonblockingTransport transport339) throws TException { - super(client337, protocolFactory338, transport339, resultHandler341, false); + public addVertices_call(AddVerticesRequest req, AsyncMethodCallback resultHandler353, TAsyncClient client349, TProtocolFactory protocolFactory350, TNonblockingTransport transport351) throws TException { + super(client349, protocolFactory350, transport351, resultHandler353, false); this.req = req; } @@ -1111,17 +1111,17 @@ public ExecResponse getResult() throws TException { } } - public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler345) throws TException { + public void addEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler357) throws TException { checkReady(); - addEdges_call method_call = new addEdges_call(req, resultHandler345, this, ___protocolFactory, ___transport); + addEdges_call method_call = new addEdges_call(req, resultHandler357, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler346, TAsyncClient client342, TProtocolFactory protocolFactory343, TNonblockingTransport transport344) throws TException { - super(client342, protocolFactory343, transport344, resultHandler346, false); + public addEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler358, TAsyncClient client354, TProtocolFactory protocolFactory355, TNonblockingTransport transport356) throws TException { + super(client354, protocolFactory355, transport356, resultHandler358, false); this.req = req; } @@ -1143,17 +1143,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler350) throws TException { + public void deleteEdges(DeleteEdgesRequest req, AsyncMethodCallback resultHandler362) throws TException { checkReady(); - deleteEdges_call method_call = new deleteEdges_call(req, resultHandler350, this, ___protocolFactory, ___transport); + deleteEdges_call method_call = new deleteEdges_call(req, resultHandler362, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteEdges_call extends TAsyncMethodCall { private DeleteEdgesRequest req; - public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler351, TAsyncClient client347, TProtocolFactory protocolFactory348, TNonblockingTransport transport349) throws TException { - super(client347, protocolFactory348, transport349, resultHandler351, false); + public deleteEdges_call(DeleteEdgesRequest req, AsyncMethodCallback resultHandler363, TAsyncClient client359, TProtocolFactory protocolFactory360, TNonblockingTransport transport361) throws TException { + super(client359, protocolFactory360, transport361, resultHandler363, false); this.req = req; } @@ -1175,17 +1175,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler355) throws TException { + public void deleteVertices(DeleteVerticesRequest req, AsyncMethodCallback resultHandler367) throws TException { checkReady(); - deleteVertices_call method_call = new deleteVertices_call(req, resultHandler355, this, ___protocolFactory, ___transport); + deleteVertices_call method_call = new deleteVertices_call(req, resultHandler367, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteVertices_call extends TAsyncMethodCall { private DeleteVerticesRequest req; - public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler356, TAsyncClient client352, TProtocolFactory protocolFactory353, TNonblockingTransport transport354) throws TException { - super(client352, protocolFactory353, transport354, resultHandler356, false); + public deleteVertices_call(DeleteVerticesRequest req, AsyncMethodCallback resultHandler368, TAsyncClient client364, TProtocolFactory protocolFactory365, TNonblockingTransport transport366) throws TException { + super(client364, protocolFactory365, transport366, resultHandler368, false); this.req = req; } @@ -1207,17 +1207,17 @@ public ExecResponse getResult() throws TException { } } - public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler360) throws TException { + public void deleteTags(DeleteTagsRequest req, AsyncMethodCallback resultHandler372) throws TException { checkReady(); - deleteTags_call method_call = new deleteTags_call(req, resultHandler360, this, ___protocolFactory, ___transport); + deleteTags_call method_call = new deleteTags_call(req, resultHandler372, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class deleteTags_call extends TAsyncMethodCall { private DeleteTagsRequest req; - public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler361, TAsyncClient client357, TProtocolFactory protocolFactory358, TNonblockingTransport transport359) throws TException { - super(client357, protocolFactory358, transport359, resultHandler361, false); + public deleteTags_call(DeleteTagsRequest req, AsyncMethodCallback resultHandler373, TAsyncClient client369, TProtocolFactory protocolFactory370, TNonblockingTransport transport371) throws TException { + super(client369, protocolFactory370, transport371, resultHandler373, false); this.req = req; } @@ -1239,17 +1239,17 @@ public ExecResponse getResult() throws TException { } } - public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler365) throws TException { + public void updateVertex(UpdateVertexRequest req, AsyncMethodCallback resultHandler377) throws TException { checkReady(); - updateVertex_call method_call = new updateVertex_call(req, resultHandler365, this, ___protocolFactory, ___transport); + updateVertex_call method_call = new updateVertex_call(req, resultHandler377, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateVertex_call extends TAsyncMethodCall { private UpdateVertexRequest req; - public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler366, TAsyncClient client362, TProtocolFactory protocolFactory363, TNonblockingTransport transport364) throws TException { - super(client362, protocolFactory363, transport364, resultHandler366, false); + public updateVertex_call(UpdateVertexRequest req, AsyncMethodCallback resultHandler378, TAsyncClient client374, TProtocolFactory protocolFactory375, TNonblockingTransport transport376) throws TException { + super(client374, protocolFactory375, transport376, resultHandler378, false); this.req = req; } @@ -1271,17 +1271,17 @@ public UpdateResponse getResult() throws TException { } } - public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler370) throws TException { + public void updateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler382) throws TException { checkReady(); - updateEdge_call method_call = new updateEdge_call(req, resultHandler370, this, ___protocolFactory, ___transport); + updateEdge_call method_call = new updateEdge_call(req, resultHandler382, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class updateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler371, TAsyncClient client367, TProtocolFactory protocolFactory368, TNonblockingTransport transport369) throws TException { - super(client367, protocolFactory368, transport369, resultHandler371, false); + public updateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler383, TAsyncClient client379, TProtocolFactory protocolFactory380, TNonblockingTransport transport381) throws TException { + super(client379, protocolFactory380, transport381, resultHandler383, false); this.req = req; } @@ -1303,17 +1303,17 @@ public UpdateResponse getResult() throws TException { } } - public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler375) throws TException { + public void scanVertex(ScanVertexRequest req, AsyncMethodCallback resultHandler387) throws TException { checkReady(); - scanVertex_call method_call = new scanVertex_call(req, resultHandler375, this, ___protocolFactory, ___transport); + scanVertex_call method_call = new scanVertex_call(req, resultHandler387, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanVertex_call extends TAsyncMethodCall { private ScanVertexRequest req; - public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler376, TAsyncClient client372, TProtocolFactory protocolFactory373, TNonblockingTransport transport374) throws TException { - super(client372, protocolFactory373, transport374, resultHandler376, false); + public scanVertex_call(ScanVertexRequest req, AsyncMethodCallback resultHandler388, TAsyncClient client384, TProtocolFactory protocolFactory385, TNonblockingTransport transport386) throws TException { + super(client384, protocolFactory385, transport386, resultHandler388, false); this.req = req; } @@ -1335,17 +1335,17 @@ public ScanResponse getResult() throws TException { } } - public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler380) throws TException { + public void scanEdge(ScanEdgeRequest req, AsyncMethodCallback resultHandler392) throws TException { checkReady(); - scanEdge_call method_call = new scanEdge_call(req, resultHandler380, this, ___protocolFactory, ___transport); + scanEdge_call method_call = new scanEdge_call(req, resultHandler392, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class scanEdge_call extends TAsyncMethodCall { private ScanEdgeRequest req; - public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler381, TAsyncClient client377, TProtocolFactory protocolFactory378, TNonblockingTransport transport379) throws TException { - super(client377, protocolFactory378, transport379, resultHandler381, false); + public scanEdge_call(ScanEdgeRequest req, AsyncMethodCallback resultHandler393, TAsyncClient client389, TProtocolFactory protocolFactory390, TNonblockingTransport transport391) throws TException { + super(client389, protocolFactory390, transport391, resultHandler393, false); this.req = req; } @@ -1367,17 +1367,17 @@ public ScanResponse getResult() throws TException { } } - public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler385) throws TException { + public void getUUID(GetUUIDReq req, AsyncMethodCallback resultHandler397) throws TException { checkReady(); - getUUID_call method_call = new getUUID_call(req, resultHandler385, this, ___protocolFactory, ___transport); + getUUID_call method_call = new getUUID_call(req, resultHandler397, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getUUID_call extends TAsyncMethodCall { private GetUUIDReq req; - public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler386, TAsyncClient client382, TProtocolFactory protocolFactory383, TNonblockingTransport transport384) throws TException { - super(client382, protocolFactory383, transport384, resultHandler386, false); + public getUUID_call(GetUUIDReq req, AsyncMethodCallback resultHandler398, TAsyncClient client394, TProtocolFactory protocolFactory395, TNonblockingTransport transport396) throws TException { + super(client394, protocolFactory395, transport396, resultHandler398, false); this.req = req; } @@ -1399,17 +1399,17 @@ public GetUUIDResp getResult() throws TException { } } - public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler390) throws TException { + public void lookupIndex(LookupIndexRequest req, AsyncMethodCallback resultHandler402) throws TException { checkReady(); - lookupIndex_call method_call = new lookupIndex_call(req, resultHandler390, this, ___protocolFactory, ___transport); + lookupIndex_call method_call = new lookupIndex_call(req, resultHandler402, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupIndex_call extends TAsyncMethodCall { private LookupIndexRequest req; - public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler391, TAsyncClient client387, TProtocolFactory protocolFactory388, TNonblockingTransport transport389) throws TException { - super(client387, protocolFactory388, transport389, resultHandler391, false); + public lookupIndex_call(LookupIndexRequest req, AsyncMethodCallback resultHandler403, TAsyncClient client399, TProtocolFactory protocolFactory400, TNonblockingTransport transport401) throws TException { + super(client399, protocolFactory400, transport401, resultHandler403, false); this.req = req; } @@ -1431,17 +1431,17 @@ public LookupIndexResp getResult() throws TException { } } - public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler395) throws TException { + public void lookupAndTraverse(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler407) throws TException { checkReady(); - lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler395, this, ___protocolFactory, ___transport); + lookupAndTraverse_call method_call = new lookupAndTraverse_call(req, resultHandler407, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class lookupAndTraverse_call extends TAsyncMethodCall { private LookupAndTraverseRequest req; - public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler396, TAsyncClient client392, TProtocolFactory protocolFactory393, TNonblockingTransport transport394) throws TException { - super(client392, protocolFactory393, transport394, resultHandler396, false); + public lookupAndTraverse_call(LookupAndTraverseRequest req, AsyncMethodCallback resultHandler408, TAsyncClient client404, TProtocolFactory protocolFactory405, TNonblockingTransport transport406) throws TException { + super(client404, protocolFactory405, transport406, resultHandler408, false); this.req = req; } @@ -1463,17 +1463,17 @@ public GetNeighborsResponse getResult() throws TException { } } - public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler400) throws TException { + public void chainUpdateEdge(UpdateEdgeRequest req, AsyncMethodCallback resultHandler412) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler400, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler412, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private UpdateEdgeRequest req; - public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler401, TAsyncClient client397, TProtocolFactory protocolFactory398, TNonblockingTransport transport399) throws TException { - super(client397, protocolFactory398, transport399, resultHandler401, false); + public chainUpdateEdge_call(UpdateEdgeRequest req, AsyncMethodCallback resultHandler413, TAsyncClient client409, TProtocolFactory protocolFactory410, TNonblockingTransport transport411) throws TException { + super(client409, protocolFactory410, transport411, resultHandler413, false); this.req = req; } @@ -1495,17 +1495,17 @@ public UpdateResponse getResult() throws TException { } } - public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler405) throws TException { + public void chainAddEdges(AddEdgesRequest req, AsyncMethodCallback resultHandler417) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler405, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler417, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private AddEdgesRequest req; - public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler406, TAsyncClient client402, TProtocolFactory protocolFactory403, TNonblockingTransport transport404) throws TException { - super(client402, protocolFactory403, transport404, resultHandler406, false); + public chainAddEdges_call(AddEdgesRequest req, AsyncMethodCallback resultHandler418, TAsyncClient client414, TProtocolFactory protocolFactory415, TNonblockingTransport transport416) throws TException { + super(client414, protocolFactory415, transport416, resultHandler418, false); this.req = req; } @@ -1527,17 +1527,17 @@ public ExecResponse getResult() throws TException { } } - public void get(KVGetRequest req, AsyncMethodCallback resultHandler410) throws TException { + public void get(KVGetRequest req, AsyncMethodCallback resultHandler422) throws TException { checkReady(); - get_call method_call = new get_call(req, resultHandler410, this, ___protocolFactory, ___transport); + get_call method_call = new get_call(req, resultHandler422, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class get_call extends TAsyncMethodCall { private KVGetRequest req; - public get_call(KVGetRequest req, AsyncMethodCallback resultHandler411, TAsyncClient client407, TProtocolFactory protocolFactory408, TNonblockingTransport transport409) throws TException { - super(client407, protocolFactory408, transport409, resultHandler411, false); + public get_call(KVGetRequest req, AsyncMethodCallback resultHandler423, TAsyncClient client419, TProtocolFactory protocolFactory420, TNonblockingTransport transport421) throws TException { + super(client419, protocolFactory420, transport421, resultHandler423, false); this.req = req; } @@ -1559,17 +1559,17 @@ public KVGetResponse getResult() throws TException { } } - public void put(KVPutRequest req, AsyncMethodCallback resultHandler415) throws TException { + public void put(KVPutRequest req, AsyncMethodCallback resultHandler427) throws TException { checkReady(); - put_call method_call = new put_call(req, resultHandler415, this, ___protocolFactory, ___transport); + put_call method_call = new put_call(req, resultHandler427, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class put_call extends TAsyncMethodCall { private KVPutRequest req; - public put_call(KVPutRequest req, AsyncMethodCallback resultHandler416, TAsyncClient client412, TProtocolFactory protocolFactory413, TNonblockingTransport transport414) throws TException { - super(client412, protocolFactory413, transport414, resultHandler416, false); + public put_call(KVPutRequest req, AsyncMethodCallback resultHandler428, TAsyncClient client424, TProtocolFactory protocolFactory425, TNonblockingTransport transport426) throws TException { + super(client424, protocolFactory425, transport426, resultHandler428, false); this.req = req; } @@ -1591,17 +1591,17 @@ public ExecResponse getResult() throws TException { } } - public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler420) throws TException { + public void remove(KVRemoveRequest req, AsyncMethodCallback resultHandler432) throws TException { checkReady(); - remove_call method_call = new remove_call(req, resultHandler420, this, ___protocolFactory, ___transport); + remove_call method_call = new remove_call(req, resultHandler432, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class remove_call extends TAsyncMethodCall { private KVRemoveRequest req; - public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler421, TAsyncClient client417, TProtocolFactory protocolFactory418, TNonblockingTransport transport419) throws TException { - super(client417, protocolFactory418, transport419, resultHandler421, false); + public remove_call(KVRemoveRequest req, AsyncMethodCallback resultHandler433, TAsyncClient client429, TProtocolFactory protocolFactory430, TNonblockingTransport transport431) throws TException { + super(client429, protocolFactory430, transport431, resultHandler433, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java index f687d603f..eb9e70bc2 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalStorageService.java @@ -182,17 +182,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler523) throws TException { + public void chainAddEdges(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler529) throws TException { checkReady(); - chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler523, this, ___protocolFactory, ___transport); + chainAddEdges_call method_call = new chainAddEdges_call(req, resultHandler529, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainAddEdges_call extends TAsyncMethodCall { private ChainAddEdgesRequest req; - public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler524, TAsyncClient client520, TProtocolFactory protocolFactory521, TNonblockingTransport transport522) throws TException { - super(client520, protocolFactory521, transport522, resultHandler524, false); + public chainAddEdges_call(ChainAddEdgesRequest req, AsyncMethodCallback resultHandler530, TAsyncClient client526, TProtocolFactory protocolFactory527, TNonblockingTransport transport528) throws TException { + super(client526, protocolFactory527, transport528, resultHandler530, false); this.req = req; } @@ -214,17 +214,17 @@ public ExecResponse getResult() throws TException { } } - public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler528) throws TException { + public void chainUpdateEdge(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler534) throws TException { checkReady(); - chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler528, this, ___protocolFactory, ___transport); + chainUpdateEdge_call method_call = new chainUpdateEdge_call(req, resultHandler534, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class chainUpdateEdge_call extends TAsyncMethodCall { private ChainUpdateEdgeRequest req; - public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler529, TAsyncClient client525, TProtocolFactory protocolFactory526, TNonblockingTransport transport527) throws TException { - super(client525, protocolFactory526, transport527, resultHandler529, false); + public chainUpdateEdge_call(ChainUpdateEdgeRequest req, AsyncMethodCallback resultHandler535, TAsyncClient client531, TProtocolFactory protocolFactory532, TNonblockingTransport transport533) throws TException { + super(client531, protocolFactory532, transport533, resultHandler535, false); this.req = req; } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java index a54234d85..692ffd7fe 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/InternalTxnRequest.java @@ -419,17 +419,17 @@ public void read(TProtocol iprot) throws TException { case TERM_OF_PARTS: if (__field.type == TType.MAP) { { - TMap _map277 = iprot.readMapBegin(); - this.term_of_parts = new HashMap(Math.max(0, 2*_map277.size)); - for (int _i278 = 0; - (_map277.size < 0) ? iprot.peekMap() : (_i278 < _map277.size); - ++_i278) + TMap _map289 = iprot.readMapBegin(); + this.term_of_parts = new HashMap(Math.max(0, 2*_map289.size)); + for (int _i290 = 0; + (_map289.size < 0) ? iprot.peekMap() : (_i290 < _map289.size); + ++_i290) { - int _key279; - long _val280; - _key279 = iprot.readI32(); - _val280 = iprot.readI64(); - this.term_of_parts.put(_key279, _val280); + int _key291; + long _val292; + _key291 = iprot.readI32(); + _val292 = iprot.readI64(); + this.term_of_parts.put(_key291, _val292); } iprot.readMapEnd(); } @@ -456,29 +456,29 @@ public void read(TProtocol iprot) throws TException { case EDGE_VER: if (__field.type == TType.MAP) { { - TMap _map281 = iprot.readMapBegin(); - this.edge_ver = new HashMap>(Math.max(0, 2*_map281.size)); - for (int _i282 = 0; - (_map281.size < 0) ? iprot.peekMap() : (_i282 < _map281.size); - ++_i282) + TMap _map293 = iprot.readMapBegin(); + this.edge_ver = new HashMap>(Math.max(0, 2*_map293.size)); + for (int _i294 = 0; + (_map293.size < 0) ? iprot.peekMap() : (_i294 < _map293.size); + ++_i294) { - int _key283; - List _val284; - _key283 = iprot.readI32(); + int _key295; + List _val296; + _key295 = iprot.readI32(); { - TList _list285 = iprot.readListBegin(); - _val284 = new ArrayList(Math.max(0, _list285.size)); - for (int _i286 = 0; - (_list285.size < 0) ? iprot.peekList() : (_i286 < _list285.size); - ++_i286) + TList _list297 = iprot.readListBegin(); + _val296 = new ArrayList(Math.max(0, _list297.size)); + for (int _i298 = 0; + (_list297.size < 0) ? iprot.peekList() : (_i298 < _list297.size); + ++_i298) { - long _elem287; - _elem287 = iprot.readI64(); - _val284.add(_elem287); + long _elem299; + _elem299 = iprot.readI64(); + _val296.add(_elem299); } iprot.readListEnd(); } - this.edge_ver.put(_key283, _val284); + this.edge_ver.put(_key295, _val296); } iprot.readMapEnd(); } @@ -510,9 +510,9 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(TERM_OF_PARTS_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.I64, this.term_of_parts.size())); - for (Map.Entry _iter288 : this.term_of_parts.entrySet()) { - oprot.writeI32(_iter288.getKey()); - oprot.writeI64(_iter288.getValue()); + for (Map.Entry _iter300 : this.term_of_parts.entrySet()) { + oprot.writeI32(_iter300.getKey()); + oprot.writeI64(_iter300.getValue()); } oprot.writeMapEnd(); } @@ -537,12 +537,12 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(EDGE_VER_FIELD_DESC); { oprot.writeMapBegin(new TMap(TType.I32, TType.LIST, this.edge_ver.size())); - for (Map.Entry> _iter289 : this.edge_ver.entrySet()) { - oprot.writeI32(_iter289.getKey()); + for (Map.Entry> _iter301 : this.edge_ver.entrySet()) { + oprot.writeI32(_iter301.getKey()); { - oprot.writeListBegin(new TList(TType.I64, _iter289.getValue().size())); - for (long _iter290 : _iter289.getValue()) { - oprot.writeI64(_iter290); + oprot.writeListBegin(new TList(TType.I64, _iter301.getValue().size())); + for (long _iter302 : _iter301.getValue()) { + oprot.writeI64(_iter302); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java index c3947fc5e..2047e2101 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/RebuildIndexRequest.java @@ -339,15 +339,15 @@ public void read(TProtocol iprot) throws TException { case PARTS: if (__field.type == TType.LIST) { { - TList _list269 = iprot.readListBegin(); - this.parts = new ArrayList(Math.max(0, _list269.size)); - for (int _i270 = 0; - (_list269.size < 0) ? iprot.peekList() : (_i270 < _list269.size); - ++_i270) + TList _list281 = iprot.readListBegin(); + this.parts = new ArrayList(Math.max(0, _list281.size)); + for (int _i282 = 0; + (_list281.size < 0) ? iprot.peekList() : (_i282 < _list281.size); + ++_i282) { - int _elem271; - _elem271 = iprot.readI32(); - this.parts.add(_elem271); + int _elem283; + _elem283 = iprot.readI32(); + this.parts.add(_elem283); } iprot.readListEnd(); } @@ -387,8 +387,8 @@ public void write(TProtocol oprot) throws TException { oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new TList(TType.I32, this.parts.size())); - for (int _iter272 : this.parts) { - oprot.writeI32(_iter272); + for (int _iter284 : this.parts) { + oprot.writeI32(_iter284); } oprot.writeListEnd(); } diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java deleted file mode 100644 index 36a6c53df..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanEdgeResponse.java +++ /dev/null @@ -1,432 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ScanEdgeResponse implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("ScanEdgeResponse"); - private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); - private static final TField EDGE_DATA_FIELD_DESC = new TField("edge_data", TType.STRUCT, (short)2); - private static final TField CURSORS_FIELD_DESC = new TField("cursors", TType.MAP, (short)3); - - public ResponseCommon result; - public com.vesoft.nebula.DataSet edge_data; - public Map cursors; - public static final int RESULT = 1; - public static final int EDGE_DATA = 2; - public static final int CURSORS = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, - new StructMetaData(TType.STRUCT, ResponseCommon.class))); - tmpMetaDataMap.put(EDGE_DATA, new FieldMetaData("edge_data", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); - tmpMetaDataMap.put(CURSORS, new FieldMetaData("cursors", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I32), - new StructMetaData(TType.STRUCT, ScanCursor.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ScanEdgeResponse.class, metaDataMap); - } - - public ScanEdgeResponse() { - } - - public ScanEdgeResponse( - ResponseCommon result) { - this(); - this.result = result; - } - - public ScanEdgeResponse( - ResponseCommon result, - com.vesoft.nebula.DataSet edge_data, - Map cursors) { - this(); - this.result = result; - this.edge_data = edge_data; - this.cursors = cursors; - } - - public static class Builder { - private ResponseCommon result; - private com.vesoft.nebula.DataSet edge_data; - private Map cursors; - - public Builder() { - } - - public Builder setResult(final ResponseCommon result) { - this.result = result; - return this; - } - - public Builder setEdge_data(final com.vesoft.nebula.DataSet edge_data) { - this.edge_data = edge_data; - return this; - } - - public Builder setCursors(final Map cursors) { - this.cursors = cursors; - return this; - } - - public ScanEdgeResponse build() { - ScanEdgeResponse result = new ScanEdgeResponse(); - result.setResult(this.result); - result.setEdge_data(this.edge_data); - result.setCursors(this.cursors); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ScanEdgeResponse(ScanEdgeResponse other) { - if (other.isSetResult()) { - this.result = TBaseHelper.deepCopy(other.result); - } - if (other.isSetEdge_data()) { - this.edge_data = TBaseHelper.deepCopy(other.edge_data); - } - if (other.isSetCursors()) { - this.cursors = TBaseHelper.deepCopy(other.cursors); - } - } - - public ScanEdgeResponse deepCopy() { - return new ScanEdgeResponse(this); - } - - public ResponseCommon getResult() { - return this.result; - } - - public ScanEdgeResponse setResult(ResponseCommon result) { - this.result = result; - return this; - } - - public void unsetResult() { - this.result = null; - } - - // Returns true if field result is set (has been assigned a value) and false otherwise - public boolean isSetResult() { - return this.result != null; - } - - public void setResultIsSet(boolean __value) { - if (!__value) { - this.result = null; - } - } - - public com.vesoft.nebula.DataSet getEdge_data() { - return this.edge_data; - } - - public ScanEdgeResponse setEdge_data(com.vesoft.nebula.DataSet edge_data) { - this.edge_data = edge_data; - return this; - } - - public void unsetEdge_data() { - this.edge_data = null; - } - - // Returns true if field edge_data is set (has been assigned a value) and false otherwise - public boolean isSetEdge_data() { - return this.edge_data != null; - } - - public void setEdge_dataIsSet(boolean __value) { - if (!__value) { - this.edge_data = null; - } - } - - public Map getCursors() { - return this.cursors; - } - - public ScanEdgeResponse setCursors(Map cursors) { - this.cursors = cursors; - return this; - } - - public void unsetCursors() { - this.cursors = null; - } - - // Returns true if field cursors is set (has been assigned a value) and false otherwise - public boolean isSetCursors() { - return this.cursors != null; - } - - public void setCursorsIsSet(boolean __value) { - if (!__value) { - this.cursors = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case RESULT: - if (__value == null) { - unsetResult(); - } else { - setResult((ResponseCommon)__value); - } - break; - - case EDGE_DATA: - if (__value == null) { - unsetEdge_data(); - } else { - setEdge_data((com.vesoft.nebula.DataSet)__value); - } - break; - - case CURSORS: - if (__value == null) { - unsetCursors(); - } else { - setCursors((Map)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case RESULT: - return getResult(); - - case EDGE_DATA: - return getEdge_data(); - - case CURSORS: - return getCursors(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ScanEdgeResponse)) - return false; - ScanEdgeResponse that = (ScanEdgeResponse)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetEdge_data(), that.isSetEdge_data(), this.edge_data, that.edge_data)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetCursors(), that.isSetCursors(), this.cursors, that.cursors)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, edge_data, cursors}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case RESULT: - if (__field.type == TType.STRUCT) { - this.result = new ResponseCommon(); - this.result.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case EDGE_DATA: - if (__field.type == TType.STRUCT) { - this.edge_data = new com.vesoft.nebula.DataSet(); - this.edge_data.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CURSORS: - if (__field.type == TType.MAP) { - { - TMap _map208 = iprot.readMapBegin(); - this.cursors = new HashMap(Math.max(0, 2*_map208.size)); - for (int _i209 = 0; - (_map208.size < 0) ? iprot.peekMap() : (_i209 < _map208.size); - ++_i209) - { - int _key210; - ScanCursor _val211; - _key210 = iprot.readI32(); - _val211 = new ScanCursor(); - _val211.read(iprot); - this.cursors.put(_key210, _val211); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.result != null) { - oprot.writeFieldBegin(RESULT_FIELD_DESC); - this.result.write(oprot); - oprot.writeFieldEnd(); - } - if (this.edge_data != null) { - oprot.writeFieldBegin(EDGE_DATA_FIELD_DESC); - this.edge_data.write(oprot); - oprot.writeFieldEnd(); - } - if (this.cursors != null) { - oprot.writeFieldBegin(CURSORS_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.cursors.size())); - for (Map.Entry _iter212 : this.cursors.entrySet()) { - oprot.writeI32(_iter212.getKey()); - _iter212.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ScanEdgeResponse"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("result"); - sb.append(space); - sb.append(":").append(space); - if (this.getResult() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("edge_data"); - sb.append(space); - sb.append(":").append(space); - if (this.getEdge_data() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getEdge_data(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("cursors"); - sb.append(space); - sb.append(":").append(space); - if (this.getCursors() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getCursors(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - if (result == null) { - throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); - } - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java b/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java deleted file mode 100644 index 377ff3c26..000000000 --- a/client/src/main/generated/com/vesoft/nebula/storage/ScanVertexResponse.java +++ /dev/null @@ -1,432 +0,0 @@ -/** - * Autogenerated by Thrift - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ -package com.vesoft.nebula.storage; - -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.Set; -import java.util.HashSet; -import java.util.Collections; -import java.util.BitSet; -import java.util.Arrays; -import com.facebook.thrift.*; -import com.facebook.thrift.annotations.*; -import com.facebook.thrift.async.*; -import com.facebook.thrift.meta_data.*; -import com.facebook.thrift.server.*; -import com.facebook.thrift.transport.*; -import com.facebook.thrift.protocol.*; - -@SuppressWarnings({ "unused", "serial" }) -public class ScanVertexResponse implements TBase, java.io.Serializable, Cloneable { - private static final TStruct STRUCT_DESC = new TStruct("ScanVertexResponse"); - private static final TField RESULT_FIELD_DESC = new TField("result", TType.STRUCT, (short)1); - private static final TField VERTEX_DATA_FIELD_DESC = new TField("vertex_data", TType.STRUCT, (short)2); - private static final TField CURSORS_FIELD_DESC = new TField("cursors", TType.MAP, (short)3); - - public ResponseCommon result; - public com.vesoft.nebula.DataSet vertex_data; - public Map cursors; - public static final int RESULT = 1; - public static final int VERTEX_DATA = 2; - public static final int CURSORS = 3; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(RESULT, new FieldMetaData("result", TFieldRequirementType.REQUIRED, - new StructMetaData(TType.STRUCT, ResponseCommon.class))); - tmpMetaDataMap.put(VERTEX_DATA, new FieldMetaData("vertex_data", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, com.vesoft.nebula.DataSet.class))); - tmpMetaDataMap.put(CURSORS, new FieldMetaData("cursors", TFieldRequirementType.DEFAULT, - new MapMetaData(TType.MAP, - new FieldValueMetaData(TType.I32), - new StructMetaData(TType.STRUCT, ScanCursor.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(ScanVertexResponse.class, metaDataMap); - } - - public ScanVertexResponse() { - } - - public ScanVertexResponse( - ResponseCommon result) { - this(); - this.result = result; - } - - public ScanVertexResponse( - ResponseCommon result, - com.vesoft.nebula.DataSet vertex_data, - Map cursors) { - this(); - this.result = result; - this.vertex_data = vertex_data; - this.cursors = cursors; - } - - public static class Builder { - private ResponseCommon result; - private com.vesoft.nebula.DataSet vertex_data; - private Map cursors; - - public Builder() { - } - - public Builder setResult(final ResponseCommon result) { - this.result = result; - return this; - } - - public Builder setVertex_data(final com.vesoft.nebula.DataSet vertex_data) { - this.vertex_data = vertex_data; - return this; - } - - public Builder setCursors(final Map cursors) { - this.cursors = cursors; - return this; - } - - public ScanVertexResponse build() { - ScanVertexResponse result = new ScanVertexResponse(); - result.setResult(this.result); - result.setVertex_data(this.vertex_data); - result.setCursors(this.cursors); - return result; - } - } - - public static Builder builder() { - return new Builder(); - } - - /** - * Performs a deep copy on other. - */ - public ScanVertexResponse(ScanVertexResponse other) { - if (other.isSetResult()) { - this.result = TBaseHelper.deepCopy(other.result); - } - if (other.isSetVertex_data()) { - this.vertex_data = TBaseHelper.deepCopy(other.vertex_data); - } - if (other.isSetCursors()) { - this.cursors = TBaseHelper.deepCopy(other.cursors); - } - } - - public ScanVertexResponse deepCopy() { - return new ScanVertexResponse(this); - } - - public ResponseCommon getResult() { - return this.result; - } - - public ScanVertexResponse setResult(ResponseCommon result) { - this.result = result; - return this; - } - - public void unsetResult() { - this.result = null; - } - - // Returns true if field result is set (has been assigned a value) and false otherwise - public boolean isSetResult() { - return this.result != null; - } - - public void setResultIsSet(boolean __value) { - if (!__value) { - this.result = null; - } - } - - public com.vesoft.nebula.DataSet getVertex_data() { - return this.vertex_data; - } - - public ScanVertexResponse setVertex_data(com.vesoft.nebula.DataSet vertex_data) { - this.vertex_data = vertex_data; - return this; - } - - public void unsetVertex_data() { - this.vertex_data = null; - } - - // Returns true if field vertex_data is set (has been assigned a value) and false otherwise - public boolean isSetVertex_data() { - return this.vertex_data != null; - } - - public void setVertex_dataIsSet(boolean __value) { - if (!__value) { - this.vertex_data = null; - } - } - - public Map getCursors() { - return this.cursors; - } - - public ScanVertexResponse setCursors(Map cursors) { - this.cursors = cursors; - return this; - } - - public void unsetCursors() { - this.cursors = null; - } - - // Returns true if field cursors is set (has been assigned a value) and false otherwise - public boolean isSetCursors() { - return this.cursors != null; - } - - public void setCursorsIsSet(boolean __value) { - if (!__value) { - this.cursors = null; - } - } - - @SuppressWarnings("unchecked") - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case RESULT: - if (__value == null) { - unsetResult(); - } else { - setResult((ResponseCommon)__value); - } - break; - - case VERTEX_DATA: - if (__value == null) { - unsetVertex_data(); - } else { - setVertex_data((com.vesoft.nebula.DataSet)__value); - } - break; - - case CURSORS: - if (__value == null) { - unsetCursors(); - } else { - setCursors((Map)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case RESULT: - return getResult(); - - case VERTEX_DATA: - return getVertex_data(); - - case CURSORS: - return getCursors(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof ScanVertexResponse)) - return false; - ScanVertexResponse that = (ScanVertexResponse)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetResult(), that.isSetResult(), this.result, that.result)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetVertex_data(), that.isSetVertex_data(), this.vertex_data, that.vertex_data)) { return false; } - - if (!TBaseHelper.equalsNobinary(this.isSetCursors(), that.isSetCursors(), this.cursors, that.cursors)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {result, vertex_data, cursors}); - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case RESULT: - if (__field.type == TType.STRUCT) { - this.result = new ResponseCommon(); - this.result.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case VERTEX_DATA: - if (__field.type == TType.STRUCT) { - this.vertex_data = new com.vesoft.nebula.DataSet(); - this.vertex_data.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - case CURSORS: - if (__field.type == TType.MAP) { - { - TMap _map198 = iprot.readMapBegin(); - this.cursors = new HashMap(Math.max(0, 2*_map198.size)); - for (int _i199 = 0; - (_map198.size < 0) ? iprot.peekMap() : (_i199 < _map198.size); - ++_i199) - { - int _key200; - ScanCursor _val201; - _key200 = iprot.readI32(); - _val201 = new ScanCursor(); - _val201.read(iprot); - this.cursors.put(_key200, _val201); - } - iprot.readMapEnd(); - } - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.result != null) { - oprot.writeFieldBegin(RESULT_FIELD_DESC); - this.result.write(oprot); - oprot.writeFieldEnd(); - } - if (this.vertex_data != null) { - oprot.writeFieldBegin(VERTEX_DATA_FIELD_DESC); - this.vertex_data.write(oprot); - oprot.writeFieldEnd(); - } - if (this.cursors != null) { - oprot.writeFieldBegin(CURSORS_FIELD_DESC); - { - oprot.writeMapBegin(new TMap(TType.I32, TType.STRUCT, this.cursors.size())); - for (Map.Entry _iter202 : this.cursors.entrySet()) { - oprot.writeI32(_iter202.getKey()); - _iter202.getValue().write(oprot); - } - oprot.writeMapEnd(); - } - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("ScanVertexResponse"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("result"); - sb.append(space); - sb.append(":").append(space); - if (this.getResult() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getResult(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("vertex_data"); - sb.append(space); - sb.append(":").append(space); - if (this.getVertex_data() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getVertex_data(), indent + 1, prettyPrint)); - } - first = false; - if (!first) sb.append("," + newLine); - sb.append(indentStr); - sb.append("cursors"); - sb.append(space); - sb.append(":").append(space); - if (this.getCursors() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getCursors(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - if (result == null) { - throw new TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not present! Struct: " + toString()); - } - } - -} - diff --git a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java index 4374a8cd4..c1cae42ce 100644 --- a/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java +++ b/client/src/main/generated/com/vesoft/nebula/storage/StorageAdminService.java @@ -61,8 +61,6 @@ public interface Iface { public AdminExecResp stopAdminTask(StopAdminTaskRequest req) throws TException; - public ListClusterInfoResp listClusterInfo(ListClusterInfoReq req) throws TException; - } public interface AsyncIface { @@ -97,8 +95,6 @@ public interface AsyncIface { public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler) throws TException; - public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler) throws TException; - } public static class Client extends EventHandlerBase implements Iface, TClientIf { @@ -805,51 +801,6 @@ public AdminExecResp recv_stopAdminTask() throws TException throw new TApplicationException(TApplicationException.MISSING_RESULT, "stopAdminTask failed: unknown result"); } - public ListClusterInfoResp listClusterInfo(ListClusterInfoReq req) throws TException - { - ContextStack ctx = getContextStack("StorageAdminService.listClusterInfo", null); - this.setContextStack(ctx); - send_listClusterInfo(req); - return recv_listClusterInfo(); - } - - public void send_listClusterInfo(ListClusterInfoReq req) throws TException - { - ContextStack ctx = this.getContextStack(); - super.preWrite(ctx, "StorageAdminService.listClusterInfo", null); - oprot_.writeMessageBegin(new TMessage("listClusterInfo", TMessageType.CALL, seqid_)); - listClusterInfo_args args = new listClusterInfo_args(); - args.req = req; - args.write(oprot_); - oprot_.writeMessageEnd(); - oprot_.getTransport().flush(); - super.postWrite(ctx, "StorageAdminService.listClusterInfo", args); - return; - } - - public ListClusterInfoResp recv_listClusterInfo() throws TException - { - ContextStack ctx = super.getContextStack(); - long bytes; - TMessageType mtype; - super.preRead(ctx, "StorageAdminService.listClusterInfo"); - TMessage msg = iprot_.readMessageBegin(); - if (msg.type == TMessageType.EXCEPTION) { - TApplicationException x = TApplicationException.read(iprot_); - iprot_.readMessageEnd(); - throw x; - } - listClusterInfo_result result = new listClusterInfo_result(); - result.read(iprot_); - iprot_.readMessageEnd(); - super.postRead(ctx, "StorageAdminService.listClusterInfo", result); - - if (result.isSetSuccess()) { - return result.success; - } - throw new TApplicationException(TApplicationException.MISSING_RESULT, "listClusterInfo failed: unknown result"); - } - } public static class AsyncClient extends TAsyncClient implements AsyncIface { public static class Factory implements TAsyncClientFactory { @@ -868,17 +819,17 @@ public AsyncClient(TProtocolFactory protocolFactory, TAsyncClientManager clientM super(protocolFactory, clientManager, transport); } - public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler441) throws TException { + public void transLeader(TransLeaderReq req, AsyncMethodCallback resultHandler452) throws TException { checkReady(); - transLeader_call method_call = new transLeader_call(req, resultHandler441, this, ___protocolFactory, ___transport); + transLeader_call method_call = new transLeader_call(req, resultHandler452, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class transLeader_call extends TAsyncMethodCall { private TransLeaderReq req; - public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler442, TAsyncClient client438, TProtocolFactory protocolFactory439, TNonblockingTransport transport440) throws TException { - super(client438, protocolFactory439, transport440, resultHandler442, false); + public transLeader_call(TransLeaderReq req, AsyncMethodCallback resultHandler453, TAsyncClient client449, TProtocolFactory protocolFactory450, TNonblockingTransport transport451) throws TException { + super(client449, protocolFactory450, transport451, resultHandler453, false); this.req = req; } @@ -900,17 +851,17 @@ public AdminExecResp getResult() throws TException { } } - public void addPart(AddPartReq req, AsyncMethodCallback resultHandler446) throws TException { + public void addPart(AddPartReq req, AsyncMethodCallback resultHandler457) throws TException { checkReady(); - addPart_call method_call = new addPart_call(req, resultHandler446, this, ___protocolFactory, ___transport); + addPart_call method_call = new addPart_call(req, resultHandler457, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addPart_call extends TAsyncMethodCall { private AddPartReq req; - public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler447, TAsyncClient client443, TProtocolFactory protocolFactory444, TNonblockingTransport transport445) throws TException { - super(client443, protocolFactory444, transport445, resultHandler447, false); + public addPart_call(AddPartReq req, AsyncMethodCallback resultHandler458, TAsyncClient client454, TProtocolFactory protocolFactory455, TNonblockingTransport transport456) throws TException { + super(client454, protocolFactory455, transport456, resultHandler458, false); this.req = req; } @@ -932,17 +883,17 @@ public AdminExecResp getResult() throws TException { } } - public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler451) throws TException { + public void addLearner(AddLearnerReq req, AsyncMethodCallback resultHandler462) throws TException { checkReady(); - addLearner_call method_call = new addLearner_call(req, resultHandler451, this, ___protocolFactory, ___transport); + addLearner_call method_call = new addLearner_call(req, resultHandler462, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addLearner_call extends TAsyncMethodCall { private AddLearnerReq req; - public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler452, TAsyncClient client448, TProtocolFactory protocolFactory449, TNonblockingTransport transport450) throws TException { - super(client448, protocolFactory449, transport450, resultHandler452, false); + public addLearner_call(AddLearnerReq req, AsyncMethodCallback resultHandler463, TAsyncClient client459, TProtocolFactory protocolFactory460, TNonblockingTransport transport461) throws TException { + super(client459, protocolFactory460, transport461, resultHandler463, false); this.req = req; } @@ -964,17 +915,17 @@ public AdminExecResp getResult() throws TException { } } - public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler456) throws TException { + public void removePart(RemovePartReq req, AsyncMethodCallback resultHandler467) throws TException { checkReady(); - removePart_call method_call = new removePart_call(req, resultHandler456, this, ___protocolFactory, ___transport); + removePart_call method_call = new removePart_call(req, resultHandler467, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class removePart_call extends TAsyncMethodCall { private RemovePartReq req; - public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler457, TAsyncClient client453, TProtocolFactory protocolFactory454, TNonblockingTransport transport455) throws TException { - super(client453, protocolFactory454, transport455, resultHandler457, false); + public removePart_call(RemovePartReq req, AsyncMethodCallback resultHandler468, TAsyncClient client464, TProtocolFactory protocolFactory465, TNonblockingTransport transport466) throws TException { + super(client464, protocolFactory465, transport466, resultHandler468, false); this.req = req; } @@ -996,17 +947,17 @@ public AdminExecResp getResult() throws TException { } } - public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler461) throws TException { + public void memberChange(MemberChangeReq req, AsyncMethodCallback resultHandler472) throws TException { checkReady(); - memberChange_call method_call = new memberChange_call(req, resultHandler461, this, ___protocolFactory, ___transport); + memberChange_call method_call = new memberChange_call(req, resultHandler472, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class memberChange_call extends TAsyncMethodCall { private MemberChangeReq req; - public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler462, TAsyncClient client458, TProtocolFactory protocolFactory459, TNonblockingTransport transport460) throws TException { - super(client458, protocolFactory459, transport460, resultHandler462, false); + public memberChange_call(MemberChangeReq req, AsyncMethodCallback resultHandler473, TAsyncClient client469, TProtocolFactory protocolFactory470, TNonblockingTransport transport471) throws TException { + super(client469, protocolFactory470, transport471, resultHandler473, false); this.req = req; } @@ -1028,17 +979,17 @@ public AdminExecResp getResult() throws TException { } } - public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler466) throws TException { + public void waitingForCatchUpData(CatchUpDataReq req, AsyncMethodCallback resultHandler477) throws TException { checkReady(); - waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler466, this, ___protocolFactory, ___transport); + waitingForCatchUpData_call method_call = new waitingForCatchUpData_call(req, resultHandler477, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class waitingForCatchUpData_call extends TAsyncMethodCall { private CatchUpDataReq req; - public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler467, TAsyncClient client463, TProtocolFactory protocolFactory464, TNonblockingTransport transport465) throws TException { - super(client463, protocolFactory464, transport465, resultHandler467, false); + public waitingForCatchUpData_call(CatchUpDataReq req, AsyncMethodCallback resultHandler478, TAsyncClient client474, TProtocolFactory protocolFactory475, TNonblockingTransport transport476) throws TException { + super(client474, protocolFactory475, transport476, resultHandler478, false); this.req = req; } @@ -1060,17 +1011,17 @@ public AdminExecResp getResult() throws TException { } } - public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler471) throws TException { + public void createCheckpoint(CreateCPRequest req, AsyncMethodCallback resultHandler482) throws TException { checkReady(); - createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler471, this, ___protocolFactory, ___transport); + createCheckpoint_call method_call = new createCheckpoint_call(req, resultHandler482, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class createCheckpoint_call extends TAsyncMethodCall { private CreateCPRequest req; - public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler472, TAsyncClient client468, TProtocolFactory protocolFactory469, TNonblockingTransport transport470) throws TException { - super(client468, protocolFactory469, transport470, resultHandler472, false); + public createCheckpoint_call(CreateCPRequest req, AsyncMethodCallback resultHandler483, TAsyncClient client479, TProtocolFactory protocolFactory480, TNonblockingTransport transport481) throws TException { + super(client479, protocolFactory480, transport481, resultHandler483, false); this.req = req; } @@ -1092,17 +1043,17 @@ public CreateCPResp getResult() throws TException { } } - public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler476) throws TException { + public void dropCheckpoint(DropCPRequest req, AsyncMethodCallback resultHandler487) throws TException { checkReady(); - dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler476, this, ___protocolFactory, ___transport); + dropCheckpoint_call method_call = new dropCheckpoint_call(req, resultHandler487, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class dropCheckpoint_call extends TAsyncMethodCall { private DropCPRequest req; - public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler477, TAsyncClient client473, TProtocolFactory protocolFactory474, TNonblockingTransport transport475) throws TException { - super(client473, protocolFactory474, transport475, resultHandler477, false); + public dropCheckpoint_call(DropCPRequest req, AsyncMethodCallback resultHandler488, TAsyncClient client484, TProtocolFactory protocolFactory485, TNonblockingTransport transport486) throws TException { + super(client484, protocolFactory485, transport486, resultHandler488, false); this.req = req; } @@ -1124,17 +1075,17 @@ public AdminExecResp getResult() throws TException { } } - public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler481) throws TException { + public void blockingWrites(BlockingSignRequest req, AsyncMethodCallback resultHandler492) throws TException { checkReady(); - blockingWrites_call method_call = new blockingWrites_call(req, resultHandler481, this, ___protocolFactory, ___transport); + blockingWrites_call method_call = new blockingWrites_call(req, resultHandler492, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class blockingWrites_call extends TAsyncMethodCall { private BlockingSignRequest req; - public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler482, TAsyncClient client478, TProtocolFactory protocolFactory479, TNonblockingTransport transport480) throws TException { - super(client478, protocolFactory479, transport480, resultHandler482, false); + public blockingWrites_call(BlockingSignRequest req, AsyncMethodCallback resultHandler493, TAsyncClient client489, TProtocolFactory protocolFactory490, TNonblockingTransport transport491) throws TException { + super(client489, protocolFactory490, transport491, resultHandler493, false); this.req = req; } @@ -1156,17 +1107,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler486) throws TException { + public void rebuildTagIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler497) throws TException { checkReady(); - rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler486, this, ___protocolFactory, ___transport); + rebuildTagIndex_call method_call = new rebuildTagIndex_call(req, resultHandler497, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildTagIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler487, TAsyncClient client483, TProtocolFactory protocolFactory484, TNonblockingTransport transport485) throws TException { - super(client483, protocolFactory484, transport485, resultHandler487, false); + public rebuildTagIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler498, TAsyncClient client494, TProtocolFactory protocolFactory495, TNonblockingTransport transport496) throws TException { + super(client494, protocolFactory495, transport496, resultHandler498, false); this.req = req; } @@ -1188,17 +1139,17 @@ public AdminExecResp getResult() throws TException { } } - public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler491) throws TException { + public void rebuildEdgeIndex(RebuildIndexRequest req, AsyncMethodCallback resultHandler502) throws TException { checkReady(); - rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler491, this, ___protocolFactory, ___transport); + rebuildEdgeIndex_call method_call = new rebuildEdgeIndex_call(req, resultHandler502, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class rebuildEdgeIndex_call extends TAsyncMethodCall { private RebuildIndexRequest req; - public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler492, TAsyncClient client488, TProtocolFactory protocolFactory489, TNonblockingTransport transport490) throws TException { - super(client488, protocolFactory489, transport490, resultHandler492, false); + public rebuildEdgeIndex_call(RebuildIndexRequest req, AsyncMethodCallback resultHandler503, TAsyncClient client499, TProtocolFactory protocolFactory500, TNonblockingTransport transport501) throws TException { + super(client499, protocolFactory500, transport501, resultHandler503, false); this.req = req; } @@ -1220,17 +1171,17 @@ public AdminExecResp getResult() throws TException { } } - public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler496) throws TException { + public void getLeaderParts(GetLeaderReq req, AsyncMethodCallback resultHandler507) throws TException { checkReady(); - getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler496, this, ___protocolFactory, ___transport); + getLeaderParts_call method_call = new getLeaderParts_call(req, resultHandler507, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class getLeaderParts_call extends TAsyncMethodCall { private GetLeaderReq req; - public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler497, TAsyncClient client493, TProtocolFactory protocolFactory494, TNonblockingTransport transport495) throws TException { - super(client493, protocolFactory494, transport495, resultHandler497, false); + public getLeaderParts_call(GetLeaderReq req, AsyncMethodCallback resultHandler508, TAsyncClient client504, TProtocolFactory protocolFactory505, TNonblockingTransport transport506) throws TException { + super(client504, protocolFactory505, transport506, resultHandler508, false); this.req = req; } @@ -1252,17 +1203,17 @@ public GetLeaderPartsResp getResult() throws TException { } } - public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler501) throws TException { + public void checkPeers(CheckPeersReq req, AsyncMethodCallback resultHandler512) throws TException { checkReady(); - checkPeers_call method_call = new checkPeers_call(req, resultHandler501, this, ___protocolFactory, ___transport); + checkPeers_call method_call = new checkPeers_call(req, resultHandler512, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class checkPeers_call extends TAsyncMethodCall { private CheckPeersReq req; - public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler502, TAsyncClient client498, TProtocolFactory protocolFactory499, TNonblockingTransport transport500) throws TException { - super(client498, protocolFactory499, transport500, resultHandler502, false); + public checkPeers_call(CheckPeersReq req, AsyncMethodCallback resultHandler513, TAsyncClient client509, TProtocolFactory protocolFactory510, TNonblockingTransport transport511) throws TException { + super(client509, protocolFactory510, transport511, resultHandler513, false); this.req = req; } @@ -1284,17 +1235,17 @@ public AdminExecResp getResult() throws TException { } } - public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler506) throws TException { + public void addAdminTask(AddAdminTaskRequest req, AsyncMethodCallback resultHandler517) throws TException { checkReady(); - addAdminTask_call method_call = new addAdminTask_call(req, resultHandler506, this, ___protocolFactory, ___transport); + addAdminTask_call method_call = new addAdminTask_call(req, resultHandler517, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class addAdminTask_call extends TAsyncMethodCall { private AddAdminTaskRequest req; - public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler507, TAsyncClient client503, TProtocolFactory protocolFactory504, TNonblockingTransport transport505) throws TException { - super(client503, protocolFactory504, transport505, resultHandler507, false); + public addAdminTask_call(AddAdminTaskRequest req, AsyncMethodCallback resultHandler518, TAsyncClient client514, TProtocolFactory protocolFactory515, TNonblockingTransport transport516) throws TException { + super(client514, protocolFactory515, transport516, resultHandler518, false); this.req = req; } @@ -1316,17 +1267,17 @@ public AdminExecResp getResult() throws TException { } } - public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler511) throws TException { + public void stopAdminTask(StopAdminTaskRequest req, AsyncMethodCallback resultHandler522) throws TException { checkReady(); - stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler511, this, ___protocolFactory, ___transport); + stopAdminTask_call method_call = new stopAdminTask_call(req, resultHandler522, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; ___manager.call(method_call); } public static class stopAdminTask_call extends TAsyncMethodCall { private StopAdminTaskRequest req; - public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler512, TAsyncClient client508, TProtocolFactory protocolFactory509, TNonblockingTransport transport510) throws TException { - super(client508, protocolFactory509, transport510, resultHandler512, false); + public stopAdminTask_call(StopAdminTaskRequest req, AsyncMethodCallback resultHandler523, TAsyncClient client519, TProtocolFactory protocolFactory520, TNonblockingTransport transport521) throws TException { + super(client519, protocolFactory520, transport521, resultHandler523, false); this.req = req; } @@ -1348,38 +1299,6 @@ public AdminExecResp getResult() throws TException { } } - public void listClusterInfo(ListClusterInfoReq req, AsyncMethodCallback resultHandler516) throws TException { - checkReady(); - listClusterInfo_call method_call = new listClusterInfo_call(req, resultHandler516, this, ___protocolFactory, ___transport); - this.___currentMethod = method_call; - ___manager.call(method_call); - } - - public static class listClusterInfo_call extends TAsyncMethodCall { - private ListClusterInfoReq req; - public listClusterInfo_call(ListClusterInfoReq req, AsyncMethodCallback resultHandler517, TAsyncClient client513, TProtocolFactory protocolFactory514, TNonblockingTransport transport515) throws TException { - super(client513, protocolFactory514, transport515, resultHandler517, false); - this.req = req; - } - - public void write_args(TProtocol prot) throws TException { - prot.writeMessageBegin(new TMessage("listClusterInfo", TMessageType.CALL, 0)); - listClusterInfo_args args = new listClusterInfo_args(); - args.setReq(req); - args.write(prot); - prot.writeMessageEnd(); - } - - public ListClusterInfoResp getResult() throws TException { - if (getState() != State.RESPONSE_READ) { - throw new IllegalStateException("Method call not finished!"); - } - TMemoryInputTransport memoryTransport = new TMemoryInputTransport(getFrameBuffer().array()); - TProtocol prot = super.client.getProtocolFactory().getProtocol(memoryTransport); - return (new Client(prot)).recv_listClusterInfo(); - } - } - } public static class Processor implements TProcessor { @@ -1403,7 +1322,6 @@ public Processor(Iface iface) processMap_.put("checkPeers", new checkPeers()); processMap_.put("addAdminTask", new addAdminTask()); processMap_.put("stopAdminTask", new stopAdminTask()); - processMap_.put("listClusterInfo", new listClusterInfo()); } protected static interface ProcessFunction { @@ -1751,27 +1669,6 @@ public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionCont } - private class listClusterInfo implements ProcessFunction { - public void process(int seqid, TProtocol iprot, TProtocol oprot, TConnectionContext server_ctx) throws TException - { - Object handler_ctx = event_handler_.getContext("StorageAdminService.listClusterInfo", server_ctx); - listClusterInfo_args args = new listClusterInfo_args(); - event_handler_.preRead(handler_ctx, "StorageAdminService.listClusterInfo"); - args.read(iprot); - iprot.readMessageEnd(); - event_handler_.postRead(handler_ctx, "StorageAdminService.listClusterInfo", args); - listClusterInfo_result result = new listClusterInfo_result(); - result.success = iface_.listClusterInfo(args.req); - event_handler_.preWrite(handler_ctx, "StorageAdminService.listClusterInfo", result); - oprot.writeMessageBegin(new TMessage("listClusterInfo", TMessageType.REPLY, seqid)); - result.write(oprot); - oprot.writeMessageEnd(); - oprot.getTransport().flush(); - event_handler_.postWrite(handler_ctx, "StorageAdminService.listClusterInfo", result); - } - - } - } public static class transLeader_args implements TBase, java.io.Serializable, Cloneable, Comparable { @@ -8299,439 +8196,4 @@ public void validate() throws TException { } - public static class listClusterInfo_args implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listClusterInfo_args"); - private static final TField REQ_FIELD_DESC = new TField("req", TType.STRUCT, (short)1); - - public ListClusterInfoReq req; - public static final int REQ = 1; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(REQ, new FieldMetaData("req", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListClusterInfoReq.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listClusterInfo_args.class, metaDataMap); - } - - public listClusterInfo_args() { - } - - public listClusterInfo_args( - ListClusterInfoReq req) { - this(); - this.req = req; - } - - /** - * Performs a deep copy on other. - */ - public listClusterInfo_args(listClusterInfo_args other) { - if (other.isSetReq()) { - this.req = TBaseHelper.deepCopy(other.req); - } - } - - public listClusterInfo_args deepCopy() { - return new listClusterInfo_args(this); - } - - public ListClusterInfoReq getReq() { - return this.req; - } - - public listClusterInfo_args setReq(ListClusterInfoReq req) { - this.req = req; - return this; - } - - public void unsetReq() { - this.req = null; - } - - // Returns true if field req is set (has been assigned a value) and false otherwise - public boolean isSetReq() { - return this.req != null; - } - - public void setReqIsSet(boolean __value) { - if (!__value) { - this.req = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case REQ: - if (__value == null) { - unsetReq(); - } else { - setReq((ListClusterInfoReq)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case REQ: - return getReq(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listClusterInfo_args)) - return false; - listClusterInfo_args that = (listClusterInfo_args)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetReq(), that.isSetReq(), this.req, that.req)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {req}); - } - - @Override - public int compareTo(listClusterInfo_args other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetReq()).compareTo(other.isSetReq()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(req, other.req); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case REQ: - if (__field.type == TType.STRUCT) { - this.req = new ListClusterInfoReq(); - this.req.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - validate(); - - oprot.writeStructBegin(STRUCT_DESC); - if (this.req != null) { - oprot.writeFieldBegin(REQ_FIELD_DESC); - this.req.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listClusterInfo_args"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("req"); - sb.append(space); - sb.append(":").append(space); - if (this.getReq() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getReq(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - - public static class listClusterInfo_result implements TBase, java.io.Serializable, Cloneable, Comparable { - private static final TStruct STRUCT_DESC = new TStruct("listClusterInfo_result"); - private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0); - - public ListClusterInfoResp success; - public static final int SUCCESS = 0; - - // isset id assignments - - public static final Map metaDataMap; - - static { - Map tmpMetaDataMap = new HashMap(); - tmpMetaDataMap.put(SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, - new StructMetaData(TType.STRUCT, ListClusterInfoResp.class))); - metaDataMap = Collections.unmodifiableMap(tmpMetaDataMap); - } - - static { - FieldMetaData.addStructMetaDataMap(listClusterInfo_result.class, metaDataMap); - } - - public listClusterInfo_result() { - } - - public listClusterInfo_result( - ListClusterInfoResp success) { - this(); - this.success = success; - } - - /** - * Performs a deep copy on other. - */ - public listClusterInfo_result(listClusterInfo_result other) { - if (other.isSetSuccess()) { - this.success = TBaseHelper.deepCopy(other.success); - } - } - - public listClusterInfo_result deepCopy() { - return new listClusterInfo_result(this); - } - - public ListClusterInfoResp getSuccess() { - return this.success; - } - - public listClusterInfo_result setSuccess(ListClusterInfoResp success) { - this.success = success; - return this; - } - - public void unsetSuccess() { - this.success = null; - } - - // Returns true if field success is set (has been assigned a value) and false otherwise - public boolean isSetSuccess() { - return this.success != null; - } - - public void setSuccessIsSet(boolean __value) { - if (!__value) { - this.success = null; - } - } - - public void setFieldValue(int fieldID, Object __value) { - switch (fieldID) { - case SUCCESS: - if (__value == null) { - unsetSuccess(); - } else { - setSuccess((ListClusterInfoResp)__value); - } - break; - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - public Object getFieldValue(int fieldID) { - switch (fieldID) { - case SUCCESS: - return getSuccess(); - - default: - throw new IllegalArgumentException("Field " + fieldID + " doesn't exist!"); - } - } - - @Override - public boolean equals(Object _that) { - if (_that == null) - return false; - if (this == _that) - return true; - if (!(_that instanceof listClusterInfo_result)) - return false; - listClusterInfo_result that = (listClusterInfo_result)_that; - - if (!TBaseHelper.equalsNobinary(this.isSetSuccess(), that.isSetSuccess(), this.success, that.success)) { return false; } - - return true; - } - - @Override - public int hashCode() { - return Arrays.deepHashCode(new Object[] {success}); - } - - @Override - public int compareTo(listClusterInfo_result other) { - if (other == null) { - // See java.lang.Comparable docs - throw new NullPointerException(); - } - - if (other == this) { - return 0; - } - int lastComparison = 0; - - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); - if (lastComparison != 0) { - return lastComparison; - } - lastComparison = TBaseHelper.compareTo(success, other.success); - if (lastComparison != 0) { - return lastComparison; - } - return 0; - } - - public void read(TProtocol iprot) throws TException { - TField __field; - iprot.readStructBegin(metaDataMap); - while (true) - { - __field = iprot.readFieldBegin(); - if (__field.type == TType.STOP) { - break; - } - switch (__field.id) - { - case SUCCESS: - if (__field.type == TType.STRUCT) { - this.success = new ListClusterInfoResp(); - this.success.read(iprot); - } else { - TProtocolUtil.skip(iprot, __field.type); - } - break; - default: - TProtocolUtil.skip(iprot, __field.type); - break; - } - iprot.readFieldEnd(); - } - iprot.readStructEnd(); - - - // check for required fields of primitive type, which can't be checked in the validate method - validate(); - } - - public void write(TProtocol oprot) throws TException { - oprot.writeStructBegin(STRUCT_DESC); - - if (this.isSetSuccess()) { - oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - this.success.write(oprot); - oprot.writeFieldEnd(); - } - oprot.writeFieldStop(); - oprot.writeStructEnd(); - } - - @Override - public String toString() { - return toString(1, true); - } - - @Override - public String toString(int indent, boolean prettyPrint) { - String indentStr = prettyPrint ? TBaseHelper.getIndentedString(indent) : ""; - String newLine = prettyPrint ? "\n" : ""; - String space = prettyPrint ? " " : ""; - StringBuilder sb = new StringBuilder("listClusterInfo_result"); - sb.append(space); - sb.append("("); - sb.append(newLine); - boolean first = true; - - sb.append(indentStr); - sb.append("success"); - sb.append(space); - sb.append(":").append(space); - if (this.getSuccess() == null) { - sb.append("null"); - } else { - sb.append(TBaseHelper.toString(this.getSuccess(), indent + 1, prettyPrint)); - } - first = false; - sb.append(newLine + TBaseHelper.reduceIndent(indentStr)); - sb.append(")"); - return sb.toString(); - } - - public void validate() throws TException { - // check for required fields - } - - } - } diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java index 6794818b5..a3bfc260a 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/GraphStorageConnection.java @@ -18,14 +18,11 @@ import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.storage.GraphStorageService; import com.vesoft.nebula.storage.ScanEdgeRequest; -import com.vesoft.nebula.storage.ScanEdgeResponse; import com.vesoft.nebula.storage.ScanResponse; import com.vesoft.nebula.storage.ScanVertexRequest; -import com.vesoft.nebula.storage.ScanVertexResponse; import com.vesoft.nebula.util.SslUtil; import java.io.IOException; import java.net.InetAddress; -import java.net.UnknownHostException; import javax.net.ssl.SSLSocketFactory; public class GraphStorageConnection { diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java index b221ef9f8..ead2b54dc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanEdgeResultIterator.java @@ -7,16 +7,13 @@ import com.facebook.thrift.TException; import com.vesoft.nebula.DataSet; -import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.meta.MetaManager; import com.vesoft.nebula.client.storage.GraphStorageConnection; import com.vesoft.nebula.client.storage.StorageConnPool; import com.vesoft.nebula.client.storage.data.ScanStatus; -import com.vesoft.nebula.storage.PartitionResult; import com.vesoft.nebula.storage.ScanCursor; import com.vesoft.nebula.storage.ScanEdgeRequest; -import com.vesoft.nebula.storage.ScanEdgeResponse; import com.vesoft.nebula.storage.ScanResponse; import java.util.ArrayList; import java.util.Collections; diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java index 10fa498c4..5c599dbd5 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/scan/ScanVertexResultIterator.java @@ -7,13 +7,11 @@ import com.facebook.thrift.TException; import com.vesoft.nebula.DataSet; -import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.meta.MetaManager; import com.vesoft.nebula.client.storage.GraphStorageConnection; import com.vesoft.nebula.client.storage.StorageConnPool; import com.vesoft.nebula.client.storage.data.ScanStatus; -import com.vesoft.nebula.storage.PartitionResult; import com.vesoft.nebula.storage.ScanCursor; import com.vesoft.nebula.storage.ScanResponse; import com.vesoft.nebula.storage.ScanVertexRequest; From 0eebcc44825e4bf270b48852cad34128b941da18 Mon Sep 17 00:00:00 2001 From: Anqi Date: Thu, 30 Dec 2021 15:05:37 +0800 Subject: [PATCH 20/25] update thrift & support duration data type (#413) * support duration data type * update test --- .../client/graph/data/DurationWrapper.java | 78 +++++++ .../client/graph/data/ValueWrapper.java | 150 +++++++++---- .../client/storage/data/BaseTableRow.java | 5 + .../nebula/client/graph/data/TestData.java | 197 ++++++++++-------- .../client/graph/data/TestDataFromServer.java | 29 ++- 5 files changed, 327 insertions(+), 132 deletions(-) create mode 100644 client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java new file mode 100644 index 000000000..256048926 --- /dev/null +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java @@ -0,0 +1,78 @@ +/* Copyright (c) 2021 vesoft inc. All rights reserved. + * + * This source code is licensed under Apache 2.0 License. + */ + +package com.vesoft.nebula.client.graph.data; + +import com.vesoft.nebula.Duration; +import java.util.Objects; + +public class DurationWrapper extends BaseDataObject { + private final Duration duration; + + /** + * DurationWrapper is a wrapper for the duration type of nebula-graph + */ + public DurationWrapper(Duration duration) { + this.duration = duration; + } + + /** + * @return utc duration seconds + */ + public long getSeconds() { + return duration.seconds; + } + + /** + * @retrun utc duration microseconds + */ + public int getMicroseconds() { + return duration.microseconds; + } + + /** + * @return utc duration months + */ + public int getMonths() { + return duration.months; + } + + /** + * @return the duration string + */ + public String getDurationString() { + return String.format("duration({months:%d, seconds:%d, microseconds:%d})", + getMonths(), getSeconds(), getMicroseconds()); + } + + + @Override + public String toString() { + long year = duration.seconds / (60 * 60 * 24); + long remainSeconds = duration.seconds - (year) * (60 * 60 * 24); + return String.format("P%dM%dDT%sS", + duration.months, year, remainSeconds + duration.microseconds / 1000000.0); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + DurationWrapper that = (DurationWrapper) o; + return duration.months == that.getMonths() + && duration.seconds == that.getSeconds() + && duration.microseconds == that.getMicroseconds(); + } + + @Override + public int hashCode() { + return Objects.hash(duration); + } + +} diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java index 600f66e9e..9858d4564 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/ValueWrapper.java @@ -37,15 +37,24 @@ public int getNullType() { @Override public String toString() { switch (nullType) { - case __NULL__: return "NULL"; - case NaN: return "NaN"; - case BAD_DATA: return "BAD_DATA"; - case BAD_TYPE: return "BAD_TYPE"; - case ERR_OVERFLOW: return "ERR_OVERFLOW"; - case UNKNOWN_PROP: return "UNKNOWN_PROP"; - case DIV_BY_ZERO: return "DIV_BY_ZERO"; - case OUT_OF_RANGE: return "OUT_OF_RANGE"; - default: return "Unknown type: " + nullType; + case __NULL__: + return "NULL"; + case NaN: + return "NaN"; + case BAD_DATA: + return "BAD_DATA"; + case BAD_TYPE: + return "BAD_TYPE"; + case ERR_OVERFLOW: + return "ERR_OVERFLOW"; + case UNKNOWN_PROP: + return "UNKNOWN_PROP"; + case DIV_BY_ZERO: + return "DIV_BY_ZERO"; + case OUT_OF_RANGE: + return "OUT_OF_RANGE"; + default: + return "Unknown type: " + nullType; } } } @@ -88,13 +97,15 @@ private String descType() { return "DATASET"; case Value.GGVAL: return "GEOGRAPHY"; + case Value.DUVAL: + return "DURATION"; default: throw new IllegalArgumentException("Unknown field id " + value.getSetField()); } } /** - * @param value the Value get from service + * @param value the Value get from service * @param decodeType the decodeType get from the service to decode the byte array, * but now the service no return the decodeType, so use the utf-8 */ @@ -105,9 +116,9 @@ public ValueWrapper(Value value, String decodeType) { } /** - * @param value the Value get from service - * @param decodeType the decodeType get from the service to decode the byte array, - * but now the service no return the decodeType, so use the utf-8 + * @param value the Value get from service + * @param decodeType the decodeType get from the service to decode the byte array, + * but now the service no return the decodeType, so use the utf-8 * @param timezoneOffset the timezone offset get from the service to calculate local time */ public ValueWrapper(Value value, String decodeType, int timezoneOffset) { @@ -118,6 +129,7 @@ public ValueWrapper(Value value, String decodeType, int timezoneOffset) { /** * get the original data structure, the Value is the return from nebula-graph + * * @return Value */ public Value getValue() { @@ -126,6 +138,7 @@ public Value getValue() { /** * judge the Value is Empty type, the Empty type is the nebula's type + * * @return boolean */ public boolean isEmpty() { @@ -134,6 +147,7 @@ public boolean isEmpty() { /** * judge the Value is Null type,the Null type is the nebula's type + * * @return boolean */ public boolean isNull() { @@ -142,6 +156,7 @@ public boolean isNull() { /** * judge the Value is Boolean type + * * @return boolean */ public boolean isBoolean() { @@ -150,6 +165,7 @@ public boolean isBoolean() { /** * judge the Value is Long type + * * @return boolean */ public boolean isLong() { @@ -158,6 +174,7 @@ public boolean isLong() { /** * judge the Value is Double type + * * @return boolean */ public boolean isDouble() { @@ -166,6 +183,7 @@ public boolean isDouble() { /** * judge the Value is String type + * * @return boolean */ public boolean isString() { @@ -174,6 +192,7 @@ public boolean isString() { /** * judge the Value is List type, the List type is the nebula's type + * * @return boolean */ public boolean isList() { @@ -182,6 +201,7 @@ public boolean isList() { /** * judge the Value is Set type, the Set type is the nebula's type + * * @return boolean */ public boolean isSet() { @@ -190,6 +210,7 @@ public boolean isSet() { /** * judge the Value is Map type, the Map type is the nebula's type + * * @return boolean */ public boolean isMap() { @@ -198,6 +219,7 @@ public boolean isMap() { /** * judge the Value is Time type, the Time type is the nebula's type + * * @return boolean */ public boolean isTime() { @@ -206,6 +228,7 @@ public boolean isTime() { /** * judge the Value is Date type, the Date type is the nebula's type + * * @return boolean */ public boolean isDate() { @@ -214,6 +237,7 @@ public boolean isDate() { /** * judge the Value is DateTime type, the DateTime type is the nebula's type + * * @return boolean */ public boolean isDateTime() { @@ -222,6 +246,7 @@ public boolean isDateTime() { /** * judge the Value is Vertex type, the Vertex type is the nebula's type + * * @return boolean */ public boolean isVertex() { @@ -230,6 +255,7 @@ public boolean isVertex() { /** * judge the Value is Edge type, the Edge type is the nebula's type + * * @return boolean */ public boolean isEdge() { @@ -238,6 +264,7 @@ public boolean isEdge() { /** * judge the Value is Path type, the Path type is the nebula's type + * * @return boolean */ public boolean isPath() { @@ -246,20 +273,31 @@ public boolean isPath() { /** * judge the Value is Geography type, the Geography type is the nebula's type + * * @return boolean */ public boolean isGeography() { return value.getSetField() == Value.GGVAL; } + /** + * judge the Value is Duration type, the Duration type is the nebula's type + * + * @return boolean + */ + public boolean isDuration() { + return value.getSetField() == Value.DUVAL; + } + /** * Convert the original data type Value to NullType + * * @return NullType * @throws InvalidValueException if the value type is not null */ public NullType asNull() throws InvalidValueException { if (value.getSetField() == Value.NVAL) { - return new NullType(((com.vesoft.nebula.NullType)value.getFieldValue()).getValue()); + return new NullType(((com.vesoft.nebula.NullType) value.getFieldValue()).getValue()); } else { throw new InvalidValueException( "Cannot get field nullType because value's type is " + descType()); @@ -268,25 +306,27 @@ public NullType asNull() throws InvalidValueException { /** * Convert the original data type Value to boolean + * * @return boolean * @throws InvalidValueException if the value type is not boolean */ public boolean asBoolean() throws InvalidValueException { if (value.getSetField() == Value.BVAL) { - return (boolean)(value.getFieldValue()); + return (boolean) (value.getFieldValue()); } throw new InvalidValueException( - "Cannot get field boolean because value's type is " + descType()); + "Cannot get field boolean because value's type is " + descType()); } /** * Convert the original data type Value to long + * * @return long * @throws InvalidValueException if the value type is not long */ public long asLong() throws InvalidValueException { if (value.getSetField() == Value.IVAL) { - return (long)(value.getFieldValue()); + return (long) (value.getFieldValue()); } else { throw new InvalidValueException( "Cannot get field long because value's type is " + descType()); @@ -295,13 +335,14 @@ public long asLong() throws InvalidValueException { /** * Convert the original data type Value to String + * * @return String - * @throws InvalidValueException if the value type is not string + * @throws InvalidValueException if the value type is not string * @throws UnsupportedEncodingException if decode bianry failed */ public String asString() throws InvalidValueException, UnsupportedEncodingException { if (value.getSetField() == Value.SVAL) { - return new String((byte[])value.getFieldValue(), decodeType); + return new String((byte[]) value.getFieldValue(), decodeType); } throw new InvalidValueException( "Cannot get field string because value's type is " + descType()); @@ -309,12 +350,13 @@ public String asString() throws InvalidValueException, UnsupportedEncodingExcept /** * Convert the original data type Value to double + * * @return double * @throws InvalidValueException if the value type is not double */ public double asDouble() throws InvalidValueException { if (value.getSetField() == Value.FVAL) { - return (double)value.getFieldValue(); + return (double) value.getFieldValue(); } throw new InvalidValueException( "Cannot get field double because value's type is " + descType()); @@ -322,13 +364,14 @@ public double asDouble() throws InvalidValueException { /** * Convert the original data type Value to ArrayList + * * @return ArrayList of ValueWrapper * @throws InvalidValueException if the value type is not list */ public ArrayList asList() throws InvalidValueException { if (value.getSetField() != Value.LVAL) { throw new InvalidValueException( - "Cannot get field type `list' because value's type is " + descType()); + "Cannot get field type `list' because value's type is " + descType()); } ArrayList values = new ArrayList<>(); for (Value value : value.getLVal().getValues()) { @@ -339,13 +382,14 @@ public ArrayList asList() throws InvalidValueException { /** * Convert the original data type Value to HashSet + * * @return HashSet of ValueWrapper * @throws InvalidValueException if the value type is not set */ public HashSet asSet() throws InvalidValueException { if (value.getSetField() != Value.UVAL) { throw new InvalidValueException( - "Cannot get field type `set' because value's type is " + descType()); + "Cannot get field type `set' because value's type is " + descType()); } HashSet values = new HashSet<>(); for (Value value : value.getUVal().getValues()) { @@ -356,14 +400,15 @@ public HashSet asSet() throws InvalidValueException { /** * Convert the original data type Value to HashMap + * * @return HashMap, the key is String, value is ValueWrapper * @throws InvalidValueException if the value type is not map */ public HashMap asMap() - throws InvalidValueException, UnsupportedEncodingException { + throws InvalidValueException, UnsupportedEncodingException { if (value.getSetField() != Value.MVAL) { throw new InvalidValueException( - "Cannot get field type `set' because value's type is " + descType()); + "Cannot get field type `set' because value's type is " + descType()); } HashMap kvs = new HashMap<>(); Map inValues = value.getMVal().getKvs(); @@ -376,21 +421,23 @@ public HashMap asMap() /** * Convert the original data type Value to TimeWrapper + * * @return TimeWrapper * @throws InvalidValueException if the value type is not time */ public TimeWrapper asTime() throws InvalidValueException { if (value.getSetField() == Value.TVAL) { return (TimeWrapper) new TimeWrapper(value.getTVal()) - .setDecodeType(decodeType) - .setTimezoneOffset(timezoneOffset); + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); } throw new InvalidValueException( - "Cannot get field time because value's type is " + descType()); + "Cannot get field time because value's type is " + descType()); } /** * Convert the original data type Value to DateWrapper + * * @return DateWrapper * @throws InvalidValueException if the value type is not date */ @@ -399,35 +446,37 @@ public DateWrapper asDate() throws InvalidValueException { return new DateWrapper(value.getDVal()); } throw new InvalidValueException( - "Cannot get field date because value's type is " + descType()); + "Cannot get field date because value's type is " + descType()); } /** * Convert the original data type Value to DateTimeWrapper + * * @return DateTimeWrapper * @throws InvalidValueException if the value type is not datetime */ public DateTimeWrapper asDateTime() throws InvalidValueException { if (value.getSetField() == Value.DTVAL) { return (DateTimeWrapper) new DateTimeWrapper(value.getDtVal()) - .setDecodeType(decodeType) - .setTimezoneOffset(timezoneOffset); + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); } throw new InvalidValueException( - "Cannot get field datetime because value's type is " + descType()); + "Cannot get field datetime because value's type is " + descType()); } /** * Convert the original data type Value to Node + * * @return Node - * @throws InvalidValueException if the value type is not vertex + * @throws InvalidValueException if the value type is not vertex * @throws UnsupportedEncodingException if decode binary failed */ - public Node asNode() throws InvalidValueException, UnsupportedEncodingException { + public Node asNode() throws InvalidValueException, UnsupportedEncodingException { if (value.getSetField() == Value.VVAL) { return (Node) new Node(value.getVVal()) - .setDecodeType(decodeType) - .setTimezoneOffset(timezoneOffset); + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); } throw new InvalidValueException( "Cannot get field Node because value's type is " + descType()); @@ -442,8 +491,8 @@ public Node asNode() throws InvalidValueException, UnsupportedEncodingException public Relationship asRelationship() throws InvalidValueException { if (value.getSetField() == Value.EVAL) { return (Relationship) new Relationship(value.getEVal()) - .setDecodeType(decodeType) - .setTimezoneOffset(timezoneOffset); + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); } throw new InvalidValueException( "Cannot get field Relationship because value's type is " + descType()); @@ -451,15 +500,16 @@ public Relationship asRelationship() throws InvalidValueException { /** * Convert the original data type Value to Path + * * @return PathWrapper - * @throws InvalidValueException if the value type is not path + * @throws InvalidValueException if the value type is not path * @throws UnsupportedEncodingException if decode bianry failed */ public PathWrapper asPath() throws InvalidValueException, UnsupportedEncodingException { if (value.getSetField() == Value.PVAL) { return (PathWrapper) new PathWrapper(value.getPVal()) - .setDecodeType(decodeType) - .setTimezoneOffset(timezoneOffset); + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); } throw new InvalidValueException( "Cannot get field PathWrapper because value's type is " + descType()); @@ -467,6 +517,7 @@ public PathWrapper asPath() throws InvalidValueException, UnsupportedEncodingExc /** * Convert the original data type Value to geography + * * @return GeographyWrapper * @throws InvalidValueException if the value type is not geography */ @@ -480,6 +531,22 @@ public GeographyWrapper asGeography() throws InvalidValueException { "Cannot get field GeographyWrapper because value's type is " + descType()); } + /** + * Convert the original data type Value to duration + * + * @return DurationWrapper + * @throws InvalidValueException if the value type is not duration + */ + public DurationWrapper asDuration() throws InvalidValueException { + if (value.getSetField() == Value.DUVAL) { + return (DurationWrapper) new DurationWrapper(value.getDuVal()) + .setDecodeType(decodeType) + .setTimezoneOffset(timezoneOffset); + } + throw new InvalidValueException("Cannot get field DurationWrapper because value's type is " + + descType()); + } + @Override public boolean equals(Object o) { if (this == o) { @@ -490,7 +557,7 @@ public boolean equals(Object o) { } ValueWrapper that = (ValueWrapper) o; return Objects.equals(value, that.value) - && Objects.equals(decodeType, that.decodeType); + && Objects.equals(decodeType, that.decodeType); } @Override @@ -500,6 +567,7 @@ public int hashCode() { /** * Convert Value to String format + * * @return String */ @Override diff --git a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java index 9e30afeee..1a2951a19 100644 --- a/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java +++ b/client/src/main/java/com/vesoft/nebula/client/storage/data/BaseTableRow.java @@ -7,6 +7,7 @@ import com.vesoft.nebula.client.graph.data.DateTimeWrapper; import com.vesoft.nebula.client.graph.data.DateWrapper; +import com.vesoft.nebula.client.graph.data.DurationWrapper; import com.vesoft.nebula.client.graph.data.GeographyWrapper; import com.vesoft.nebula.client.graph.data.TimeWrapper; import com.vesoft.nebula.client.graph.data.ValueWrapper; @@ -72,6 +73,10 @@ public GeographyWrapper getGeography(int i) { return values.get(i).asGeography(); } + public DurationWrapper getDuration(int i) { + return values.get(i).asDuration(); + } + public List getValues() { return values; } diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java index b0175a7e4..bd1a369ed 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java @@ -9,6 +9,7 @@ import com.vesoft.nebula.DataSet; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Duration; import com.vesoft.nebula.Edge; import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.Geography; @@ -94,58 +95,57 @@ public Path getPath(String startId, int stepsNum) { } - public Vertex getSimpleVertex() { Map props1 = new HashMap<>(); - props1.put("tag1_prop".getBytes(), new Value(Value.IVAL, (long)100)); + props1.put("tag1_prop".getBytes(), new Value(Value.IVAL, (long) 100)); Map props2 = new HashMap<>(); - props2.put("tag2_prop".getBytes(), new Value(Value.IVAL, (long)200)); + props2.put("tag2_prop".getBytes(), new Value(Value.IVAL, (long) 200)); List tags = Arrays.asList(new Tag("tag1".getBytes(), props1), - new Tag("tag2".getBytes(), props2)); + new Tag("tag2".getBytes(), props2)); return new Vertex(new Value(Value.SVAL, "vertex".getBytes()), tags); } public Edge getSimpleEdge(boolean isReverse) { Map props = new HashMap<>(); - props.put("edge_prop".getBytes(), new Value(Value.IVAL, (long)100)); + props.put("edge_prop".getBytes(), new Value(Value.IVAL, (long) 100)); int type = 1; if (isReverse) { type = -1; } return new Edge(new Value(Value.SVAL, "Tom".getBytes()), - new Value(Value.SVAL, "Lily".getBytes()), - type, - "classmate".getBytes(), - 10, - props); + new Value(Value.SVAL, "Lily".getBytes()), + type, + "classmate".getBytes(), + 10, + props); } public Path getSimplePath(boolean isReverse) { Map props1 = new HashMap<>(); - props1.put("tag1_prop".getBytes(), new Value(Value.IVAL, (long)200)); + props1.put("tag1_prop".getBytes(), new Value(Value.IVAL, (long) 200)); List tags2 = Collections.singletonList(new Tag("tag1".getBytes(), props1)); Vertex vertex1 = new Vertex(new Value(Value.SVAL, "vertex1".getBytes()), tags2); List steps = new ArrayList<>(); Map props3 = new HashMap<>(); - props3.put("edge1_prop".getBytes(), new Value(Value.IVAL, (long)100)); + props3.put("edge1_prop".getBytes(), new Value(Value.IVAL, (long) 100)); steps.add(new Step(vertex1, 1, "classmate".getBytes(), 100, props3)); Map props2 = new HashMap<>(); - props2.put("tag2_prop".getBytes(), new Value(Value.IVAL, (long)300)); + props2.put("tag2_prop".getBytes(), new Value(Value.IVAL, (long) 300)); List tags3 = Collections.singletonList(new Tag("tag2".getBytes(), props2)); Vertex vertex2 = new Vertex(new Value(Value.SVAL, "vertex2".getBytes()), tags3); Map props4 = new HashMap<>(); - props4.put("edge2_prop".getBytes(), new Value(Value.IVAL, (long)200)); + props4.put("edge2_prop".getBytes(), new Value(Value.IVAL, (long) 200)); steps.add(new Step(vertex2, isReverse ? -1 : 1, "classmate".getBytes(), 10, props4)); Map props0 = new HashMap<>(); - props0.put("tag0_prop".getBytes(), new Value(Value.IVAL, (long)100)); + props0.put("tag0_prop".getBytes(), new Value(Value.IVAL, (long) 100)); List tags1 = Collections.singletonList(new Tag("tag0".getBytes(), props0)); Vertex vertex0 = new Vertex(new Value(Value.SVAL, "vertex0".getBytes()), tags1); return new Path(vertex0, steps); @@ -171,11 +171,11 @@ public DataSet getDateset() { new Value(Value.LVAL, new NList(list)), new Value(Value.UVAL, new NSet(set)), new Value(Value.MVAL, new NMap(map)), - new Value(Value.TVAL, new Time((byte)10, (byte)30, (byte)0, 100)), - new Value(Value.DVAL, new Date((short)2020, (byte)10, (byte)10)), + new Value(Value.TVAL, new Time((byte) 10, (byte) 30, (byte) 0, 100)), + new Value(Value.DVAL, new Date((short) 2020, (byte) 10, (byte) 10)), new Value(Value.DTVAL, - new DateTime((short)2020, (byte)10, - (byte)10, (byte)10, (byte)30, (byte)0, 100)), + new DateTime((short) 2020, (byte) 10, + (byte) 10, (byte) 10, (byte) 30, (byte) 0, 100)), new Value(Value.VVAL, getVertex("Tom")), new Value(Value.EVAL, getEdge("Tom", "Lily")), new Value(Value.PVAL, getPath("Tom", 3)), @@ -184,30 +184,32 @@ public DataSet getDateset() { new Value(Value.GGVAL, new Geography(Geography.PGVAL, new Polygon(Arrays.asList( Arrays.asList(new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0)), Arrays.asList(new Coordinate(3.0, 6.0), new Coordinate(4.0, 8.0)) - )))), + )))), new Value(Value.GGVAL, new Geography(Geography.LSVAL, new LineString(Arrays.asList( new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0) - )))))); + )))), + new Value(Value.DUVAL, new Duration(100, 20, 1)))); final List columnNames = Arrays.asList( - "col0_empty".getBytes(), - "col1_null".getBytes(), - "col2_bool".getBytes(), - "col3_int".getBytes(), - "col4_double".getBytes(), - "col5_string".getBytes(), - "col6_list".getBytes(), - "col7_set".getBytes(), - "col8_map".getBytes(), - "col9_time".getBytes(), - "col10_date".getBytes(), - "col11_datetime".getBytes(), - "col12_vertex".getBytes(), - "col13_edge".getBytes(), - "col14_path".getBytes(), - "col15_point".getBytes(), - "col16_polygon".getBytes(), - "col17_linestring".getBytes()); + "col0_empty".getBytes(), + "col1_null".getBytes(), + "col2_bool".getBytes(), + "col3_int".getBytes(), + "col4_double".getBytes(), + "col5_string".getBytes(), + "col6_list".getBytes(), + "col7_set".getBytes(), + "col8_map".getBytes(), + "col9_time".getBytes(), + "col10_date".getBytes(), + "col11_datetime".getBytes(), + "col12_vertex".getBytes(), + "col13_edge".getBytes(), + "col14_path".getBytes(), + "col15_point".getBytes(), + "col16_polygon".getBytes(), + "col17_linestring".getBytes(), + "col18_duration".getBytes()); return new DataSet(columnNames, Collections.singletonList(row)); } @@ -222,10 +224,10 @@ public void testNode() { node.keys("tag0").stream().sorted().collect(Collectors.toList()), names.stream().sorted().collect(Collectors.toList())); List propValues = Arrays.asList(new Value(Value.IVAL, 0L), - new Value(Value.IVAL, 1L), - new Value(Value.IVAL, 2L), - new Value(Value.IVAL, 3L), - new Value(Value.IVAL, 4L)); + new Value(Value.IVAL, 1L), + new Value(Value.IVAL, 2L), + new Value(Value.IVAL, 3L), + new Value(Value.IVAL, 4L)); // TODO: Check the List } catch (Exception e) { @@ -253,14 +255,14 @@ public void testRelationShip() { // check get values List values = relationShip.values(); assert values.get(0).isLong(); - ArrayList longVals = new ArrayList<>(); + ArrayList longVals = new ArrayList<>(); for (ValueWrapper val : values) { assert val.isLong(); longVals.add(val.asLong()); } List expectVals = Arrays.asList(0L, 1L, 2L, 3L, 4L); assert Objects.equals(expectVals, - longVals.stream().sorted().collect(Collectors.toList())); + longVals.stream().sorted().collect(Collectors.toList())); // check properties HashMap properties = relationShip.properties(); @@ -307,11 +309,11 @@ public void testPathWrapper() { for (int i = 0; i < 4; i++) { if (i % 2 == 0) { relationships.add(new Relationship(getEdge(String.format("vertex%d", i + 1), - String.format("vertex%d", i)))); + String.format("vertex%d", i)))); } else { relationships.add( new Relationship(getEdge(String.format("vertex%d", i), - String.format("vertex%d", i + 1)))); + String.format("vertex%d", i + 1)))); } } @@ -326,7 +328,7 @@ public void testPathWrapper() { @Test public void testResult() { try { - ExecutionResponse resp = new ExecutionResponse(); + ExecutionResponse resp = new ExecutionResponse(); resp.error_code = ErrorCode.SUCCEEDED; resp.error_msg = "test".getBytes(); resp.comment = "test_comment".getBytes(); @@ -343,14 +345,16 @@ public void testResult() { Assert.assertEquals(1000, resultSet.getLatency()); assert resultSet.getPlanDesc() != null; List expectColNames = Arrays.asList( - "col0_empty", "col1_null", "col2_bool", "col3_int", "col4_double", "col5_string", - "col6_list", "col7_set", "col8_map", "col9_time", "col10_date", "col11_datetime", - "col12_vertex", "col13_edge", "col14_path", "col15_point", "col16_polygon", - "col17_linestring"); + "col0_empty", "col1_null", "col2_bool", "col3_int", "col4_double", + "col5_string", + "col6_list", "col7_set", "col8_map", "col9_time", "col10_date", + "col11_datetime", + "col12_vertex", "col13_edge", "col14_path", "col15_point", "col16_polygon", + "col17_linestring", "col18_duration"); assert Objects.equals(resultSet.keys(), expectColNames); assert resultSet.getRows().size() == 1; ResultSet.Record record = resultSet.rowValues(0); - assert record.size() == 18; + assert record.size() == 19; assert record.get(0).isEmpty(); assert record.get(1).isNull(); @@ -369,12 +373,12 @@ public void testResult() { assert Objects.equals("value1", record.get(5).asString()); Assert.assertArrayEquals( - record.get(6).asList().stream().map(ValueWrapper::asLong).toArray(), - Arrays.asList((long)1, (long)2).toArray()); + record.get(6).asList().stream().map(ValueWrapper::asLong).toArray(), + Arrays.asList((long) 1, (long) 2).toArray()); assert record.get(7).isSet(); Set set = record.get(7).asSet().stream().map(ValueWrapper::asLong) - .collect(Collectors.toSet()); + .collect(Collectors.toSet()); assert set.size() == 2; assert set.contains((long) 1); assert set.contains((long) 2); @@ -383,61 +387,61 @@ public void testResult() { HashMap map = record.get(8).asMap(); assert map.keySet().size() == 2; Assert.assertArrayEquals(map.keySet().toArray(), - Arrays.asList("key1", "key2").toArray()); + Arrays.asList("key1", "key2").toArray()); Assert.assertArrayEquals(map.values().stream().map(ValueWrapper::asLong).toArray(), - Arrays.asList((long)1, (long)2).toArray()); + Arrays.asList((long) 1, (long) 2).toArray()); assert record.get(9).isTime(); assert record.get(9).asTime() instanceof TimeWrapper; TimeWrapper timeWrapper = (TimeWrapper) new TimeWrapper( - new Time((byte)10, (byte)30, (byte)0, 100)).setTimezoneOffset(28800); + new Time((byte) 10, (byte) 30, (byte) 0, 100)).setTimezoneOffset(28800); assert Objects.equals(record.get(9).asTime(), timeWrapper); Assert.assertEquals("utc time: 10:30:00.000100, timezoneOffset: 28800", - timeWrapper.toString()); + timeWrapper.toString()); Assert.assertEquals("18:30:00.000100", timeWrapper.getLocalTimeStr()); Assert.assertEquals("10:30:00.000100", timeWrapper.getUTCTimeStr()); Assert.assertEquals(new Time( - (byte)18, (byte)30, (byte)0, 100), timeWrapper.getLocalTime()); + (byte) 18, (byte) 30, (byte) 0, 100), timeWrapper.getLocalTime()); assert record.get(10).isDate(); assert record.get(10).asDate() instanceof DateWrapper; - DateWrapper dateWrapper = new DateWrapper(new Date((short)2020, (byte)10, (byte)10)); + DateWrapper dateWrapper = new DateWrapper(new Date((short) 2020, (byte) 10, (byte) 10)); assert Objects.equals(record.get(10).asDate(), dateWrapper); Assert.assertEquals("2020-10-10", dateWrapper.toString()); assert record.get(11).isDateTime(); DateTimeWrapper dateTimeWrapper = (DateTimeWrapper) new DateTimeWrapper( - new DateTime((short)2020, (byte)10, - (byte)10, (byte)10, (byte)30, (byte)0, 100)).setTimezoneOffset(28800); + new DateTime((short) 2020, (byte) 10, (byte) 10, (byte) 10, (byte) 30, + (byte) 0, 100)).setTimezoneOffset(28800); assert record.get(11).asDateTime() instanceof DateTimeWrapper; assert Objects.equals(record.get(11).asDateTime(), dateTimeWrapper); Assert.assertEquals("utc datetime: 2020-10-10T10:30:00.000100, timezoneOffset: 28800", - dateTimeWrapper.toString()); + dateTimeWrapper.toString()); Assert.assertEquals("2020-10-10T18:30:00.000100", - dateTimeWrapper.getLocalDateTimeStr()); + dateTimeWrapper.getLocalDateTimeStr()); Assert.assertEquals("2020-10-10T10:30:00.000100", - dateTimeWrapper.getUTCDateTimeStr()); + dateTimeWrapper.getUTCDateTimeStr()); Assert.assertEquals( - new DateTime((short)2020, (byte)10, - (byte)10, (byte)18, (byte)30, (byte)0, 100), - dateTimeWrapper.getLocalDateTime()); + new DateTime((short) 2020, (byte) 10, + (byte) 10, (byte) 18, (byte) 30, (byte) 0, 100), + dateTimeWrapper.getLocalDateTime()); assert record.get(12).isVertex(); assert Objects.equals(record.get(12).asNode(), - new Node(getVertex("Tom"))); + new Node(getVertex("Tom"))); assert record.get(13).isEdge(); assert Objects.equals(record.get(13).asRelationship(), - new Relationship(getEdge("Tom", "Lily"))); + new Relationship(getEdge("Tom", "Lily"))); assert record.get(14).isPath(); assert Objects.equals(record.get(14).asPath(), - new PathWrapper(getPath("Tom", 3))); + new PathWrapper(getPath("Tom", 3))); assert resultSet.toString().length() > 100; assert record.get(15).isGeography(); assert Objects.equals(record.get(15).asGeography().toString(), - new PointWrapper(new Point(new Coordinate(1.0, 2.0))).toString()); + new PointWrapper(new Point(new Coordinate(1.0, 2.0))).toString()); assert record.get(16).isGeography(); assert Objects.equals(record.get(16).asGeography().toString(), @@ -452,6 +456,10 @@ public void testResult() { new Coordinate(1.0, 2.0), new Coordinate(2.0, 4.0) ))).toString()); + + assert record.get(18).isDuration(); + assert Objects.equals(record.get(18).asDuration(), + new DurationWrapper(new Duration(100, 20, 1))); } catch (Exception e) { e.printStackTrace(); assert (false); @@ -463,43 +471,43 @@ public void testToString() { try { // test node ValueWrapper valueWrapper = new ValueWrapper( - new Value(Value.VVAL, getSimpleVertex()), "utf-8",28800); + new Value(Value.VVAL, getSimpleVertex()), "utf-8", 28800); String expectString = - "(\"vertex\" :tag1 {tag1_prop: 100} :tag2 {tag2_prop: 200})"; + "(\"vertex\" :tag1 {tag1_prop: 100} :tag2 {tag2_prop: 200})"; Assert.assertEquals(expectString, valueWrapper.asNode().toString()); // test relationship valueWrapper = new ValueWrapper( - new Value(Value.EVAL, getSimpleEdge(false)), "utf-8", 28800); + new Value(Value.EVAL, getSimpleEdge(false)), "utf-8", 28800); expectString = "(\"Tom\")-[:classmate@10{edge_prop: 100}]->(\"Lily\")"; Assert.assertEquals(expectString, valueWrapper.asRelationship().toString()); valueWrapper = new ValueWrapper( - new Value(Value.EVAL, getSimpleEdge(true)), "utf-8", 28800); + new Value(Value.EVAL, getSimpleEdge(true)), "utf-8", 28800); expectString = "(\"Lily\")-[:classmate@10{edge_prop: 100}]->(\"Tom\")"; Assert.assertEquals(expectString, valueWrapper.asRelationship().toString()); // test path valueWrapper = new ValueWrapper( - new Value(Value.PVAL, getSimplePath(true)), "utf-8", 28800); - expectString = - "(\"vertex0\" :tag0 {tag0_prop: 100})" + new Value(Value.PVAL, getSimplePath(true)), "utf-8", 28800); + expectString = "(\"vertex0\" :tag0 {tag0_prop: 100})" + "-[:classmate@100{edge1_prop: 100}]->" + "(\"vertex1\" :tag1 {tag1_prop: 200})<-[:classmate@10{edge2_prop: 200}]-" + "(\"vertex2\" :tag2 {tag2_prop: 300})"; Assert.assertEquals(expectString, valueWrapper.asPath().toString()); valueWrapper = new ValueWrapper( - new Value(Value.PVAL, getSimplePath(false)), "utf-8", 28800); - expectString = - "(\"vertex0\" :tag0 {tag0_prop: 100})" + new Value(Value.PVAL, getSimplePath(false)), "utf-8", 28800); + expectString = "(\"vertex0\" :tag0 {tag0_prop: 100})" + "-[:classmate@100{edge1_prop: 100}]->" + "(\"vertex1\" :tag1 {tag1_prop: 200})-[:classmate@10{edge2_prop: 200}]->" + "(\"vertex2\" :tag2 {tag2_prop: 300})"; Assert.assertEquals(expectString, valueWrapper.asPath().toString()); + // test Geography valueWrapper = new ValueWrapper( - new Value(Value.GGVAL, new Geography(Geography.PTVAL, new Point(new Coordinate(1.0, - 2.0)))), "utf-8", 28800); + new Value(Value.GGVAL, new Geography(Geography.PTVAL, + new Point(new Coordinate(1.0, + 2.0)))), "utf-8", 28800); expectString = "POINT(1.0 2.0)"; Assert.assertEquals(expectString, valueWrapper.asGeography().toString()); @@ -513,12 +521,21 @@ public void testToString() { valueWrapper = new ValueWrapper( new Value(Value.GGVAL, new Geography(Geography.LSVAL, - new LineString(Arrays.asList( - new Coordinate(1.0, 2.0), - new Coordinate(2.0, 4.0) - )))), "utf-8", 28800); + new LineString(Arrays.asList( + new Coordinate(1.0, 2.0), + new Coordinate(2.0, 4.0) + )))), "utf-8", 28800); expectString = "LINESTRING(1.0 2.0,2.0 4.0)"; Assert.assertEquals(expectString, valueWrapper.asGeography().toString()); + + // test Duration + valueWrapper = new ValueWrapper(new Value(Value.DUVAL, new Duration(100, 20, 1)), + "utf-8", 28800); + expectString = "P1M0DT100.00002S"; + String expectDurationString = "duration({months:1, seconds:100, microseconds:20})"; + Assert.assertEquals(expectString, valueWrapper.asDuration().toString()); + Assert.assertEquals(expectDurationString, + valueWrapper.asDuration().getDurationString()); } catch (Exception e) { e.printStackTrace(); assert (false); diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java index 571a65273..b2479166d 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestDataFromServer.java @@ -10,6 +10,7 @@ import com.vesoft.nebula.Coordinate; import com.vesoft.nebula.Date; import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Duration; import com.vesoft.nebula.ErrorCode; import com.vesoft.nebula.Geography; import com.vesoft.nebula.LineString; @@ -58,7 +59,8 @@ public void setUp() throws Exception { + "CREATE EDGE IF NOT EXISTS like(likeness double);" + "CREATE EDGE IF NOT EXISTS friend(start_year int, end_year int);" + "CREATE TAG INDEX IF NOT EXISTS person_name_index ON person(name(8));" - + "CREATE TAG IF NOT EXISTS any_shape(geo geography);"); + + "CREATE TAG IF NOT EXISTS any_shape(geo geography);" + + "CREATE TAG IF NOT EXISTS tag_duration(col duration);"); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); TimeUnit.SECONDS.sleep(10); String insertVertexes = "INSERT VERTEX person(name, age, grade,friends, book_num, " @@ -122,6 +124,11 @@ public void setUp() throws Exception { + "(ST_GeogFromText('POLYGON((0 1, 1 2, 2 3, 0 1))'));"; resp = session.execute(insertShape); Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); + + String insertDuration = "INSERT VERTEX tag_duration(col) VALUES 'duration':" + + "(duration({months:1, seconds:100, microseconds:20}));"; + resp = session.execute(insertDuration); + Assert.assertTrue(resp.getErrorMessage(), resp.isSucceeded()); } @After @@ -267,6 +274,26 @@ public void testAllSchemaType() { Assert.assertEquals(geographyWrapper.toString(), properties.get("geo").asGeography().toString()); + result = session.execute( + "FETCH PROP ON tag_duration 'duration' yield vertex as vertices_"); + Assert.assertTrue(result.isSucceeded()); + Assert.assertEquals("", result.getErrorMessage()); + Assert.assertFalse(result.getLatency() <= 0); + Assert.assertEquals("", result.getComment()); + Assert.assertEquals(ErrorCode.SUCCEEDED.getValue(), result.getErrorCode()); + Assert.assertEquals("test_data", result.getSpaceName()); + Assert.assertFalse(result.isEmpty()); + Assert.assertEquals(1, result.rowsSize()); + + Assert.assertTrue(result.rowValues(0).get(0).isVertex()); + node = result.rowValues(0).get(0).asNode(); + Assert.assertEquals("duration", node.getId().asString()); + Assert.assertEquals(Arrays.asList("tag_duration"), node.tagNames()); + properties = node.properties("tag_duration"); + DurationWrapper durationWrapper = new DurationWrapper(new Duration(100, 20, 1)); + Assert.assertEquals(durationWrapper, properties.get("col").asDuration()); + Assert.assertEquals(durationWrapper.toString(), + properties.get("col").asDuration().toString()); } catch (IOErrorException | UnsupportedEncodingException e) { e.printStackTrace(); From b357796f454335ee7c17b52d81555b690f480074 Mon Sep 17 00:00:00 2001 From: Anqi Date: Thu, 30 Dec 2021 17:37:57 +0800 Subject: [PATCH 21/25] update duration toString (#414) * update duration toString * repush to trigger cla --- .../vesoft/nebula/client/graph/data/DurationWrapper.java | 8 ++++---- .../com/vesoft/nebula/client/graph/data/TestData.java | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java b/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java index 256048926..f04008404 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/data/DurationWrapper.java @@ -50,10 +50,10 @@ public String getDurationString() { @Override public String toString() { - long year = duration.seconds / (60 * 60 * 24); - long remainSeconds = duration.seconds - (year) * (60 * 60 * 24); - return String.format("P%dM%dDT%sS", - duration.months, year, remainSeconds + duration.microseconds / 1000000.0); + long totalSeconds = duration.seconds + duration.microseconds / 1000000; + int remainMicroSeconds = duration.microseconds % 1000000; + String microSends = String.format("%06d", remainMicroSeconds) + "000"; + return String.format("P%dMT%d.%sS", duration.months, totalSeconds, microSends); } @Override diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java index bd1a369ed..25f1f2333 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/data/TestData.java @@ -531,11 +531,12 @@ public void testToString() { // test Duration valueWrapper = new ValueWrapper(new Value(Value.DUVAL, new Duration(100, 20, 1)), "utf-8", 28800); - expectString = "P1M0DT100.00002S"; + expectString = "P1MT100.000020000S"; String expectDurationString = "duration({months:1, seconds:100, microseconds:20})"; Assert.assertEquals(expectString, valueWrapper.asDuration().toString()); Assert.assertEquals(expectDurationString, valueWrapper.asDuration().getDurationString()); + } catch (Exception e) { e.printStackTrace(); assert (false); From 516abb75877dd22ebe20a797779c83cee2c28a92 Mon Sep 17 00:00:00 2001 From: "kyle.cao" <2426009680@qq.com> Date: Fri, 31 Dec 2021 14:52:11 +0800 Subject: [PATCH 22/25] add parameter related interface (#412) * support cypher parameter * small change --- .../nebula/client/graph/net/Session.java | 215 ++++++++++++++++-- .../client/graph/net/SyncConnection.java | 37 ++- .../nebula/client/graph/net/TestSession.java | 82 +++++++ .../nebula/examples/GraphClientExample.java | 36 +++ 4 files changed, 347 insertions(+), 23 deletions(-) diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java index 940843617..4cc020a4d 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java @@ -5,10 +5,23 @@ package com.vesoft.nebula.client.graph.net; +import com.vesoft.nebula.Date; +import com.vesoft.nebula.DateTime; +import com.vesoft.nebula.Duration; +import com.vesoft.nebula.Geography; +import com.vesoft.nebula.NList; +import com.vesoft.nebula.NMap; +import com.vesoft.nebula.NullType; +import com.vesoft.nebula.Time; +import com.vesoft.nebula.Value; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.graph.ExecutionResponse; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; import java.util.concurrent.atomic.AtomicBoolean; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -22,8 +35,8 @@ * The data type obtained by the user is `ValueWrapper`, * which is the wrapper of the original data structure Value returned by the server. * The user can directly read the data using the interface of ValueWrapper. - * */ + public class Session { private final long sessionID; private final int timezoneOffset; @@ -36,9 +49,9 @@ public class Session { /** * Constructor * - * @param connection the connection from the pool - * @param authResult the auth result from graph service - * @param connPool the connection pool + * @param connection the connection from the pool + * @param authResult the auth result from graph service + * @param connPool the connection pool * @param retryConnect whether to retry after the connection is disconnected */ public Session(SyncConnection connection, @@ -61,23 +74,43 @@ public Session(SyncConnection connection, */ public synchronized ResultSet execute(String stmt) throws IOErrorException { + return executeWithParameter(stmt, + (Map) Collections.EMPTY_MAP); + } + + /** + * Execute the nGql sentence. + * + * @param stmt The nGql sentence. + * such as insert ngql `INSERT VERTEX person(name) VALUES "Tom":("Tom");` + * @param parameterMap The nGql parameter map + * @return The ResultSet + */ + public synchronized ResultSet executeWithParameter( + String stmt, + Map parameterMap) + throws IOErrorException { if (connection == null) { throw new IOErrorException(IOErrorException.E_CONNECT_BROKEN, - "The session was released, couldn't use again."); + "The session was released, couldn't use again."); } + Map map = new HashMap<>(); + parameterMap.entrySet().stream() + .forEach(x -> map.put(x.getKey().getBytes(), value2Nvalue(x.getValue()))); if (connectionIsBroken.get() && retryConnect) { if (retryConnect()) { - ExecutionResponse resp = connection.execute(sessionID, stmt); + ExecutionResponse resp = + connection.executeWithParameter(sessionID, stmt, map); return new ResultSet(resp, timezoneOffset); } else { throw new IOErrorException(IOErrorException.E_ALL_BROKEN, - "All servers are broken."); + "All servers are broken."); } } try { - ExecutionResponse resp = connection.execute(sessionID, stmt); + ExecutionResponse resp = connection.executeWithParameter(sessionID, stmt, map); return new ResultSet(resp, timezoneOffset); } catch (IOErrorException ie) { if (ie.getType() == IOErrorException.E_CONNECT_BROKEN) { @@ -87,7 +120,8 @@ public synchronized ResultSet execute(String stmt) throws if (retryConnect) { if (retryConnect()) { connectionIsBroken.set(false); - ExecutionResponse resp = connection.execute(sessionID, stmt); + ExecutionResponse resp = + connection.executeWithParameter(sessionID, stmt, map); return new ResultSet(resp, timezoneOffset); } else { connectionIsBroken.set(true); @@ -103,7 +137,7 @@ public synchronized ResultSet execute(String stmt) throws /** * Execute the nGql sentence. * Date and Datetime will be returned in UTC - * JSON struct: + * JSON struct: * { * "results":[ * { @@ -156,18 +190,88 @@ public synchronized ResultSet execute(String stmt) throws * } * @param stmt The nGql sentence. * such as insert ngql `INSERT VERTEX person(name) VALUES "Tom":("Tom");` + * parameterMap The nGql parameters * @return The JSON string */ public synchronized String executeJson(String stmt) throws IOErrorException { + return executeJsonWithParameter(stmt, + (Map) Collections.EMPTY_MAP); + } + + /** + * Execute the nGql sentence. + * Date and Datetime will be returned in UTC + * JSON struct: + * { + * "results":[ + * { + * "columns":[], + * "data":[ + * { + * "row":row-data, + * "meta":metadata + * } + * ], + * "latencyInUs":0, + * "spaceName":"", + * "planDesc ":{ + * "planNodeDescs":[ + * { + * "name":"", + * "id":0, + * "outputVar":"", + * "description":{ + * "key":"" + * }, + * "profiles":[ + * { + * "rows":1, + * "execDurationInUs":0, + * "totalDurationInUs":0, + * "otherStats":{} + * } + * ], + * "branchInfo":{ + * "isDoBranch":false, + * "conditionNodeId":-1 + * }, + * "dependencies":[] + * } + * ], + * "nodeIndexMap":{}, + * "format":"", + * "optimize_time_in_us":0 + * }, + * "comment ":"", + * } + * ], + * "errors":[ + * { + * "code": 0, + * "message": "" + * } + * ] + * } + * @param stmt The nGql sentence. + * such as insert ngql `INSERT VERTEX person(name) VALUES "Tom":("Tom");` + * parameterMap The nGql parameters + * @return The JSON string + */ + public synchronized String executeJsonWithParameter(String stmt, + Map parameterMap) throws + IOErrorException { if (connection == null) { throw new IOErrorException(IOErrorException.E_CONNECT_BROKEN, "The session was released, couldn't use again."); } + Map map = new HashMap<>(); + parameterMap.entrySet().stream() + .forEach(x -> map.put(x.getKey().getBytes(), value2Nvalue(x.getValue()))); if (connectionIsBroken.get() && retryConnect) { if (retryConnect()) { - return connection.executeJson(sessionID, stmt); + return connection.executeJsonWithParameter(sessionID, stmt, map); } else { throw new IOErrorException(IOErrorException.E_ALL_BROKEN, "All servers are broken."); @@ -175,7 +279,7 @@ public synchronized String executeJson(String stmt) throws } try { - return connection.executeJson(sessionID, stmt); + return connection.executeJsonWithParameter(sessionID, stmt, map); } catch (IOErrorException ie) { if (ie.getType() == IOErrorException.E_CONNECT_BROKEN) { connectionIsBroken.set(true); @@ -184,7 +288,7 @@ public synchronized String executeJson(String stmt) throws if (retryConnect) { if (retryConnect()) { connectionIsBroken.set(false); - return connection.executeJson(sessionID, stmt); + return connection.executeJsonWithParameter(sessionID, stmt, map); } else { connectionIsBroken.set(true); throw new IOErrorException(IOErrorException.E_ALL_BROKEN, @@ -260,4 +364,89 @@ private boolean retryConnect() { return false; } } + + /** + * convert java list to nebula thrift list + * @param list java list + * @return nebula list + */ + private NList list2Nlist(List list) throws UnsupportedOperationException { + NList nlist = new NList(); + for (Object item : list) { + nlist.values.add(value2Nvalue(item)); + } + return nlist; + } + + /** + * convert java map to nebula thrift map + * @param map java map + * @return nebula map + */ + private NMap map2Nmap(Map map) throws UnsupportedOperationException { + NMap nmap = new NMap(); + for (Map.Entry entry : map.entrySet()) { + nmap.kvs.put(entry.getKey().getBytes(), value2Nvalue(entry.getValue())); + } + return nmap; + } + + + /** + * convert java value type to nebula thrift value type + * @param value java obj + * @return nebula value + */ + private Value value2Nvalue(Object value) throws UnsupportedOperationException { + Value nvalue = new Value(); + if (value == null) { + nvalue.setNVal(NullType.__NULL__); + } else if (value instanceof Boolean) { + boolean bval = (Boolean)value; + nvalue.setBVal(bval); + } else if (value instanceof Integer) { + int ival = (Integer)value; + nvalue.setIVal(ival); + } else if (value instanceof Short) { + int ival = (Short)value; + nvalue.setIVal(ival); + } else if (value instanceof Byte) { + int ival = (Byte)value; + nvalue.setIVal(ival); + } else if (value instanceof Long) { + long ival = (Long)value; + nvalue.setIVal(ival); + } else if (value instanceof Float) { + float fval = (Float)value; + nvalue.setFVal(fval); + } else if (value instanceof Double) { + double dval = (Double)value; + nvalue.setFVal(dval); + } else if (value instanceof String) { + byte[] sval = ((String)value).getBytes(); + nvalue.setSVal(sval); + } else if (value instanceof List) { + nvalue.setLVal(list2Nlist((List)value)); + } else if (value instanceof Map) { + nvalue.setMVal(map2Nmap((Map)value)); + } else if (value instanceof Value) { + return (Value)value; + } else if (value instanceof Date) { + nvalue.setDVal((Date)value); + } else if (value instanceof Time) { + nvalue.setTVal((Time)value); + } else if (value instanceof Duration) { + nvalue.setDuVal((Duration)value); + } else if (value instanceof DateTime) { + nvalue.setDtVal((DateTime)value); + } else if (value instanceof Geography) { + nvalue.setGgVal((Geography) value); + } else { + // unsupport other Value type, use this function carefully + throw new UnsupportedOperationException( + "Only support convert boolean/float/int/string/map/list to nebula.Value but was" + + value.getClass().getTypeName()); + } + return nvalue; + } } diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java index 4216e684c..08f9196dd 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/SyncConnection.java @@ -5,7 +5,6 @@ package com.vesoft.nebula.client.graph.net; - import com.facebook.thrift.TException; import com.facebook.thrift.protocol.TCompactProtocol; import com.facebook.thrift.protocol.TProtocol; @@ -29,10 +28,13 @@ import com.vesoft.nebula.graph.VerifyClientVersionResp; import com.vesoft.nebula.util.SslUtil; import java.io.IOException; +import java.util.Collections; +import java.util.Map; import javax.net.ssl.SSLSocketFactory; import org.slf4j.Logger; import org.slf4j.LoggerFactory; + public class SyncConnection extends Connection { private static final Logger LOGGER = LoggerFactory.getLogger(SyncConnection.class); @@ -51,7 +53,7 @@ public void open(HostAddress address, int timeout, SSLParam sslParam) try { this.serverAddr = address; - this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; + this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; this.enabledSsl = true; this.sslParam = sslParam; if (sslSocketFactory == null) { @@ -88,7 +90,7 @@ public void open(HostAddress address, int timeout) throws IOErrorException, ClientServerIncompatibleException { try { this.serverAddr = address; - this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; + this.timeout = timeout <= 0 ? Integer.MAX_VALUE : timeout; this.transport = new TSocket( address.getHost(), address.getPort(), this.timeout, this.timeout); this.transport.open(); @@ -137,18 +139,18 @@ public AuthResult authenticate(String user, String password) throw new AuthFailedException(new String(resp.error_msg)); } else { throw new AuthFailedException( - "The error_msg is null, " - + "maybe the service not set or the response is disorder."); + "The error_msg is null, " + + "maybe the service not set or the response is disorder."); } } return new AuthResult(resp.getSession_id(), resp.getTime_zone_offset_seconds()); } catch (TException e) { if (e instanceof TTransportException) { - TTransportException te = (TTransportException)e; + TTransportException te = (TTransportException) e; if (te.getType() == TTransportException.END_OF_FILE) { throw new IOErrorException(IOErrorException.E_CONNECT_BROKEN, te.getMessage()); } else if (te.getType() == TTransportException.TIMED_OUT - || te.getMessage().contains("Read timed out")) { + || te.getMessage().contains("Read timed out")) { reopen(); throw new IOErrorException(IOErrorException.E_TIME_OUT, te.getMessage()); } else if (te.getType() == TTransportException.NOT_OPEN) { @@ -161,8 +163,15 @@ public AuthResult authenticate(String user, String password) public ExecutionResponse execute(long sessionID, String stmt) throws IOErrorException { + return executeWithParameter(sessionID, + stmt, (Map) Collections.EMPTY_MAP); + } + + public ExecutionResponse executeWithParameter(long sessionID, String stmt, + Map parameterMap) + throws IOErrorException { try { - return client.execute(sessionID, stmt.getBytes()); + return client.executeWithParameter(sessionID, stmt.getBytes(), parameterMap); } catch (TException e) { if (e instanceof TTransportException) { TTransportException te = (TTransportException) e; @@ -171,7 +180,7 @@ public ExecutionResponse execute(long sessionID, String stmt) } else if (te.getType() == TTransportException.NOT_OPEN) { throw new IOErrorException(IOErrorException.E_NO_OPEN, te.getMessage()); } else if (te.getType() == TTransportException.TIMED_OUT - || te.getMessage().contains("Read timed out")) { + || te.getMessage().contains("Read timed out")) { try { reopen(); } catch (ClientServerIncompatibleException ex) { @@ -186,8 +195,16 @@ public ExecutionResponse execute(long sessionID, String stmt) public String executeJson(long sessionID, String stmt) throws IOErrorException { + return executeJsonWithParameter(sessionID, stmt, + (Map) Collections.EMPTY_MAP); + } + + public String executeJsonWithParameter(long sessionID, String stmt, + Map parameterMap) + throws IOErrorException { try { - byte[] result = client.executeJson(sessionID, stmt.getBytes()); + byte[] result = + client.executeJsonWithParameter(sessionID, stmt.getBytes(), parameterMap); return new String(result, StandardCharsets.UTF_8); } catch (TException e) { if (e instanceof TTransportException) { diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java index 35b197b74..50d772c22 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java @@ -5,13 +5,19 @@ package com.vesoft.nebula.client.graph.net; +import com.vesoft.nebula.Date; +import com.vesoft.nebula.Row; +import com.vesoft.nebula.Value; import com.vesoft.nebula.client.graph.NebulaPoolConfig; import com.vesoft.nebula.client.graph.data.HostAddress; import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.client.util.ProcessUtil; +import java.util.ArrayList; import java.util.Arrays; +import java.util.HashMap; import java.util.List; +import java.util.Map; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeUnit; @@ -173,4 +179,80 @@ public void testReconnectWithMultiServices() { pool.close(); } } + + @Test + public void testExecuteWithParameter() { + System.out.println("<==== testExecuteWithParameter ====>"); + Runtime runtime = Runtime.getRuntime(); + NebulaPool pool = new NebulaPool(); + try { + // make sure the graphd2_1 without any sessions + String cmd = "docker restart nebula-docker-compose_graphd2_1"; + Process p = runtime.exec(cmd); + p.waitFor(10, TimeUnit.SECONDS); + ProcessUtil.printProcessStatus(cmd, p); + + NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); + nebulaPoolConfig.setMaxConnSize(6); + List addresses = Arrays.asList( + new HostAddress("127.0.0.1", 9669), + new HostAddress("127.0.0.1", 9670), + new HostAddress("127.0.0.1", 9671)); + TimeUnit.SECONDS.sleep(15); + Assert.assertTrue(pool.init(addresses, nebulaPoolConfig)); + TimeUnit.SECONDS.sleep(15); + Session session = pool.getSession("root", "nebula", true); + System.out.println("The address of session is " + session.getGraphHost()); + + // test ping + Assert.assertTrue(session.ping()); + // prepare parameters + Map paramMap = new HashMap(); + paramMap.put("p1", 3); + paramMap.put("p2", true); + paramMap.put("p3", 3.3); + Value nvalue = new Value(); + Date date = new Date(); + date.setYear((short) 2021); + nvalue.setDVal(date); + List list = new ArrayList<>(); + list.add(1); + list.add(true); + list.add(nvalue); + list.add(date); + paramMap.put("p4", list); + Map map = new HashMap<>(); + map.put("a", 1); + map.put("b", true); + map.put("c", nvalue); + map.put("d", list); + paramMap.put("p5", map); + // test `executeWithParameter` interface + ResultSet resp = + session.executeWithParameter("RETURN $p1+1,$p2,$p3,$p4[2],$p5.d[3]", paramMap); + Assert.assertTrue(resp.isSucceeded()); + Row row = resp.getRows().get(0); + Assert.assertTrue(row.values.get(0).equals(Value.iVal(4))); + Assert.assertTrue(row.values.get(1).equals(Value.bVal(true))); + Assert.assertTrue(row.values.get(2).equals(Value.fVal(3.3))); + Assert.assertTrue(row.values.get(3).equals(list.get(2))); + Assert.assertTrue(row.values.get(4).equals(((List)map.get("d")).get(3))); + // release session + session.release(); + } catch (Exception e) { + e.printStackTrace(); + Assert.assertFalse(e.getMessage(), false); + } finally { + try { + runtime.exec("docker start nebula-docker-compose_graphd0_1") + .waitFor(5, TimeUnit.SECONDS); + runtime.exec("docker start nebula-docker-compose_graphd1_1") + .waitFor(5, TimeUnit.SECONDS); + TimeUnit.SECONDS.sleep(5); + } catch (Exception e) { + e.printStackTrace(); + } + pool.close(); + } + } } diff --git a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java index 0d10704d3..761994f69 100644 --- a/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java +++ b/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java @@ -7,7 +7,9 @@ import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; +import com.vesoft.nebula.Date; import com.vesoft.nebula.ErrorCode; +import com.vesoft.nebula.Value; import com.vesoft.nebula.client.graph.NebulaPoolConfig; import com.vesoft.nebula.client.graph.data.CASignedSSLParam; import com.vesoft.nebula.client.graph.data.HostAddress; @@ -17,8 +19,11 @@ import com.vesoft.nebula.client.graph.net.NebulaPool; import com.vesoft.nebula.client.graph.net.Session; import java.io.UnsupportedEncodingException; +import java.util.ArrayList; import java.util.Arrays; +import java.util.HashMap; import java.util.List; +import java.util.Map; import java.util.concurrent.TimeUnit; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -143,6 +148,37 @@ public static void main(String[] args) { } printResult(resp); } + { + // prepare parameters + Map paramMap = new HashMap(); + paramMap.put("p1", 3); + paramMap.put("p2", true); + paramMap.put("p3", 3.3); + Value nvalue = new Value(); + Date date = new Date(); + date.setYear((short) 2021); + nvalue.setDVal(date); + List list = new ArrayList<>(); + list.add(1); + list.add(true); + list.add(nvalue); + list.add(date); + paramMap.put("p4", list); + Map map = new HashMap<>(); + map.put("a", 1); + map.put("b", true); + map.put("c", nvalue); + map.put("d", list); + paramMap.put("p5", map); + String query = "RETURN abs($p1+1),toBoolean($p2) and false,$p3,$p4[2],$p5.d[3]"; + ResultSet resp = session.executeWithParameter(query, paramMap); + if (!resp.isSucceeded()) { + log.error(String.format("Execute: `%s', failed: %s", + query, resp.getErrorMessage())); + System.exit(1); + } + printResult(resp); + } { String queryForJson = "YIELD 1"; From 0cae1bb5586d90edb1b144595bc486a242ea0b84 Mon Sep 17 00:00:00 2001 From: Anqi Date: Fri, 7 Jan 2022 11:24:42 +0800 Subject: [PATCH 23/25] specify ssl config for console (#417) --- client/src/test/resources/docker-compose-casigned.yaml | 4 +++- client/src/test/resources/docker-compose-selfsigned.yaml | 6 +++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/client/src/test/resources/docker-compose-casigned.yaml b/client/src/test/resources/docker-compose-casigned.yaml index 3cbdb7f59..e3b26bbdd 100644 --- a/client/src/test/resources/docker-compose-casigned.yaml +++ b/client/src/test/resources/docker-compose-casigned.yaml @@ -136,8 +136,10 @@ services: - -c - | sleep 3 && - nebula-console -addr graphd-casigned -port 9669 -u root -p nebula -e 'ADD HOSTS "172.29.2.1":9779' && + nebula-console -addr graphd-casigned -port 9669 -u root -p nebula -enable_ssl=true -ssl_root_ca_path /share/resources/test.ca.pem -ssl_cert_path /share/resources/test.derive.crt -ssl_private_key_path /share/resources/test.derive.key --ssl_insecure_skip_verify=true -e 'ADD HOSTS "172.29.2.1":9779' && sleep 36000 + volumes: + - ./ssl:/share/resources:Z depends_on: - graphd-casigned networks: diff --git a/client/src/test/resources/docker-compose-selfsigned.yaml b/client/src/test/resources/docker-compose-selfsigned.yaml index ff551b8d8..3bd3a17a1 100644 --- a/client/src/test/resources/docker-compose-selfsigned.yaml +++ b/client/src/test/resources/docker-compose-selfsigned.yaml @@ -135,8 +135,12 @@ services: - -c - | sleep 3 && - nebula-console -addr graphd-selfsigned -port 9669 -u root -p nebula -e 'ADD HOSTS "172.30.2.1":9779' && + nebula-console -addr graphd-selfsigned -port 9669 -u root -p nebula -enable_ssl=true -ssl_root_ca_path /share/resources/test.ca.pem -ssl_cert_path /share/resources/test.derive.crt -ssl_private_key_path /share/resources/test.derive.key --ssl_insecure_skip_verify=true -e 'ADD HOSTS "172.30.2.1":9779' && sleep 36000 + volumes: + - ./data/graph_self:/data/graph:Z + - ./logs/graph:/logs:Z + - ./ssl:/share/resources:Z depends_on: - graphd-selfsigned networks: From 883d6f0b1d59204b060c08b6c328ebd85080d7d2 Mon Sep 17 00:00:00 2001 From: Anqi Date: Fri, 7 Jan 2022 17:01:36 +0800 Subject: [PATCH 24/25] enable auto release after close staging repo & update snapshot version (#418) * move jts dependency & enable auto release after close staging repo * update client SNAPSHOT version --- README.md | 10 +++++----- client/pom.xml | 18 +++++++++++++++++- examples/pom.xml | 2 +- pom.xml | 13 ++----------- 4 files changed, 25 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index 56f0d50b7..1b802835a 100644 --- a/README.md +++ b/README.md @@ -37,19 +37,19 @@ The v2.0.0-rc branch works with Nebula Graph v2.0.0-beta and v2.0.0-rc1, but not To use this Java client, do a check of these: - Java 8 or a later version is installed. -- Nebula Graph v2.0 is deployed. For more information, see [Deployment and installation of Nebula Graph](https://docs.nebula-graph.io/2.0/4.deployment-and-installation/1.resource-preparations/ "Click to go to Nebula Graph website"). +- Nebula Graph is deployed. For more information, see [Deployment and installation of Nebula Graph](https://docs.nebula-graph.io/master/4.deployment-and-installation/1.resource-preparations/ "Click to go to Nebula Graph website"). ## Modify pom.xml If you use Maven to manage your project, add the following dependency to your `pom.xml` file. -Replace `2.0.0-SNAPSHOT` with an appropriate Nebula Java v2.x version. +Replace `3.0-SNAPSHOT` with an appropriate Nebula Java version. For more versions, visit [releases](https://github.com/vesoft-inc/nebula-java/releases). ```xml com.vesoft client - 2.0.0-SNAPSHOT + 3.0-SNAPSHOT ``` There are the version correspondence between client and Nebula: @@ -67,11 +67,11 @@ There are the version correspondence between client and Nebula: | 2.5.0 | 2.5.0,2.5.1 | | 2.6.0 | 2.6.0,2.6.1 | | 2.6.1 | 2.6.0,2.6.1 | -| 2.0.0-SNAPSHOT| nightly | +| 3.0-SNAPSHOT | nightly | ## Graph client example -To connect to the `nebula-graphd` process of Nebula Graph v2.0: +To connect to the `nebula-graphd` process of Nebula Graph: ```java NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); diff --git a/client/pom.xml b/client/pom.xml index a17bc85f7..a58c32ccb 100644 --- a/client/pom.xml +++ b/client/pom.xml @@ -5,7 +5,7 @@ com.vesoft nebula - 2.0.0-SNAPSHOT + 3.0-SNAPSHOT 4.0.0 @@ -38,6 +38,17 @@ + + + org.sonatype.plugins + nexus-staging-maven-plugin + true + + ossrh + https://oss.sonatype.org/ + true + + org.codehaus.mojo build-helper-maven-plugin @@ -245,5 +256,10 @@ bcpkix-jdk15on ${bouncycastle.version} + + org.locationtech.jts + jts-core + 1.16.1 + diff --git a/examples/pom.xml b/examples/pom.xml index c2db1caea..7fbbd07ad 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -5,7 +5,7 @@ com.vesoft nebula - 2.0.0-SNAPSHOT + 3.0-SNAPSHOT 4.0.0 diff --git a/pom.xml b/pom.xml index 5076510d8..40f8b3ac2 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ com.vesoft nebula pom - 2.0.0-SNAPSHOT + 3.0-SNAPSHOT UTF-8 @@ -134,7 +134,7 @@ ossrh https://oss.sonatype.org/ - false + true @@ -158,13 +158,4 @@ - - - - org.locationtech.jts - jts-core - 1.16.1 - - - From eb5ae6bff0e602e0f7db4fa957b00a640e12b252 Mon Sep 17 00:00:00 2001 From: Anqi Date: Mon, 10 Jan 2022 10:22:37 +0800 Subject: [PATCH 25/25] fix executeWithParameter NPE (#419) * fix executeWithParameter NPE * fix test * fix test --- .../java/com/vesoft/nebula/client/graph/net/Session.java | 8 ++++---- .../com/vesoft/nebula/client/graph/net/TestSession.java | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java index 4cc020a4d..212152dbc 100644 --- a/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java +++ b/client/src/main/java/com/vesoft/nebula/client/graph/net/Session.java @@ -18,6 +18,7 @@ import com.vesoft.nebula.client.graph.data.ResultSet; import com.vesoft.nebula.client.graph.exception.IOErrorException; import com.vesoft.nebula.graph.ExecutionResponse; +import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; import java.util.List; @@ -95,8 +96,7 @@ public synchronized ResultSet executeWithParameter( "The session was released, couldn't use again."); } Map map = new HashMap<>(); - parameterMap.entrySet().stream() - .forEach(x -> map.put(x.getKey().getBytes(), value2Nvalue(x.getValue()))); + parameterMap.forEach((key, value) -> map.put(key.getBytes(), value2Nvalue(value))); if (connectionIsBroken.get() && retryConnect) { if (retryConnect()) { @@ -371,7 +371,7 @@ private boolean retryConnect() { * @return nebula list */ private NList list2Nlist(List list) throws UnsupportedOperationException { - NList nlist = new NList(); + NList nlist = new NList(new ArrayList()); for (Object item : list) { nlist.values.add(value2Nvalue(item)); } @@ -384,7 +384,7 @@ private NList list2Nlist(List list) throws UnsupportedOperationException * @return nebula map */ private NMap map2Nmap(Map map) throws UnsupportedOperationException { - NMap nmap = new NMap(); + NMap nmap = new NMap(new HashMap()); for (Map.Entry entry : map.entrySet()) { nmap.kvs.put(entry.getKey().getBytes(), value2Nvalue(entry.getValue())); } diff --git a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java index 50d772c22..2dcae27d3 100644 --- a/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java +++ b/client/src/test/java/com/vesoft/nebula/client/graph/net/TestSession.java @@ -236,12 +236,12 @@ public void testExecuteWithParameter() { Assert.assertTrue(row.values.get(1).equals(Value.bVal(true))); Assert.assertTrue(row.values.get(2).equals(Value.fVal(3.3))); Assert.assertTrue(row.values.get(3).equals(list.get(2))); - Assert.assertTrue(row.values.get(4).equals(((List)map.get("d")).get(3))); + Assert.assertTrue(row.values.get(4).getDVal().equals(list.get(3))); // release session session.release(); } catch (Exception e) { e.printStackTrace(); - Assert.assertFalse(e.getMessage(), false); + Assert.assertFalse(true); } finally { try { runtime.exec("docker start nebula-docker-compose_graphd0_1")