This is an automated email from the ASF dual-hosted git repository.

laiyingchun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-pegasus.git


The following commit(s) were added to refs/heads/master by this push:
     new cedb819d feat: add app drop interface to the java client (#973)
cedb819d is described below

commit cedb819def7162b5beca19a858af010d62aeb158
Author: liguohao <[email protected]>
AuthorDate: Mon May 23 22:14:55 2022 +0800

    feat: add app drop interface to the java client (#973)
---
 java-client/idl/meta_admin.thrift                  |   17 +
 java-client/idl/rrdb.thrift                        |    1 +
 .../main/java/org/apache/pegasus/apps/meta.java    | 1188 ++++++++++++++++++--
 .../apache/pegasus/client/PegasusAdminClient.java  |   24 +
 .../client/PegasusAdminClientInterface.java        |    2 +
 .../apache/pegasus/operator/drop_app_operator.java |   67 ++
 .../configuration_drop_app_request.java            |  532 +++++++++
 .../configuration_drop_app_response.java           |  426 +++++++
 .../pegasus/replication/drop_app_options.java      |  534 +++++++++
 .../org/apache/pegasus/rpc/async/MetaSession.java  |    3 +
 .../org/apache/pegasus/client/TestAdminClient.java |   61 +-
 11 files changed, 2764 insertions(+), 91 deletions(-)

diff --git a/java-client/idl/meta_admin.thrift 
b/java-client/idl/meta_admin.thrift
index 8066989a..f11d3c9b 100644
--- a/java-client/idl/meta_admin.thrift
+++ b/java-client/idl/meta_admin.thrift
@@ -44,3 +44,20 @@ struct configuration_create_app_response
     1:base.error_code  err;
     2:i32              appid;
 }
+
+struct drop_app_options
+{
+    1:bool             success_if_not_exist;
+    2:optional i64     reserve_seconds;
+}
+
+struct configuration_drop_app_request
+{
+    1:string                   app_name;
+    2:drop_app_options         options;
+}
+
+struct configuration_drop_app_response
+{
+    1:base.error_code   err;
+}
diff --git a/java-client/idl/rrdb.thrift b/java-client/idl/rrdb.thrift
index 74efdf6b..e7e73da5 100644
--- a/java-client/idl/rrdb.thrift
+++ b/java-client/idl/rrdb.thrift
@@ -318,4 +318,5 @@ service meta
 {
     replication.query_cfg_response query_cfg(1:replication.query_cfg_request 
query);
     meta_admin.configuration_create_app_response 
create_app(1:meta_admin.configuration_create_app_request request);
+    meta_admin.configuration_drop_app_response 
drop_app(1:meta_admin.configuration_drop_app_request request);
 }
diff --git a/java-client/src/main/java/org/apache/pegasus/apps/meta.java 
b/java-client/src/main/java/org/apache/pegasus/apps/meta.java
index 795aa340..cb51bd85 100644
--- a/java-client/src/main/java/org/apache/pegasus/apps/meta.java
+++ b/java-client/src/main/java/org/apache/pegasus/apps/meta.java
@@ -25,36 +25,46 @@
  */
 package org.apache.pegasus.apps;
 
-import org.apache.pegasus.replication.configuration_create_app_request;
-import org.apache.pegasus.replication.configuration_create_app_response;
-import org.apache.pegasus.replication.query_cfg_request;
-import org.apache.pegasus.replication.query_cfg_response;
-
 @SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
 @javax.annotation.Generated(
     value = "Autogenerated by Thrift Compiler (0.11.0)",
-    date = "2022-03-10")
+    date = "2022-05-17")
 public class meta {
 
   public interface Iface {
 
-    public query_cfg_response query_cfg(query_cfg_request query)
+    public org.apache.pegasus.replication.query_cfg_response query_cfg(
+        org.apache.pegasus.replication.query_cfg_request query) throws 
org.apache.thrift.TException;
+
+    public org.apache.pegasus.replication.configuration_create_app_response 
create_app(
+        org.apache.pegasus.replication.configuration_create_app_request 
request)
         throws org.apache.thrift.TException;
 
-    public configuration_create_app_response 
create_app(configuration_create_app_request request)
+    public org.apache.pegasus.replication.configuration_drop_app_response 
drop_app(
+        org.apache.pegasus.replication.configuration_drop_app_request request)
         throws org.apache.thrift.TException;
   }
 
   public interface AsyncIface {
 
     public void query_cfg(
-        query_cfg_request query,
-        org.apache.thrift.async.AsyncMethodCallback<query_cfg_response> 
resultHandler)
+        org.apache.pegasus.replication.query_cfg_request query,
+        org.apache.thrift.async.AsyncMethodCallback<
+                org.apache.pegasus.replication.query_cfg_response>
+            resultHandler)
         throws org.apache.thrift.TException;
 
     public void create_app(
-        configuration_create_app_request request,
-        
org.apache.thrift.async.AsyncMethodCallback<configuration_create_app_response>
+        org.apache.pegasus.replication.configuration_create_app_request 
request,
+        org.apache.thrift.async.AsyncMethodCallback<
+                
org.apache.pegasus.replication.configuration_create_app_response>
+            resultHandler)
+        throws org.apache.thrift.TException;
+
+    public void drop_app(
+        org.apache.pegasus.replication.configuration_drop_app_request request,
+        org.apache.thrift.async.AsyncMethodCallback<
+                org.apache.pegasus.replication.configuration_drop_app_response>
             resultHandler)
         throws org.apache.thrift.TException;
   }
@@ -82,19 +92,22 @@ public class meta {
       super(iprot, oprot);
     }
 
-    public query_cfg_response query_cfg(query_cfg_request query)
+    public org.apache.pegasus.replication.query_cfg_response query_cfg(
+        org.apache.pegasus.replication.query_cfg_request query)
         throws org.apache.thrift.TException {
       send_query_cfg(query);
       return recv_query_cfg();
     }
 
-    public void send_query_cfg(query_cfg_request query) throws 
org.apache.thrift.TException {
+    public void 
send_query_cfg(org.apache.pegasus.replication.query_cfg_request query)
+        throws org.apache.thrift.TException {
       query_cfg_args args = new query_cfg_args();
       args.setQuery(query);
       sendBase("query_cfg", args);
     }
 
-    public query_cfg_response recv_query_cfg() throws 
org.apache.thrift.TException {
+    public org.apache.pegasus.replication.query_cfg_response recv_query_cfg()
+        throws org.apache.thrift.TException {
       query_cfg_result result = new query_cfg_result();
       receiveBase(result, "query_cfg");
       if (result.isSetSuccess()) {
@@ -105,20 +118,23 @@ public class meta {
           "query_cfg failed: unknown result");
     }
 
-    public configuration_create_app_response 
create_app(configuration_create_app_request request)
+    public org.apache.pegasus.replication.configuration_create_app_response 
create_app(
+        org.apache.pegasus.replication.configuration_create_app_request 
request)
         throws org.apache.thrift.TException {
       send_create_app(request);
       return recv_create_app();
     }
 
-    public void send_create_app(configuration_create_app_request request)
+    public void send_create_app(
+        org.apache.pegasus.replication.configuration_create_app_request 
request)
         throws org.apache.thrift.TException {
       create_app_args args = new create_app_args();
       args.setRequest(request);
       sendBase("create_app", args);
     }
 
-    public configuration_create_app_response recv_create_app() throws 
org.apache.thrift.TException {
+    public org.apache.pegasus.replication.configuration_create_app_response 
recv_create_app()
+        throws org.apache.thrift.TException {
       create_app_result result = new create_app_result();
       receiveBase(result, "create_app");
       if (result.isSetSuccess()) {
@@ -128,6 +144,32 @@ public class meta {
           org.apache.thrift.TApplicationException.MISSING_RESULT,
           "create_app failed: unknown result");
     }
+
+    public org.apache.pegasus.replication.configuration_drop_app_response 
drop_app(
+        org.apache.pegasus.replication.configuration_drop_app_request request)
+        throws org.apache.thrift.TException {
+      send_drop_app(request);
+      return recv_drop_app();
+    }
+
+    public void 
send_drop_app(org.apache.pegasus.replication.configuration_drop_app_request 
request)
+        throws org.apache.thrift.TException {
+      drop_app_args args = new drop_app_args();
+      args.setRequest(request);
+      sendBase("drop_app", args);
+    }
+
+    public org.apache.pegasus.replication.configuration_drop_app_response 
recv_drop_app()
+        throws org.apache.thrift.TException {
+      drop_app_result result = new drop_app_result();
+      receiveBase(result, "drop_app");
+      if (result.isSetSuccess()) {
+        return result.success;
+      }
+      throw new org.apache.thrift.TApplicationException(
+          org.apache.thrift.TApplicationException.MISSING_RESULT,
+          "drop_app failed: unknown result");
+    }
   }
 
   public static class AsyncClient extends org.apache.thrift.async.TAsyncClient
@@ -158,8 +200,10 @@ public class meta {
     }
 
     public void query_cfg(
-        query_cfg_request query,
-        org.apache.thrift.async.AsyncMethodCallback<query_cfg_response> 
resultHandler)
+        org.apache.pegasus.replication.query_cfg_request query,
+        org.apache.thrift.async.AsyncMethodCallback<
+                org.apache.pegasus.replication.query_cfg_response>
+            resultHandler)
         throws org.apache.thrift.TException {
       checkReady();
       query_cfg_call method_call =
@@ -169,12 +213,15 @@ public class meta {
     }
 
     public static class query_cfg_call
-        extends org.apache.thrift.async.TAsyncMethodCall<query_cfg_response> {
-      private query_cfg_request query;
+        extends org.apache.thrift.async.TAsyncMethodCall<
+            org.apache.pegasus.replication.query_cfg_response> {
+      private org.apache.pegasus.replication.query_cfg_request query;
 
       public query_cfg_call(
-          query_cfg_request query,
-          org.apache.thrift.async.AsyncMethodCallback<query_cfg_response> 
resultHandler,
+          org.apache.pegasus.replication.query_cfg_request query,
+          org.apache.thrift.async.AsyncMethodCallback<
+                  org.apache.pegasus.replication.query_cfg_response>
+              resultHandler,
           org.apache.thrift.async.TAsyncClient client,
           org.apache.thrift.protocol.TProtocolFactory protocolFactory,
           org.apache.thrift.transport.TNonblockingTransport transport)
@@ -194,7 +241,8 @@ public class meta {
         prot.writeMessageEnd();
       }
 
-      public query_cfg_response getResult() throws 
org.apache.thrift.TException {
+      public org.apache.pegasus.replication.query_cfg_response getResult()
+          throws org.apache.thrift.TException {
         if (getState() != 
org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
           throw new java.lang.IllegalStateException("Method call not 
finished!");
         }
@@ -207,8 +255,9 @@ public class meta {
     }
 
     public void create_app(
-        configuration_create_app_request request,
-        
org.apache.thrift.async.AsyncMethodCallback<configuration_create_app_response>
+        org.apache.pegasus.replication.configuration_create_app_request 
request,
+        org.apache.thrift.async.AsyncMethodCallback<
+                
org.apache.pegasus.replication.configuration_create_app_response>
             resultHandler)
         throws org.apache.thrift.TException {
       checkReady();
@@ -219,12 +268,14 @@ public class meta {
     }
 
     public static class create_app_call
-        extends 
org.apache.thrift.async.TAsyncMethodCall<configuration_create_app_response> {
-      private configuration_create_app_request request;
+        extends org.apache.thrift.async.TAsyncMethodCall<
+            org.apache.pegasus.replication.configuration_create_app_response> {
+      private org.apache.pegasus.replication.configuration_create_app_request 
request;
 
       public create_app_call(
-          configuration_create_app_request request,
-          
org.apache.thrift.async.AsyncMethodCallback<configuration_create_app_response>
+          org.apache.pegasus.replication.configuration_create_app_request 
request,
+          org.apache.thrift.async.AsyncMethodCallback<
+                  
org.apache.pegasus.replication.configuration_create_app_response>
               resultHandler,
           org.apache.thrift.async.TAsyncClient client,
           org.apache.thrift.protocol.TProtocolFactory protocolFactory,
@@ -245,7 +296,8 @@ public class meta {
         prot.writeMessageEnd();
       }
 
-      public configuration_create_app_response getResult() throws 
org.apache.thrift.TException {
+      public org.apache.pegasus.replication.configuration_create_app_response 
getResult()
+          throws org.apache.thrift.TException {
         if (getState() != 
org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
           throw new java.lang.IllegalStateException("Method call not 
finished!");
         }
@@ -256,6 +308,61 @@ public class meta {
         return (new Client(prot)).recv_create_app();
       }
     }
+
+    public void drop_app(
+        org.apache.pegasus.replication.configuration_drop_app_request request,
+        org.apache.thrift.async.AsyncMethodCallback<
+                org.apache.pegasus.replication.configuration_drop_app_response>
+            resultHandler)
+        throws org.apache.thrift.TException {
+      checkReady();
+      drop_app_call method_call =
+          new drop_app_call(request, resultHandler, this, ___protocolFactory, 
___transport);
+      this.___currentMethod = method_call;
+      ___manager.call(method_call);
+    }
+
+    public static class drop_app_call
+        extends org.apache.thrift.async.TAsyncMethodCall<
+            org.apache.pegasus.replication.configuration_drop_app_response> {
+      private org.apache.pegasus.replication.configuration_drop_app_request 
request;
+
+      public drop_app_call(
+          org.apache.pegasus.replication.configuration_drop_app_request 
request,
+          org.apache.thrift.async.AsyncMethodCallback<
+                  
org.apache.pegasus.replication.configuration_drop_app_response>
+              resultHandler,
+          org.apache.thrift.async.TAsyncClient client,
+          org.apache.thrift.protocol.TProtocolFactory protocolFactory,
+          org.apache.thrift.transport.TNonblockingTransport transport)
+          throws org.apache.thrift.TException {
+        super(client, protocolFactory, transport, resultHandler, false);
+        this.request = request;
+      }
+
+      public void write_args(org.apache.thrift.protocol.TProtocol prot)
+          throws org.apache.thrift.TException {
+        prot.writeMessageBegin(
+            new org.apache.thrift.protocol.TMessage(
+                "drop_app", org.apache.thrift.protocol.TMessageType.CALL, 0));
+        drop_app_args args = new drop_app_args();
+        args.setRequest(request);
+        args.write(prot);
+        prot.writeMessageEnd();
+      }
+
+      public org.apache.pegasus.replication.configuration_drop_app_response 
getResult()
+          throws org.apache.thrift.TException {
+        if (getState() != 
org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
+          throw new java.lang.IllegalStateException("Method call not 
finished!");
+        }
+        org.apache.thrift.transport.TMemoryInputTransport memoryTransport =
+            new 
org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
+        org.apache.thrift.protocol.TProtocol prot =
+            client.getProtocolFactory().getProtocol(memoryTransport);
+        return (new Client(prot)).recv_drop_app();
+      }
+    }
   }
 
   public static class Processor<I extends Iface> extends 
org.apache.thrift.TBaseProcessor<I>
@@ -292,6 +399,7 @@ public class meta {
                     processMap) {
       processMap.put("query_cfg", new query_cfg());
       processMap.put("create_app", new create_app());
+      processMap.put("drop_app", new drop_app());
       return processMap;
     }
 
@@ -348,6 +456,33 @@ public class meta {
         return result;
       }
     }
+
+    public static class drop_app<I extends Iface>
+        extends org.apache.thrift.ProcessFunction<I, drop_app_args> {
+      public drop_app() {
+        super("drop_app");
+      }
+
+      public drop_app_args getEmptyArgsInstance() {
+        return new drop_app_args();
+      }
+
+      protected boolean isOneway() {
+        return false;
+      }
+
+      @Override
+      protected boolean handleRuntimeExceptions() {
+        return false;
+      }
+
+      public drop_app_result getResult(I iface, drop_app_args args)
+          throws org.apache.thrift.TException {
+        drop_app_result result = new drop_app_result();
+        result.success = iface.drop_app(args.request);
+        return result;
+      }
+    }
   }
 
   public static class AsyncProcessor<I extends AsyncIface>
@@ -386,11 +521,13 @@ public class meta {
                     processMap) {
       processMap.put("query_cfg", new query_cfg());
       processMap.put("create_app", new create_app());
+      processMap.put("drop_app", new drop_app());
       return processMap;
     }
 
     public static class query_cfg<I extends AsyncIface>
-        extends org.apache.thrift.AsyncProcessFunction<I, query_cfg_args, 
query_cfg_response> {
+        extends org.apache.thrift.AsyncProcessFunction<
+            I, query_cfg_args, 
org.apache.pegasus.replication.query_cfg_response> {
       public query_cfg() {
         super("query_cfg");
       }
@@ -399,12 +536,15 @@ public class meta {
         return new query_cfg_args();
       }
 
-      public org.apache.thrift.async.AsyncMethodCallback<query_cfg_response> 
getResultHandler(
-          final 
org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb,
-          final int seqid) {
+      public org.apache.thrift.async.AsyncMethodCallback<
+              org.apache.pegasus.replication.query_cfg_response>
+          getResultHandler(
+              final 
org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb,
+              final int seqid) {
         final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new 
org.apache.thrift.async.AsyncMethodCallback<query_cfg_response>() {
-          public void onComplete(query_cfg_response o) {
+        return new org.apache.thrift.async.AsyncMethodCallback<
+            org.apache.pegasus.replication.query_cfg_response>() {
+          public void 
onComplete(org.apache.pegasus.replication.query_cfg_response o) {
             query_cfg_result result = new query_cfg_result();
             result.success = o;
             try {
@@ -454,7 +594,9 @@ public class meta {
       public void start(
           I iface,
           query_cfg_args args,
-          org.apache.thrift.async.AsyncMethodCallback<query_cfg_response> 
resultHandler)
+          org.apache.thrift.async.AsyncMethodCallback<
+                  org.apache.pegasus.replication.query_cfg_response>
+              resultHandler)
           throws org.apache.thrift.TException {
         iface.query_cfg(args.query, resultHandler);
       }
@@ -462,7 +604,7 @@ public class meta {
 
     public static class create_app<I extends AsyncIface>
         extends org.apache.thrift.AsyncProcessFunction<
-            I, create_app_args, configuration_create_app_response> {
+            I, create_app_args, 
org.apache.pegasus.replication.configuration_create_app_response> {
       public create_app() {
         super("create_app");
       }
@@ -471,14 +613,16 @@ public class meta {
         return new create_app_args();
       }
 
-      public 
org.apache.thrift.async.AsyncMethodCallback<configuration_create_app_response>
+      public org.apache.thrift.async.AsyncMethodCallback<
+              org.apache.pegasus.replication.configuration_create_app_response>
           getResultHandler(
               final 
org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb,
               final int seqid) {
         final org.apache.thrift.AsyncProcessFunction fcall = this;
         return new org.apache.thrift.async.AsyncMethodCallback<
-            configuration_create_app_response>() {
-          public void onComplete(configuration_create_app_response o) {
+            
org.apache.pegasus.replication.configuration_create_app_response>() {
+          public void onComplete(
+              org.apache.pegasus.replication.configuration_create_app_response 
o) {
             create_app_result result = new create_app_result();
             result.success = o;
             try {
@@ -528,12 +672,90 @@ public class meta {
       public void start(
           I iface,
           create_app_args args,
-          
org.apache.thrift.async.AsyncMethodCallback<configuration_create_app_response>
+          org.apache.thrift.async.AsyncMethodCallback<
+                  
org.apache.pegasus.replication.configuration_create_app_response>
               resultHandler)
           throws org.apache.thrift.TException {
         iface.create_app(args.request, resultHandler);
       }
     }
+
+    public static class drop_app<I extends AsyncIface>
+        extends org.apache.thrift.AsyncProcessFunction<
+            I, drop_app_args, 
org.apache.pegasus.replication.configuration_drop_app_response> {
+      public drop_app() {
+        super("drop_app");
+      }
+
+      public drop_app_args getEmptyArgsInstance() {
+        return new drop_app_args();
+      }
+
+      public org.apache.thrift.async.AsyncMethodCallback<
+              org.apache.pegasus.replication.configuration_drop_app_response>
+          getResultHandler(
+              final 
org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb,
+              final int seqid) {
+        final org.apache.thrift.AsyncProcessFunction fcall = this;
+        return new org.apache.thrift.async.AsyncMethodCallback<
+            org.apache.pegasus.replication.configuration_drop_app_response>() {
+          public void 
onComplete(org.apache.pegasus.replication.configuration_drop_app_response o) {
+            drop_app_result result = new drop_app_result();
+            result.success = o;
+            try {
+              fcall.sendResponse(fb, result, 
org.apache.thrift.protocol.TMessageType.REPLY, seqid);
+            } catch (org.apache.thrift.transport.TTransportException e) {
+              _LOGGER.error("TTransportException writing to internal frame 
buffer", e);
+              fb.close();
+            } catch (java.lang.Exception e) {
+              _LOGGER.error("Exception writing to internal frame buffer", e);
+              onError(e);
+            }
+          }
+
+          public void onError(java.lang.Exception e) {
+            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+            org.apache.thrift.TSerializable msg;
+            drop_app_result result = new drop_app_result();
+            if (e instanceof org.apache.thrift.transport.TTransportException) {
+              _LOGGER.error("TTransportException inside handler", e);
+              fb.close();
+              return;
+            } else if (e instanceof org.apache.thrift.TApplicationException) {
+              _LOGGER.error("TApplicationException inside handler", e);
+              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+              msg = (org.apache.thrift.TApplicationException) e;
+            } else {
+              _LOGGER.error("Exception inside handler", e);
+              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+              msg =
+                  new org.apache.thrift.TApplicationException(
+                      org.apache.thrift.TApplicationException.INTERNAL_ERROR, 
e.getMessage());
+            }
+            try {
+              fcall.sendResponse(fb, msg, msgType, seqid);
+            } catch (java.lang.Exception ex) {
+              _LOGGER.error("Exception writing to internal frame buffer", ex);
+              fb.close();
+            }
+          }
+        };
+      }
+
+      protected boolean isOneway() {
+        return false;
+      }
+
+      public void start(
+          I iface,
+          drop_app_args args,
+          org.apache.thrift.async.AsyncMethodCallback<
+                  
org.apache.pegasus.replication.configuration_drop_app_response>
+              resultHandler)
+          throws org.apache.thrift.TException {
+        iface.drop_app(args.request, resultHandler);
+      }
+    }
   }
 
   public static class query_cfg_args
@@ -553,7 +775,7 @@ public class meta {
     private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
         new query_cfg_argsTupleSchemeFactory();
 
-    public query_cfg_request query; // required
+    public org.apache.pegasus.replication.query_cfg_request query; // required
 
     /**
      * The set of fields this struct contains, along with convenience methods 
for finding and
@@ -626,7 +848,8 @@ public class meta {
               "query",
               org.apache.thrift.TFieldRequirementType.DEFAULT,
               new org.apache.thrift.meta_data.StructMetaData(
-                  org.apache.thrift.protocol.TType.STRUCT, 
query_cfg_request.class)));
+                  org.apache.thrift.protocol.TType.STRUCT,
+                  org.apache.pegasus.replication.query_cfg_request.class)));
       metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
       org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
           query_cfg_args.class, metaDataMap);
@@ -634,7 +857,7 @@ public class meta {
 
     public query_cfg_args() {}
 
-    public query_cfg_args(query_cfg_request query) {
+    public query_cfg_args(org.apache.pegasus.replication.query_cfg_request 
query) {
       this();
       this.query = query;
     }
@@ -642,7 +865,7 @@ public class meta {
     /** Performs a deep copy on <i>other</i>. */
     public query_cfg_args(query_cfg_args other) {
       if (other.isSetQuery()) {
-        this.query = new query_cfg_request(other.query);
+        this.query = new 
org.apache.pegasus.replication.query_cfg_request(other.query);
       }
     }
 
@@ -655,11 +878,11 @@ public class meta {
       this.query = null;
     }
 
-    public query_cfg_request getQuery() {
+    public org.apache.pegasus.replication.query_cfg_request getQuery() {
       return this.query;
     }
 
-    public query_cfg_args setQuery(query_cfg_request query) {
+    public query_cfg_args 
setQuery(org.apache.pegasus.replication.query_cfg_request query) {
       this.query = query;
       return this;
     }
@@ -685,7 +908,7 @@ public class meta {
           if (value == null) {
             unsetQuery();
           } else {
-            setQuery((query_cfg_request) value);
+            setQuery((org.apache.pegasus.replication.query_cfg_request) value);
           }
           break;
       }
@@ -848,7 +1071,7 @@ public class meta {
           switch (schemeField.id) {
             case 1: // QUERY
               if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
-                struct.query = new query_cfg_request();
+                struct.query = new 
org.apache.pegasus.replication.query_cfg_request();
                 struct.query.read(iprot);
                 struct.setQueryIsSet(true);
               } else {
@@ -914,7 +1137,7 @@ public class meta {
             (org.apache.thrift.protocol.TTupleProtocol) prot;
         java.util.BitSet incoming = iprot.readBitSet(1);
         if (incoming.get(0)) {
-          struct.query = new query_cfg_request();
+          struct.query = new 
org.apache.pegasus.replication.query_cfg_request();
           struct.query.read(iprot);
           struct.setQueryIsSet(true);
         }
@@ -947,7 +1170,7 @@ public class meta {
     private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
         new query_cfg_resultTupleSchemeFactory();
 
-    public query_cfg_response success; // required
+    public org.apache.pegasus.replication.query_cfg_response success; // 
required
 
     /**
      * The set of fields this struct contains, along with convenience methods 
for finding and
@@ -1020,7 +1243,8 @@ public class meta {
               "success",
               org.apache.thrift.TFieldRequirementType.DEFAULT,
               new org.apache.thrift.meta_data.StructMetaData(
-                  org.apache.thrift.protocol.TType.STRUCT, 
query_cfg_response.class)));
+                  org.apache.thrift.protocol.TType.STRUCT,
+                  org.apache.pegasus.replication.query_cfg_response.class)));
       metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
       org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
           query_cfg_result.class, metaDataMap);
@@ -1028,7 +1252,7 @@ public class meta {
 
     public query_cfg_result() {}
 
-    public query_cfg_result(query_cfg_response success) {
+    public query_cfg_result(org.apache.pegasus.replication.query_cfg_response 
success) {
       this();
       this.success = success;
     }
@@ -1036,7 +1260,7 @@ public class meta {
     /** Performs a deep copy on <i>other</i>. */
     public query_cfg_result(query_cfg_result other) {
       if (other.isSetSuccess()) {
-        this.success = new query_cfg_response(other.success);
+        this.success = new 
org.apache.pegasus.replication.query_cfg_response(other.success);
       }
     }
 
@@ -1049,11 +1273,11 @@ public class meta {
       this.success = null;
     }
 
-    public query_cfg_response getSuccess() {
+    public org.apache.pegasus.replication.query_cfg_response getSuccess() {
       return this.success;
     }
 
-    public query_cfg_result setSuccess(query_cfg_response success) {
+    public query_cfg_result 
setSuccess(org.apache.pegasus.replication.query_cfg_response success) {
       this.success = success;
       return this;
     }
@@ -1079,7 +1303,7 @@ public class meta {
           if (value == null) {
             unsetSuccess();
           } else {
-            setSuccess((query_cfg_response) value);
+            setSuccess((org.apache.pegasus.replication.query_cfg_response) 
value);
           }
           break;
       }
@@ -1242,7 +1466,7 @@ public class meta {
           switch (schemeField.id) {
             case 0: // SUCCESS
               if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
-                struct.success = new query_cfg_response();
+                struct.success = new 
org.apache.pegasus.replication.query_cfg_response();
                 struct.success.read(iprot);
                 struct.setSuccessIsSet(true);
               } else {
@@ -1308,7 +1532,7 @@ public class meta {
             (org.apache.thrift.protocol.TTupleProtocol) prot;
         java.util.BitSet incoming = iprot.readBitSet(1);
         if (incoming.get(0)) {
-          struct.success = new query_cfg_response();
+          struct.success = new 
org.apache.pegasus.replication.query_cfg_response();
           struct.success.read(iprot);
           struct.setSuccessIsSet(true);
         }
@@ -1341,7 +1565,7 @@ public class meta {
     private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
         new create_app_argsTupleSchemeFactory();
 
-    public configuration_create_app_request request; // required
+    public org.apache.pegasus.replication.configuration_create_app_request 
request; // required
 
     /**
      * The set of fields this struct contains, along with convenience methods 
for finding and
@@ -1415,7 +1639,7 @@ public class meta {
               org.apache.thrift.TFieldRequirementType.DEFAULT,
               new org.apache.thrift.meta_data.StructMetaData(
                   org.apache.thrift.protocol.TType.STRUCT,
-                  configuration_create_app_request.class)));
+                  
org.apache.pegasus.replication.configuration_create_app_request.class)));
       metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
       org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
           create_app_args.class, metaDataMap);
@@ -1423,7 +1647,8 @@ public class meta {
 
     public create_app_args() {}
 
-    public create_app_args(configuration_create_app_request request) {
+    public create_app_args(
+        org.apache.pegasus.replication.configuration_create_app_request 
request) {
       this();
       this.request = request;
     }
@@ -1431,7 +1656,8 @@ public class meta {
     /** Performs a deep copy on <i>other</i>. */
     public create_app_args(create_app_args other) {
       if (other.isSetRequest()) {
-        this.request = new configuration_create_app_request(other.request);
+        this.request =
+            new 
org.apache.pegasus.replication.configuration_create_app_request(other.request);
       }
     }
 
@@ -1444,11 +1670,12 @@ public class meta {
       this.request = null;
     }
 
-    public configuration_create_app_request getRequest() {
+    public org.apache.pegasus.replication.configuration_create_app_request 
getRequest() {
       return this.request;
     }
 
-    public create_app_args setRequest(configuration_create_app_request 
request) {
+    public create_app_args setRequest(
+        org.apache.pegasus.replication.configuration_create_app_request 
request) {
       this.request = request;
       return this;
     }
@@ -1474,7 +1701,7 @@ public class meta {
           if (value == null) {
             unsetRequest();
           } else {
-            setRequest((configuration_create_app_request) value);
+            
setRequest((org.apache.pegasus.replication.configuration_create_app_request) 
value);
           }
           break;
       }
@@ -1637,7 +1864,8 @@ public class meta {
           switch (schemeField.id) {
             case 1: // REQUEST
               if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
-                struct.request = new configuration_create_app_request();
+                struct.request =
+                    new 
org.apache.pegasus.replication.configuration_create_app_request();
                 struct.request.read(iprot);
                 struct.setRequestIsSet(true);
               } else {
@@ -1703,7 +1931,7 @@ public class meta {
             (org.apache.thrift.protocol.TTupleProtocol) prot;
         java.util.BitSet incoming = iprot.readBitSet(1);
         if (incoming.get(0)) {
-          struct.request = new configuration_create_app_request();
+          struct.request = new 
org.apache.pegasus.replication.configuration_create_app_request();
           struct.request.read(iprot);
           struct.setRequestIsSet(true);
         }
@@ -1736,7 +1964,7 @@ public class meta {
     private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
         new create_app_resultTupleSchemeFactory();
 
-    public configuration_create_app_response success; // required
+    public org.apache.pegasus.replication.configuration_create_app_response 
success; // required
 
     /**
      * The set of fields this struct contains, along with convenience methods 
for finding and
@@ -1810,7 +2038,7 @@ public class meta {
               org.apache.thrift.TFieldRequirementType.DEFAULT,
               new org.apache.thrift.meta_data.StructMetaData(
                   org.apache.thrift.protocol.TType.STRUCT,
-                  configuration_create_app_response.class)));
+                  
org.apache.pegasus.replication.configuration_create_app_response.class)));
       metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
       org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
           create_app_result.class, metaDataMap);
@@ -1818,7 +2046,8 @@ public class meta {
 
     public create_app_result() {}
 
-    public create_app_result(configuration_create_app_response success) {
+    public create_app_result(
+        org.apache.pegasus.replication.configuration_create_app_response 
success) {
       this();
       this.success = success;
     }
@@ -1826,7 +2055,8 @@ public class meta {
     /** Performs a deep copy on <i>other</i>. */
     public create_app_result(create_app_result other) {
       if (other.isSetSuccess()) {
-        this.success = new configuration_create_app_response(other.success);
+        this.success =
+            new 
org.apache.pegasus.replication.configuration_create_app_response(other.success);
       }
     }
 
@@ -1839,11 +2069,12 @@ public class meta {
       this.success = null;
     }
 
-    public configuration_create_app_response getSuccess() {
+    public org.apache.pegasus.replication.configuration_create_app_response 
getSuccess() {
       return this.success;
     }
 
-    public create_app_result setSuccess(configuration_create_app_response 
success) {
+    public create_app_result setSuccess(
+        org.apache.pegasus.replication.configuration_create_app_response 
success) {
       this.success = success;
       return this;
     }
@@ -1869,7 +2100,7 @@ public class meta {
           if (value == null) {
             unsetSuccess();
           } else {
-            setSuccess((configuration_create_app_response) value);
+            
setSuccess((org.apache.pegasus.replication.configuration_create_app_response) 
value);
           }
           break;
       }
@@ -2032,7 +2263,8 @@ public class meta {
           switch (schemeField.id) {
             case 0: // SUCCESS
               if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
-                struct.success = new configuration_create_app_response();
+                struct.success =
+                    new 
org.apache.pegasus.replication.configuration_create_app_response();
                 struct.success.read(iprot);
                 struct.setSuccessIsSet(true);
               } else {
@@ -2098,7 +2330,803 @@ public class meta {
             (org.apache.thrift.protocol.TTupleProtocol) prot;
         java.util.BitSet incoming = iprot.readBitSet(1);
         if (incoming.get(0)) {
-          struct.success = new configuration_create_app_response();
+          struct.success = new 
org.apache.pegasus.replication.configuration_create_app_response();
+          struct.success.read(iprot);
+          struct.setSuccessIsSet(true);
+        }
+      }
+    }
+
+    private static <S extends org.apache.thrift.scheme.IScheme> S scheme(
+        org.apache.thrift.protocol.TProtocol proto) {
+      return 
(org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme())
+              ? STANDARD_SCHEME_FACTORY
+              : TUPLE_SCHEME_FACTORY)
+          .getScheme();
+    }
+  }
+
+  public static class drop_app_args
+      implements org.apache.thrift.TBase<drop_app_args, drop_app_args._Fields>,
+          java.io.Serializable,
+          Cloneable,
+          Comparable<drop_app_args> {
+    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC =
+        new org.apache.thrift.protocol.TStruct("drop_app_args");
+
+    private static final org.apache.thrift.protocol.TField REQUEST_FIELD_DESC =
+        new org.apache.thrift.protocol.TField(
+            "request", org.apache.thrift.protocol.TType.STRUCT, (short) 1);
+
+    private static final org.apache.thrift.scheme.SchemeFactory 
STANDARD_SCHEME_FACTORY =
+        new drop_app_argsStandardSchemeFactory();
+    private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
+        new drop_app_argsTupleSchemeFactory();
+
+    public org.apache.pegasus.replication.configuration_drop_app_request 
request; // required
+
+    /**
+     * The set of fields this struct contains, along with convenience methods 
for finding and
+     * manipulating them.
+     */
+    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+      REQUEST((short) 1, "request");
+
+      private static final java.util.Map<java.lang.String, _Fields> byName =
+          new java.util.HashMap<java.lang.String, _Fields>();
+
+      static {
+        for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
+          byName.put(field.getFieldName(), field);
+        }
+      }
+
+      /** Find the _Fields constant that matches fieldId, or null if its not 
found. */
+      public static _Fields findByThriftId(int fieldId) {
+        switch (fieldId) {
+          case 1: // REQUEST
+            return REQUEST;
+          default:
+            return null;
+        }
+      }
+
+      /**
+       * Find the _Fields constant that matches fieldId, throwing an exception 
if it is not found.
+       */
+      public static _Fields findByThriftIdOrThrow(int fieldId) {
+        _Fields fields = findByThriftId(fieldId);
+        if (fields == null)
+          throw new java.lang.IllegalArgumentException("Field " + fieldId + " 
doesn't exist!");
+        return fields;
+      }
+
+      /** Find the _Fields constant that matches name, or null if its not 
found. */
+      public static _Fields findByName(java.lang.String name) {
+        return byName.get(name);
+      }
+
+      private final short _thriftId;
+      private final java.lang.String _fieldName;
+
+      _Fields(short thriftId, java.lang.String fieldName) {
+        _thriftId = thriftId;
+        _fieldName = fieldName;
+      }
+
+      public short getThriftFieldId() {
+        return _thriftId;
+      }
+
+      public java.lang.String getFieldName() {
+        return _fieldName;
+      }
+    }
+
+    // isset id assignments
+    public static final java.util.Map<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>
+        metaDataMap;
+
+    static {
+      java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap 
=
+          new java.util.EnumMap<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+      tmpMap.put(
+          _Fields.REQUEST,
+          new org.apache.thrift.meta_data.FieldMetaData(
+              "request",
+              org.apache.thrift.TFieldRequirementType.DEFAULT,
+              new org.apache.thrift.meta_data.StructMetaData(
+                  org.apache.thrift.protocol.TType.STRUCT,
+                  
org.apache.pegasus.replication.configuration_drop_app_request.class)));
+      metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
+      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
+          drop_app_args.class, metaDataMap);
+    }
+
+    public drop_app_args() {}
+
+    public 
drop_app_args(org.apache.pegasus.replication.configuration_drop_app_request 
request) {
+      this();
+      this.request = request;
+    }
+
+    /** Performs a deep copy on <i>other</i>. */
+    public drop_app_args(drop_app_args other) {
+      if (other.isSetRequest()) {
+        this.request =
+            new 
org.apache.pegasus.replication.configuration_drop_app_request(other.request);
+      }
+    }
+
+    public drop_app_args deepCopy() {
+      return new drop_app_args(this);
+    }
+
+    @Override
+    public void clear() {
+      this.request = null;
+    }
+
+    public org.apache.pegasus.replication.configuration_drop_app_request 
getRequest() {
+      return this.request;
+    }
+
+    public drop_app_args setRequest(
+        org.apache.pegasus.replication.configuration_drop_app_request request) 
{
+      this.request = request;
+      return this;
+    }
+
+    public void unsetRequest() {
+      this.request = null;
+    }
+
+    /** Returns true if field request is set (has been assigned a value) and 
false otherwise */
+    public boolean isSetRequest() {
+      return this.request != null;
+    }
+
+    public void setRequestIsSet(boolean value) {
+      if (!value) {
+        this.request = null;
+      }
+    }
+
+    public void setFieldValue(_Fields field, java.lang.Object value) {
+      switch (field) {
+        case REQUEST:
+          if (value == null) {
+            unsetRequest();
+          } else {
+            
setRequest((org.apache.pegasus.replication.configuration_drop_app_request) 
value);
+          }
+          break;
+      }
+    }
+
+    public java.lang.Object getFieldValue(_Fields field) {
+      switch (field) {
+        case REQUEST:
+          return getRequest();
+      }
+      throw new java.lang.IllegalStateException();
+    }
+
+    /**
+     * Returns true if field corresponding to fieldID is set (has been 
assigned a value) and false
+     * otherwise
+     */
+    public boolean isSet(_Fields field) {
+      if (field == null) {
+        throw new java.lang.IllegalArgumentException();
+      }
+
+      switch (field) {
+        case REQUEST:
+          return isSetRequest();
+      }
+      throw new java.lang.IllegalStateException();
+    }
+
+    @Override
+    public boolean equals(java.lang.Object that) {
+      if (that == null) return false;
+      if (that instanceof drop_app_args) return this.equals((drop_app_args) 
that);
+      return false;
+    }
+
+    public boolean equals(drop_app_args that) {
+      if (that == null) return false;
+      if (this == that) return true;
+
+      boolean this_present_request = true && this.isSetRequest();
+      boolean that_present_request = true && that.isSetRequest();
+      if (this_present_request || that_present_request) {
+        if (!(this_present_request && that_present_request)) return false;
+        if (!this.request.equals(that.request)) return false;
+      }
+
+      return true;
+    }
+
+    @Override
+    public int hashCode() {
+      int hashCode = 1;
+
+      hashCode = hashCode * 8191 + ((isSetRequest()) ? 131071 : 524287);
+      if (isSetRequest()) hashCode = hashCode * 8191 + request.hashCode();
+
+      return hashCode;
+    }
+
+    @Override
+    public int compareTo(drop_app_args other) {
+      if (!getClass().equals(other.getClass())) {
+        return getClass().getName().compareTo(other.getClass().getName());
+      }
+
+      int lastComparison = 0;
+
+      lastComparison = 
java.lang.Boolean.valueOf(isSetRequest()).compareTo(other.isSetRequest());
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+      if (isSetRequest()) {
+        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.request, 
other.request);
+        if (lastComparison != 0) {
+          return lastComparison;
+        }
+      }
+      return 0;
+    }
+
+    public _Fields fieldForId(int fieldId) {
+      return _Fields.findByThriftId(fieldId);
+    }
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot)
+        throws org.apache.thrift.TException {
+      scheme(iprot).read(iprot, this);
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot)
+        throws org.apache.thrift.TException {
+      scheme(oprot).write(oprot, this);
+    }
+
+    @Override
+    public java.lang.String toString() {
+      java.lang.StringBuilder sb = new 
java.lang.StringBuilder("drop_app_args(");
+      boolean first = true;
+
+      sb.append("request:");
+      if (this.request == null) {
+        sb.append("null");
+      } else {
+        sb.append(this.request);
+      }
+      first = false;
+      sb.append(")");
+      return sb.toString();
+    }
+
+    public void validate() throws org.apache.thrift.TException {
+      // check for required fields
+      // check for sub-struct validity
+      if (request != null) {
+        request.validate();
+      }
+    }
+
+    private void writeObject(java.io.ObjectOutputStream out) throws 
java.io.IOException {
+      try {
+        write(
+            new org.apache.thrift.protocol.TCompactProtocol(
+                new org.apache.thrift.transport.TIOStreamTransport(out)));
+      } catch (org.apache.thrift.TException te) {
+        throw new java.io.IOException(te);
+      }
+    }
+
+    private void readObject(java.io.ObjectInputStream in)
+        throws java.io.IOException, java.lang.ClassNotFoundException {
+      try {
+        read(
+            new org.apache.thrift.protocol.TCompactProtocol(
+                new org.apache.thrift.transport.TIOStreamTransport(in)));
+      } catch (org.apache.thrift.TException te) {
+        throw new java.io.IOException(te);
+      }
+    }
+
+    private static class drop_app_argsStandardSchemeFactory
+        implements org.apache.thrift.scheme.SchemeFactory {
+      public drop_app_argsStandardScheme getScheme() {
+        return new drop_app_argsStandardScheme();
+      }
+    }
+
+    private static class drop_app_argsStandardScheme
+        extends org.apache.thrift.scheme.StandardScheme<drop_app_args> {
+
+      public void read(org.apache.thrift.protocol.TProtocol iprot, 
drop_app_args struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TField schemeField;
+        iprot.readStructBegin();
+        while (true) {
+          schemeField = iprot.readFieldBegin();
+          if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+            break;
+          }
+          switch (schemeField.id) {
+            case 1: // REQUEST
+              if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
+                struct.request =
+                    new 
org.apache.pegasus.replication.configuration_drop_app_request();
+                struct.request.read(iprot);
+                struct.setRequestIsSet(true);
+              } else {
+                org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+              }
+              break;
+            default:
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+          }
+          iprot.readFieldEnd();
+        }
+        iprot.readStructEnd();
+
+        // check for required fields of primitive type, which can't be checked 
in the validate
+        // method
+        struct.validate();
+      }
+
+      public void write(org.apache.thrift.protocol.TProtocol oprot, 
drop_app_args struct)
+          throws org.apache.thrift.TException {
+        struct.validate();
+
+        oprot.writeStructBegin(STRUCT_DESC);
+        if (struct.request != null) {
+          oprot.writeFieldBegin(REQUEST_FIELD_DESC);
+          struct.request.write(oprot);
+          oprot.writeFieldEnd();
+        }
+        oprot.writeFieldStop();
+        oprot.writeStructEnd();
+      }
+    }
+
+    private static class drop_app_argsTupleSchemeFactory
+        implements org.apache.thrift.scheme.SchemeFactory {
+      public drop_app_argsTupleScheme getScheme() {
+        return new drop_app_argsTupleScheme();
+      }
+    }
+
+    private static class drop_app_argsTupleScheme
+        extends org.apache.thrift.scheme.TupleScheme<drop_app_args> {
+
+      @Override
+      public void write(org.apache.thrift.protocol.TProtocol prot, 
drop_app_args struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TTupleProtocol oprot =
+            (org.apache.thrift.protocol.TTupleProtocol) prot;
+        java.util.BitSet optionals = new java.util.BitSet();
+        if (struct.isSetRequest()) {
+          optionals.set(0);
+        }
+        oprot.writeBitSet(optionals, 1);
+        if (struct.isSetRequest()) {
+          struct.request.write(oprot);
+        }
+      }
+
+      @Override
+      public void read(org.apache.thrift.protocol.TProtocol prot, 
drop_app_args struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TTupleProtocol iprot =
+            (org.apache.thrift.protocol.TTupleProtocol) prot;
+        java.util.BitSet incoming = iprot.readBitSet(1);
+        if (incoming.get(0)) {
+          struct.request = new 
org.apache.pegasus.replication.configuration_drop_app_request();
+          struct.request.read(iprot);
+          struct.setRequestIsSet(true);
+        }
+      }
+    }
+
+    private static <S extends org.apache.thrift.scheme.IScheme> S scheme(
+        org.apache.thrift.protocol.TProtocol proto) {
+      return 
(org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme())
+              ? STANDARD_SCHEME_FACTORY
+              : TUPLE_SCHEME_FACTORY)
+          .getScheme();
+    }
+  }
+
+  public static class drop_app_result
+      implements org.apache.thrift.TBase<drop_app_result, 
drop_app_result._Fields>,
+          java.io.Serializable,
+          Cloneable,
+          Comparable<drop_app_result> {
+    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC =
+        new org.apache.thrift.protocol.TStruct("drop_app_result");
+
+    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC =
+        new org.apache.thrift.protocol.TField(
+            "success", org.apache.thrift.protocol.TType.STRUCT, (short) 0);
+
+    private static final org.apache.thrift.scheme.SchemeFactory 
STANDARD_SCHEME_FACTORY =
+        new drop_app_resultStandardSchemeFactory();
+    private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
+        new drop_app_resultTupleSchemeFactory();
+
+    public org.apache.pegasus.replication.configuration_drop_app_response 
success; // required
+
+    /**
+     * The set of fields this struct contains, along with convenience methods 
for finding and
+     * manipulating them.
+     */
+    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+      SUCCESS((short) 0, "success");
+
+      private static final java.util.Map<java.lang.String, _Fields> byName =
+          new java.util.HashMap<java.lang.String, _Fields>();
+
+      static {
+        for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
+          byName.put(field.getFieldName(), field);
+        }
+      }
+
+      /** Find the _Fields constant that matches fieldId, or null if its not 
found. */
+      public static _Fields findByThriftId(int fieldId) {
+        switch (fieldId) {
+          case 0: // SUCCESS
+            return SUCCESS;
+          default:
+            return null;
+        }
+      }
+
+      /**
+       * Find the _Fields constant that matches fieldId, throwing an exception 
if it is not found.
+       */
+      public static _Fields findByThriftIdOrThrow(int fieldId) {
+        _Fields fields = findByThriftId(fieldId);
+        if (fields == null)
+          throw new java.lang.IllegalArgumentException("Field " + fieldId + " 
doesn't exist!");
+        return fields;
+      }
+
+      /** Find the _Fields constant that matches name, or null if its not 
found. */
+      public static _Fields findByName(java.lang.String name) {
+        return byName.get(name);
+      }
+
+      private final short _thriftId;
+      private final java.lang.String _fieldName;
+
+      _Fields(short thriftId, java.lang.String fieldName) {
+        _thriftId = thriftId;
+        _fieldName = fieldName;
+      }
+
+      public short getThriftFieldId() {
+        return _thriftId;
+      }
+
+      public java.lang.String getFieldName() {
+        return _fieldName;
+      }
+    }
+
+    // isset id assignments
+    public static final java.util.Map<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>
+        metaDataMap;
+
+    static {
+      java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap 
=
+          new java.util.EnumMap<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+      tmpMap.put(
+          _Fields.SUCCESS,
+          new org.apache.thrift.meta_data.FieldMetaData(
+              "success",
+              org.apache.thrift.TFieldRequirementType.DEFAULT,
+              new org.apache.thrift.meta_data.StructMetaData(
+                  org.apache.thrift.protocol.TType.STRUCT,
+                  
org.apache.pegasus.replication.configuration_drop_app_response.class)));
+      metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
+      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
+          drop_app_result.class, metaDataMap);
+    }
+
+    public drop_app_result() {}
+
+    public 
drop_app_result(org.apache.pegasus.replication.configuration_drop_app_response 
success) {
+      this();
+      this.success = success;
+    }
+
+    /** Performs a deep copy on <i>other</i>. */
+    public drop_app_result(drop_app_result other) {
+      if (other.isSetSuccess()) {
+        this.success =
+            new 
org.apache.pegasus.replication.configuration_drop_app_response(other.success);
+      }
+    }
+
+    public drop_app_result deepCopy() {
+      return new drop_app_result(this);
+    }
+
+    @Override
+    public void clear() {
+      this.success = null;
+    }
+
+    public org.apache.pegasus.replication.configuration_drop_app_response 
getSuccess() {
+      return this.success;
+    }
+
+    public drop_app_result setSuccess(
+        org.apache.pegasus.replication.configuration_drop_app_response 
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(_Fields field, java.lang.Object value) {
+      switch (field) {
+        case SUCCESS:
+          if (value == null) {
+            unsetSuccess();
+          } else {
+            
setSuccess((org.apache.pegasus.replication.configuration_drop_app_response) 
value);
+          }
+          break;
+      }
+    }
+
+    public java.lang.Object getFieldValue(_Fields field) {
+      switch (field) {
+        case SUCCESS:
+          return getSuccess();
+      }
+      throw new java.lang.IllegalStateException();
+    }
+
+    /**
+     * Returns true if field corresponding to fieldID is set (has been 
assigned a value) and false
+     * otherwise
+     */
+    public boolean isSet(_Fields field) {
+      if (field == null) {
+        throw new java.lang.IllegalArgumentException();
+      }
+
+      switch (field) {
+        case SUCCESS:
+          return isSetSuccess();
+      }
+      throw new java.lang.IllegalStateException();
+    }
+
+    @Override
+    public boolean equals(java.lang.Object that) {
+      if (that == null) return false;
+      if (that instanceof drop_app_result) return 
this.equals((drop_app_result) that);
+      return false;
+    }
+
+    public boolean equals(drop_app_result that) {
+      if (that == null) return false;
+      if (this == that) return true;
+
+      boolean this_present_success = true && this.isSetSuccess();
+      boolean that_present_success = true && that.isSetSuccess();
+      if (this_present_success || that_present_success) {
+        if (!(this_present_success && that_present_success)) return false;
+        if (!this.success.equals(that.success)) return false;
+      }
+
+      return true;
+    }
+
+    @Override
+    public int hashCode() {
+      int hashCode = 1;
+
+      hashCode = hashCode * 8191 + ((isSetSuccess()) ? 131071 : 524287);
+      if (isSetSuccess()) hashCode = hashCode * 8191 + success.hashCode();
+
+      return hashCode;
+    }
+
+    @Override
+    public int compareTo(drop_app_result other) {
+      if (!getClass().equals(other.getClass())) {
+        return getClass().getName().compareTo(other.getClass().getName());
+      }
+
+      int lastComparison = 0;
+
+      lastComparison = 
java.lang.Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+      if (isSetSuccess()) {
+        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, 
other.success);
+        if (lastComparison != 0) {
+          return lastComparison;
+        }
+      }
+      return 0;
+    }
+
+    public _Fields fieldForId(int fieldId) {
+      return _Fields.findByThriftId(fieldId);
+    }
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot)
+        throws org.apache.thrift.TException {
+      scheme(iprot).read(iprot, this);
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot)
+        throws org.apache.thrift.TException {
+      scheme(oprot).write(oprot, this);
+    }
+
+    @Override
+    public java.lang.String toString() {
+      java.lang.StringBuilder sb = new 
java.lang.StringBuilder("drop_app_result(");
+      boolean first = true;
+
+      sb.append("success:");
+      if (this.success == null) {
+        sb.append("null");
+      } else {
+        sb.append(this.success);
+      }
+      first = false;
+      sb.append(")");
+      return sb.toString();
+    }
+
+    public void validate() throws org.apache.thrift.TException {
+      // check for required fields
+      // check for sub-struct validity
+      if (success != null) {
+        success.validate();
+      }
+    }
+
+    private void writeObject(java.io.ObjectOutputStream out) throws 
java.io.IOException {
+      try {
+        write(
+            new org.apache.thrift.protocol.TCompactProtocol(
+                new org.apache.thrift.transport.TIOStreamTransport(out)));
+      } catch (org.apache.thrift.TException te) {
+        throw new java.io.IOException(te);
+      }
+    }
+
+    private void readObject(java.io.ObjectInputStream in)
+        throws java.io.IOException, java.lang.ClassNotFoundException {
+      try {
+        read(
+            new org.apache.thrift.protocol.TCompactProtocol(
+                new org.apache.thrift.transport.TIOStreamTransport(in)));
+      } catch (org.apache.thrift.TException te) {
+        throw new java.io.IOException(te);
+      }
+    }
+
+    private static class drop_app_resultStandardSchemeFactory
+        implements org.apache.thrift.scheme.SchemeFactory {
+      public drop_app_resultStandardScheme getScheme() {
+        return new drop_app_resultStandardScheme();
+      }
+    }
+
+    private static class drop_app_resultStandardScheme
+        extends org.apache.thrift.scheme.StandardScheme<drop_app_result> {
+
+      public void read(org.apache.thrift.protocol.TProtocol iprot, 
drop_app_result struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TField schemeField;
+        iprot.readStructBegin();
+        while (true) {
+          schemeField = iprot.readFieldBegin();
+          if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+            break;
+          }
+          switch (schemeField.id) {
+            case 0: // SUCCESS
+              if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) 
{
+                struct.success =
+                    new 
org.apache.pegasus.replication.configuration_drop_app_response();
+                struct.success.read(iprot);
+                struct.setSuccessIsSet(true);
+              } else {
+                org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+              }
+              break;
+            default:
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+          }
+          iprot.readFieldEnd();
+        }
+        iprot.readStructEnd();
+
+        // check for required fields of primitive type, which can't be checked 
in the validate
+        // method
+        struct.validate();
+      }
+
+      public void write(org.apache.thrift.protocol.TProtocol oprot, 
drop_app_result struct)
+          throws org.apache.thrift.TException {
+        struct.validate();
+
+        oprot.writeStructBegin(STRUCT_DESC);
+        if (struct.success != null) {
+          oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
+          struct.success.write(oprot);
+          oprot.writeFieldEnd();
+        }
+        oprot.writeFieldStop();
+        oprot.writeStructEnd();
+      }
+    }
+
+    private static class drop_app_resultTupleSchemeFactory
+        implements org.apache.thrift.scheme.SchemeFactory {
+      public drop_app_resultTupleScheme getScheme() {
+        return new drop_app_resultTupleScheme();
+      }
+    }
+
+    private static class drop_app_resultTupleScheme
+        extends org.apache.thrift.scheme.TupleScheme<drop_app_result> {
+
+      @Override
+      public void write(org.apache.thrift.protocol.TProtocol prot, 
drop_app_result struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TTupleProtocol oprot =
+            (org.apache.thrift.protocol.TTupleProtocol) prot;
+        java.util.BitSet optionals = new java.util.BitSet();
+        if (struct.isSetSuccess()) {
+          optionals.set(0);
+        }
+        oprot.writeBitSet(optionals, 1);
+        if (struct.isSetSuccess()) {
+          struct.success.write(oprot);
+        }
+      }
+
+      @Override
+      public void read(org.apache.thrift.protocol.TProtocol prot, 
drop_app_result struct)
+          throws org.apache.thrift.TException {
+        org.apache.thrift.protocol.TTupleProtocol iprot =
+            (org.apache.thrift.protocol.TTupleProtocol) prot;
+        java.util.BitSet incoming = iprot.readBitSet(1);
+        if (incoming.get(0)) {
+          struct.success = new 
org.apache.pegasus.replication.configuration_drop_app_response();
           struct.success.read(iprot);
           struct.setSuccessIsSet(true);
         }
diff --git 
a/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClient.java 
b/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClient.java
index 157473b9..2f869d21 100644
--- 
a/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClient.java
+++ 
b/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClient.java
@@ -24,6 +24,7 @@ import java.util.Properties;
 import org.apache.pegasus.base.error_code;
 import org.apache.pegasus.base.gpid;
 import org.apache.pegasus.operator.create_app_operator;
+import org.apache.pegasus.operator.drop_app_operator;
 import org.apache.pegasus.operator.query_cfg_operator;
 import org.apache.pegasus.replication.*;
 import org.apache.pegasus.rpc.Meta;
@@ -194,4 +195,27 @@ public class PegasusAdminClient extends 
PegasusAbstractClient
 
     return readyCount == response.partition_count;
   }
+
+  @Override
+  public void dropApp(String appName, int reserveSeconds) throws PException {
+    if (appName.isEmpty()) {
+      throw new PException(new IllegalArgumentException("dropApp failed: empty 
appName"));
+    }
+
+    drop_app_options options = new drop_app_options();
+    options.setSuccess_if_not_exist(true);
+    options.setReserve_seconds(reserveSeconds);
+
+    configuration_drop_app_request request = new 
configuration_drop_app_request();
+    request.setApp_name(appName);
+    request.setOptions(options);
+
+    drop_app_operator app_operator = new drop_app_operator(appName, request);
+    error_code.error_types error = this.meta.operate(app_operator, 
META_RETRY_MIN_COUNT);
+
+    if (error != error_code.error_types.ERR_OK) {
+      throw new PException(
+          String.format("Drop app:%s failed! error: %s.", appName, 
error.toString()));
+    }
+  }
 }
diff --git 
a/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClientInterface.java
 
b/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClientInterface.java
index c92f45c0..103a1cbc 100644
--- 
a/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClientInterface.java
+++ 
b/java-client/src/main/java/org/apache/pegasus/client/PegasusAdminClientInterface.java
@@ -58,6 +58,8 @@ public interface PegasusAdminClientInterface {
    */
   public boolean isAppHealthy(String appName, int replicaCount) throws 
PException;
 
+  public void dropApp(String appName, int reserveSeconds) throws PException;
+
   /** close the client */
   public void close();
 }
diff --git 
a/java-client/src/main/java/org/apache/pegasus/operator/drop_app_operator.java 
b/java-client/src/main/java/org/apache/pegasus/operator/drop_app_operator.java
new file mode 100644
index 00000000..691af053
--- /dev/null
+++ 
b/java-client/src/main/java/org/apache/pegasus/operator/drop_app_operator.java
@@ -0,0 +1,67 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pegasus.operator;
+
+import org.apache.pegasus.apps.meta;
+import org.apache.pegasus.base.gpid;
+import org.apache.pegasus.replication.configuration_drop_app_request;
+import org.apache.pegasus.replication.configuration_drop_app_response;
+import org.apache.thrift.TException;
+import org.apache.thrift.protocol.TMessage;
+import org.apache.thrift.protocol.TMessageType;
+import org.apache.thrift.protocol.TProtocol;
+
+public class drop_app_operator extends client_operator {
+  public drop_app_operator(String appName, configuration_drop_app_request 
reqeust) {
+    super(new gpid(), appName, 0);
+    this.request = reqeust;
+  }
+
+  @Override
+  public String name() {
+    return "drop_app_operator";
+  }
+
+  @Override
+  public void send_data(TProtocol oprot, int sequence_id) throws TException {
+    TMessage msg = new TMessage("RPC_CM_DROP_APP", TMessageType.CALL, 
sequence_id);
+    oprot.writeMessageBegin(msg);
+    org.apache.pegasus.apps.meta.drop_app_args args = new 
meta.drop_app_args(request);
+    args.write(oprot);
+    oprot.writeMessageEnd();
+  }
+
+  @Override
+  public void recv_data(TProtocol iprot) throws TException {
+    meta.drop_app_result result = new meta.drop_app_result();
+    result.read(iprot);
+    if (result.isSetSuccess()) response = result.success;
+    else
+      throw new org.apache.thrift.TApplicationException(
+          org.apache.thrift.TApplicationException.MISSING_RESULT,
+          "drop app failed: unknown result");
+  }
+
+  public configuration_drop_app_response get_response() {
+    return response;
+  }
+
+  private configuration_drop_app_request request;
+  private configuration_drop_app_response response;
+}
diff --git 
a/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_request.java
 
b/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_request.java
new file mode 100644
index 00000000..e9699d4f
--- /dev/null
+++ 
b/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_request.java
@@ -0,0 +1,532 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+/**
+ * Autogenerated by Thrift Compiler (0.11.0)
+ *
+ * <p>DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *
+ * @generated
+ */
+package org.apache.pegasus.replication;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
[email protected](
+    value = "Autogenerated by Thrift Compiler (0.11.0)",
+    date = "2022-05-17")
+public class configuration_drop_app_request
+    implements org.apache.thrift.TBase<
+            configuration_drop_app_request, 
configuration_drop_app_request._Fields>,
+        java.io.Serializable,
+        Cloneable,
+        Comparable<configuration_drop_app_request> {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC =
+      new org.apache.thrift.protocol.TStruct("configuration_drop_app_request");
+
+  private static final org.apache.thrift.protocol.TField APP_NAME_FIELD_DESC =
+      new org.apache.thrift.protocol.TField(
+          "app_name", org.apache.thrift.protocol.TType.STRING, (short) 1);
+  private static final org.apache.thrift.protocol.TField OPTIONS_FIELD_DESC =
+      new org.apache.thrift.protocol.TField(
+          "options", org.apache.thrift.protocol.TType.STRUCT, (short) 2);
+
+  private static final org.apache.thrift.scheme.SchemeFactory 
STANDARD_SCHEME_FACTORY =
+      new configuration_drop_app_requestStandardSchemeFactory();
+  private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
+      new configuration_drop_app_requestTupleSchemeFactory();
+
+  public java.lang.String app_name; // required
+  public drop_app_options options; // required
+
+  /**
+   * The set of fields this struct contains, along with convenience methods 
for finding and
+   * manipulating them.
+   */
+  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+    APP_NAME((short) 1, "app_name"),
+    OPTIONS((short) 2, "options");
+
+    private static final java.util.Map<java.lang.String, _Fields> byName =
+        new java.util.HashMap<java.lang.String, _Fields>();
+
+    static {
+      for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
+        byName.put(field.getFieldName(), field);
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, or null if its not 
found. */
+    public static _Fields findByThriftId(int fieldId) {
+      switch (fieldId) {
+        case 1: // APP_NAME
+          return APP_NAME;
+        case 2: // OPTIONS
+          return OPTIONS;
+        default:
+          return null;
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, throwing an exception 
if it is not found. */
+    public static _Fields findByThriftIdOrThrow(int fieldId) {
+      _Fields fields = findByThriftId(fieldId);
+      if (fields == null)
+        throw new java.lang.IllegalArgumentException("Field " + fieldId + " 
doesn't exist!");
+      return fields;
+    }
+
+    /** Find the _Fields constant that matches name, or null if its not found. 
*/
+    public static _Fields findByName(java.lang.String name) {
+      return byName.get(name);
+    }
+
+    private final short _thriftId;
+    private final java.lang.String _fieldName;
+
+    _Fields(short thriftId, java.lang.String fieldName) {
+      _thriftId = thriftId;
+      _fieldName = fieldName;
+    }
+
+    public short getThriftFieldId() {
+      return _thriftId;
+    }
+
+    public java.lang.String getFieldName() {
+      return _fieldName;
+    }
+  }
+
+  // isset id assignments
+  public static final java.util.Map<_Fields, 
org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+
+  static {
+    java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap =
+        new java.util.EnumMap<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+    tmpMap.put(
+        _Fields.APP_NAME,
+        new org.apache.thrift.meta_data.FieldMetaData(
+            "app_name",
+            org.apache.thrift.TFieldRequirementType.DEFAULT,
+            new org.apache.thrift.meta_data.FieldValueMetaData(
+                org.apache.thrift.protocol.TType.STRING)));
+    tmpMap.put(
+        _Fields.OPTIONS,
+        new org.apache.thrift.meta_data.FieldMetaData(
+            "options",
+            org.apache.thrift.TFieldRequirementType.DEFAULT,
+            new org.apache.thrift.meta_data.StructMetaData(
+                org.apache.thrift.protocol.TType.STRUCT, 
drop_app_options.class)));
+    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
+        configuration_drop_app_request.class, metaDataMap);
+  }
+
+  public configuration_drop_app_request() {}
+
+  public configuration_drop_app_request(java.lang.String app_name, 
drop_app_options options) {
+    this();
+    this.app_name = app_name;
+    this.options = options;
+  }
+
+  /** Performs a deep copy on <i>other</i>. */
+  public configuration_drop_app_request(configuration_drop_app_request other) {
+    if (other.isSetApp_name()) {
+      this.app_name = other.app_name;
+    }
+    if (other.isSetOptions()) {
+      this.options = new drop_app_options(other.options);
+    }
+  }
+
+  public configuration_drop_app_request deepCopy() {
+    return new configuration_drop_app_request(this);
+  }
+
+  @Override
+  public void clear() {
+    this.app_name = null;
+    this.options = null;
+  }
+
+  public java.lang.String getApp_name() {
+    return this.app_name;
+  }
+
+  public configuration_drop_app_request setApp_name(java.lang.String app_name) 
{
+    this.app_name = app_name;
+    return this;
+  }
+
+  public void unsetApp_name() {
+    this.app_name = null;
+  }
+
+  /** Returns true if field app_name is set (has been assigned a value) and 
false otherwise */
+  public boolean isSetApp_name() {
+    return this.app_name != null;
+  }
+
+  public void setApp_nameIsSet(boolean value) {
+    if (!value) {
+      this.app_name = null;
+    }
+  }
+
+  public drop_app_options getOptions() {
+    return this.options;
+  }
+
+  public configuration_drop_app_request setOptions(drop_app_options options) {
+    this.options = options;
+    return this;
+  }
+
+  public void unsetOptions() {
+    this.options = null;
+  }
+
+  /** Returns true if field options is set (has been assigned a value) and 
false otherwise */
+  public boolean isSetOptions() {
+    return this.options != null;
+  }
+
+  public void setOptionsIsSet(boolean value) {
+    if (!value) {
+      this.options = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, java.lang.Object value) {
+    switch (field) {
+      case APP_NAME:
+        if (value == null) {
+          unsetApp_name();
+        } else {
+          setApp_name((java.lang.String) value);
+        }
+        break;
+
+      case OPTIONS:
+        if (value == null) {
+          unsetOptions();
+        } else {
+          setOptions((drop_app_options) value);
+        }
+        break;
+    }
+  }
+
+  public java.lang.Object getFieldValue(_Fields field) {
+    switch (field) {
+      case APP_NAME:
+        return getApp_name();
+
+      case OPTIONS:
+        return getOptions();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  /**
+   * Returns true if field corresponding to fieldID is set (has been assigned 
a value) and false
+   * otherwise
+   */
+  public boolean isSet(_Fields field) {
+    if (field == null) {
+      throw new java.lang.IllegalArgumentException();
+    }
+
+    switch (field) {
+      case APP_NAME:
+        return isSetApp_name();
+      case OPTIONS:
+        return isSetOptions();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(java.lang.Object that) {
+    if (that == null) return false;
+    if (that instanceof configuration_drop_app_request)
+      return this.equals((configuration_drop_app_request) that);
+    return false;
+  }
+
+  public boolean equals(configuration_drop_app_request that) {
+    if (that == null) return false;
+    if (this == that) return true;
+
+    boolean this_present_app_name = true && this.isSetApp_name();
+    boolean that_present_app_name = true && that.isSetApp_name();
+    if (this_present_app_name || that_present_app_name) {
+      if (!(this_present_app_name && that_present_app_name)) return false;
+      if (!this.app_name.equals(that.app_name)) return false;
+    }
+
+    boolean this_present_options = true && this.isSetOptions();
+    boolean that_present_options = true && that.isSetOptions();
+    if (this_present_options || that_present_options) {
+      if (!(this_present_options && that_present_options)) return false;
+      if (!this.options.equals(that.options)) return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    int hashCode = 1;
+
+    hashCode = hashCode * 8191 + ((isSetApp_name()) ? 131071 : 524287);
+    if (isSetApp_name()) hashCode = hashCode * 8191 + app_name.hashCode();
+
+    hashCode = hashCode * 8191 + ((isSetOptions()) ? 131071 : 524287);
+    if (isSetOptions()) hashCode = hashCode * 8191 + options.hashCode();
+
+    return hashCode;
+  }
+
+  @Override
+  public int compareTo(configuration_drop_app_request other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+
+    lastComparison = 
java.lang.Boolean.valueOf(isSetApp_name()).compareTo(other.isSetApp_name());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetApp_name()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.app_name, 
other.app_name);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison = 
java.lang.Boolean.valueOf(isSetOptions()).compareTo(other.isSetOptions());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetOptions()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.options, 
other.options);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    return 0;
+  }
+
+  public _Fields fieldForId(int fieldId) {
+    return _Fields.findByThriftId(fieldId);
+  }
+
+  public void read(org.apache.thrift.protocol.TProtocol iprot) throws 
org.apache.thrift.TException {
+    scheme(iprot).read(iprot, this);
+  }
+
+  public void write(org.apache.thrift.protocol.TProtocol oprot)
+      throws org.apache.thrift.TException {
+    scheme(oprot).write(oprot, this);
+  }
+
+  @Override
+  public java.lang.String toString() {
+    java.lang.StringBuilder sb = new 
java.lang.StringBuilder("configuration_drop_app_request(");
+    boolean first = true;
+
+    sb.append("app_name:");
+    if (this.app_name == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.app_name);
+    }
+    first = false;
+    if (!first) sb.append(", ");
+    sb.append("options:");
+    if (this.options == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.options);
+    }
+    first = false;
+    sb.append(")");
+    return sb.toString();
+  }
+
+  public void validate() throws org.apache.thrift.TException {
+    // check for required fields
+    // check for sub-struct validity
+    if (options != null) {
+      options.validate();
+    }
+  }
+
+  private void writeObject(java.io.ObjectOutputStream out) throws 
java.io.IOException {
+    try {
+      write(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(out)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private void readObject(java.io.ObjectInputStream in)
+      throws java.io.IOException, java.lang.ClassNotFoundException {
+    try {
+      read(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(in)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private static class configuration_drop_app_requestStandardSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public configuration_drop_app_requestStandardScheme getScheme() {
+      return new configuration_drop_app_requestStandardScheme();
+    }
+  }
+
+  private static class configuration_drop_app_requestStandardScheme
+      extends 
org.apache.thrift.scheme.StandardScheme<configuration_drop_app_request> {
+
+    public void read(
+        org.apache.thrift.protocol.TProtocol iprot, 
configuration_drop_app_request struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TField schemeField;
+      iprot.readStructBegin();
+      while (true) {
+        schemeField = iprot.readFieldBegin();
+        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+          break;
+        }
+        switch (schemeField.id) {
+          case 1: // APP_NAME
+            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+              struct.app_name = iprot.readString();
+              struct.setApp_nameIsSet(true);
+            } else {
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+            }
+            break;
+          case 2: // OPTIONS
+            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
+              struct.options = new drop_app_options();
+              struct.options.read(iprot);
+              struct.setOptionsIsSet(true);
+            } else {
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked 
in the validate method
+      struct.validate();
+    }
+
+    public void write(
+        org.apache.thrift.protocol.TProtocol oprot, 
configuration_drop_app_request struct)
+        throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      if (struct.app_name != null) {
+        oprot.writeFieldBegin(APP_NAME_FIELD_DESC);
+        oprot.writeString(struct.app_name);
+        oprot.writeFieldEnd();
+      }
+      if (struct.options != null) {
+        oprot.writeFieldBegin(OPTIONS_FIELD_DESC);
+        struct.options.write(oprot);
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+  }
+
+  private static class configuration_drop_app_requestTupleSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public configuration_drop_app_requestTupleScheme getScheme() {
+      return new configuration_drop_app_requestTupleScheme();
+    }
+  }
+
+  private static class configuration_drop_app_requestTupleScheme
+      extends 
org.apache.thrift.scheme.TupleScheme<configuration_drop_app_request> {
+
+    @Override
+    public void write(
+        org.apache.thrift.protocol.TProtocol prot, 
configuration_drop_app_request struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol oprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet optionals = new java.util.BitSet();
+      if (struct.isSetApp_name()) {
+        optionals.set(0);
+      }
+      if (struct.isSetOptions()) {
+        optionals.set(1);
+      }
+      oprot.writeBitSet(optionals, 2);
+      if (struct.isSetApp_name()) {
+        oprot.writeString(struct.app_name);
+      }
+      if (struct.isSetOptions()) {
+        struct.options.write(oprot);
+      }
+    }
+
+    @Override
+    public void read(
+        org.apache.thrift.protocol.TProtocol prot, 
configuration_drop_app_request struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol iprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet incoming = iprot.readBitSet(2);
+      if (incoming.get(0)) {
+        struct.app_name = iprot.readString();
+        struct.setApp_nameIsSet(true);
+      }
+      if (incoming.get(1)) {
+        struct.options = new drop_app_options();
+        struct.options.read(iprot);
+        struct.setOptionsIsSet(true);
+      }
+    }
+  }
+
+  private static <S extends org.apache.thrift.scheme.IScheme> S scheme(
+      org.apache.thrift.protocol.TProtocol proto) {
+    return 
(org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme())
+            ? STANDARD_SCHEME_FACTORY
+            : TUPLE_SCHEME_FACTORY)
+        .getScheme();
+  }
+}
diff --git 
a/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_response.java
 
b/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_response.java
new file mode 100644
index 00000000..0b362db1
--- /dev/null
+++ 
b/java-client/src/main/java/org/apache/pegasus/replication/configuration_drop_app_response.java
@@ -0,0 +1,426 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+/**
+ * Autogenerated by Thrift Compiler (0.11.0)
+ *
+ * <p>DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *
+ * @generated
+ */
+package org.apache.pegasus.replication;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
[email protected](
+    value = "Autogenerated by Thrift Compiler (0.11.0)",
+    date = "2022-05-17")
+public class configuration_drop_app_response
+    implements org.apache.thrift.TBase<
+            configuration_drop_app_response, 
configuration_drop_app_response._Fields>,
+        java.io.Serializable,
+        Cloneable,
+        Comparable<configuration_drop_app_response> {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC =
+      new 
org.apache.thrift.protocol.TStruct("configuration_drop_app_response");
+
+  private static final org.apache.thrift.protocol.TField ERR_FIELD_DESC =
+      new org.apache.thrift.protocol.TField(
+          "err", org.apache.thrift.protocol.TType.STRUCT, (short) 1);
+
+  private static final org.apache.thrift.scheme.SchemeFactory 
STANDARD_SCHEME_FACTORY =
+      new configuration_drop_app_responseStandardSchemeFactory();
+  private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
+      new configuration_drop_app_responseTupleSchemeFactory();
+
+  public org.apache.pegasus.base.error_code err; // required
+
+  /**
+   * The set of fields this struct contains, along with convenience methods 
for finding and
+   * manipulating them.
+   */
+  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+    ERR((short) 1, "err");
+
+    private static final java.util.Map<java.lang.String, _Fields> byName =
+        new java.util.HashMap<java.lang.String, _Fields>();
+
+    static {
+      for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
+        byName.put(field.getFieldName(), field);
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, or null if its not 
found. */
+    public static _Fields findByThriftId(int fieldId) {
+      switch (fieldId) {
+        case 1: // ERR
+          return ERR;
+        default:
+          return null;
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, throwing an exception 
if it is not found. */
+    public static _Fields findByThriftIdOrThrow(int fieldId) {
+      _Fields fields = findByThriftId(fieldId);
+      if (fields == null)
+        throw new java.lang.IllegalArgumentException("Field " + fieldId + " 
doesn't exist!");
+      return fields;
+    }
+
+    /** Find the _Fields constant that matches name, or null if its not found. 
*/
+    public static _Fields findByName(java.lang.String name) {
+      return byName.get(name);
+    }
+
+    private final short _thriftId;
+    private final java.lang.String _fieldName;
+
+    _Fields(short thriftId, java.lang.String fieldName) {
+      _thriftId = thriftId;
+      _fieldName = fieldName;
+    }
+
+    public short getThriftFieldId() {
+      return _thriftId;
+    }
+
+    public java.lang.String getFieldName() {
+      return _fieldName;
+    }
+  }
+
+  // isset id assignments
+  public static final java.util.Map<_Fields, 
org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+
+  static {
+    java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap =
+        new java.util.EnumMap<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+    tmpMap.put(
+        _Fields.ERR,
+        new org.apache.thrift.meta_data.FieldMetaData(
+            "err",
+            org.apache.thrift.TFieldRequirementType.DEFAULT,
+            new org.apache.thrift.meta_data.StructMetaData(
+                org.apache.thrift.protocol.TType.STRUCT,
+                org.apache.pegasus.base.error_code.class)));
+    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
+        configuration_drop_app_response.class, metaDataMap);
+  }
+
+  public configuration_drop_app_response() {}
+
+  public configuration_drop_app_response(org.apache.pegasus.base.error_code 
err) {
+    this();
+    this.err = err;
+  }
+
+  /** Performs a deep copy on <i>other</i>. */
+  public configuration_drop_app_response(configuration_drop_app_response 
other) {
+    if (other.isSetErr()) {
+      this.err = new org.apache.pegasus.base.error_code(other.err);
+    }
+  }
+
+  public configuration_drop_app_response deepCopy() {
+    return new configuration_drop_app_response(this);
+  }
+
+  @Override
+  public void clear() {
+    this.err = null;
+  }
+
+  public org.apache.pegasus.base.error_code getErr() {
+    return this.err;
+  }
+
+  public configuration_drop_app_response 
setErr(org.apache.pegasus.base.error_code err) {
+    this.err = err;
+    return this;
+  }
+
+  public void unsetErr() {
+    this.err = null;
+  }
+
+  /** Returns true if field err is set (has been assigned a value) and false 
otherwise */
+  public boolean isSetErr() {
+    return this.err != null;
+  }
+
+  public void setErrIsSet(boolean value) {
+    if (!value) {
+      this.err = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, java.lang.Object value) {
+    switch (field) {
+      case ERR:
+        if (value == null) {
+          unsetErr();
+        } else {
+          setErr((org.apache.pegasus.base.error_code) value);
+        }
+        break;
+    }
+  }
+
+  public java.lang.Object getFieldValue(_Fields field) {
+    switch (field) {
+      case ERR:
+        return getErr();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  /**
+   * Returns true if field corresponding to fieldID is set (has been assigned 
a value) and false
+   * otherwise
+   */
+  public boolean isSet(_Fields field) {
+    if (field == null) {
+      throw new java.lang.IllegalArgumentException();
+    }
+
+    switch (field) {
+      case ERR:
+        return isSetErr();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(java.lang.Object that) {
+    if (that == null) return false;
+    if (that instanceof configuration_drop_app_response)
+      return this.equals((configuration_drop_app_response) that);
+    return false;
+  }
+
+  public boolean equals(configuration_drop_app_response that) {
+    if (that == null) return false;
+    if (this == that) return true;
+
+    boolean this_present_err = true && this.isSetErr();
+    boolean that_present_err = true && that.isSetErr();
+    if (this_present_err || that_present_err) {
+      if (!(this_present_err && that_present_err)) return false;
+      if (!this.err.equals(that.err)) return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    int hashCode = 1;
+
+    hashCode = hashCode * 8191 + ((isSetErr()) ? 131071 : 524287);
+    if (isSetErr()) hashCode = hashCode * 8191 + err.hashCode();
+
+    return hashCode;
+  }
+
+  @Override
+  public int compareTo(configuration_drop_app_response other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+
+    lastComparison = 
java.lang.Boolean.valueOf(isSetErr()).compareTo(other.isSetErr());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetErr()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.err, 
other.err);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    return 0;
+  }
+
+  public _Fields fieldForId(int fieldId) {
+    return _Fields.findByThriftId(fieldId);
+  }
+
+  public void read(org.apache.thrift.protocol.TProtocol iprot) throws 
org.apache.thrift.TException {
+    scheme(iprot).read(iprot, this);
+  }
+
+  public void write(org.apache.thrift.protocol.TProtocol oprot)
+      throws org.apache.thrift.TException {
+    scheme(oprot).write(oprot, this);
+  }
+
+  @Override
+  public java.lang.String toString() {
+    java.lang.StringBuilder sb = new 
java.lang.StringBuilder("configuration_drop_app_response(");
+    boolean first = true;
+
+    sb.append("err:");
+    if (this.err == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.err);
+    }
+    first = false;
+    sb.append(")");
+    return sb.toString();
+  }
+
+  public void validate() throws org.apache.thrift.TException {
+    // check for required fields
+    // check for sub-struct validity
+    if (err != null) {
+      err.validate();
+    }
+  }
+
+  private void writeObject(java.io.ObjectOutputStream out) throws 
java.io.IOException {
+    try {
+      write(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(out)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private void readObject(java.io.ObjectInputStream in)
+      throws java.io.IOException, java.lang.ClassNotFoundException {
+    try {
+      read(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(in)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private static class configuration_drop_app_responseStandardSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public configuration_drop_app_responseStandardScheme getScheme() {
+      return new configuration_drop_app_responseStandardScheme();
+    }
+  }
+
+  private static class configuration_drop_app_responseStandardScheme
+      extends 
org.apache.thrift.scheme.StandardScheme<configuration_drop_app_response> {
+
+    public void read(
+        org.apache.thrift.protocol.TProtocol iprot, 
configuration_drop_app_response struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TField schemeField;
+      iprot.readStructBegin();
+      while (true) {
+        schemeField = iprot.readFieldBegin();
+        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+          break;
+        }
+        switch (schemeField.id) {
+          case 1: // ERR
+            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
+              struct.err = new org.apache.pegasus.base.error_code();
+              struct.err.read(iprot);
+              struct.setErrIsSet(true);
+            } else {
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked 
in the validate method
+      struct.validate();
+    }
+
+    public void write(
+        org.apache.thrift.protocol.TProtocol oprot, 
configuration_drop_app_response struct)
+        throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      if (struct.err != null) {
+        oprot.writeFieldBegin(ERR_FIELD_DESC);
+        struct.err.write(oprot);
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+  }
+
+  private static class configuration_drop_app_responseTupleSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public configuration_drop_app_responseTupleScheme getScheme() {
+      return new configuration_drop_app_responseTupleScheme();
+    }
+  }
+
+  private static class configuration_drop_app_responseTupleScheme
+      extends 
org.apache.thrift.scheme.TupleScheme<configuration_drop_app_response> {
+
+    @Override
+    public void write(
+        org.apache.thrift.protocol.TProtocol prot, 
configuration_drop_app_response struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol oprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet optionals = new java.util.BitSet();
+      if (struct.isSetErr()) {
+        optionals.set(0);
+      }
+      oprot.writeBitSet(optionals, 1);
+      if (struct.isSetErr()) {
+        struct.err.write(oprot);
+      }
+    }
+
+    @Override
+    public void read(
+        org.apache.thrift.protocol.TProtocol prot, 
configuration_drop_app_response struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol iprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet incoming = iprot.readBitSet(1);
+      if (incoming.get(0)) {
+        struct.err = new org.apache.pegasus.base.error_code();
+        struct.err.read(iprot);
+        struct.setErrIsSet(true);
+      }
+    }
+  }
+
+  private static <S extends org.apache.thrift.scheme.IScheme> S scheme(
+      org.apache.thrift.protocol.TProtocol proto) {
+    return 
(org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme())
+            ? STANDARD_SCHEME_FACTORY
+            : TUPLE_SCHEME_FACTORY)
+        .getScheme();
+  }
+}
diff --git 
a/java-client/src/main/java/org/apache/pegasus/replication/drop_app_options.java
 
b/java-client/src/main/java/org/apache/pegasus/replication/drop_app_options.java
new file mode 100644
index 00000000..f44dcaa3
--- /dev/null
+++ 
b/java-client/src/main/java/org/apache/pegasus/replication/drop_app_options.java
@@ -0,0 +1,534 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+/**
+ * Autogenerated by Thrift Compiler (0.11.0)
+ *
+ * <p>DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *
+ * @generated
+ */
+package org.apache.pegasus.replication;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
[email protected](
+    value = "Autogenerated by Thrift Compiler (0.11.0)",
+    date = "2022-05-17")
+public class drop_app_options
+    implements org.apache.thrift.TBase<drop_app_options, 
drop_app_options._Fields>,
+        java.io.Serializable,
+        Cloneable,
+        Comparable<drop_app_options> {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC =
+      new org.apache.thrift.protocol.TStruct("drop_app_options");
+
+  private static final org.apache.thrift.protocol.TField 
SUCCESS_IF_NOT_EXIST_FIELD_DESC =
+      new org.apache.thrift.protocol.TField(
+          "success_if_not_exist", org.apache.thrift.protocol.TType.BOOL, 
(short) 1);
+  private static final org.apache.thrift.protocol.TField 
RESERVE_SECONDS_FIELD_DESC =
+      new org.apache.thrift.protocol.TField(
+          "reserve_seconds", org.apache.thrift.protocol.TType.I64, (short) 2);
+
+  private static final org.apache.thrift.scheme.SchemeFactory 
STANDARD_SCHEME_FACTORY =
+      new drop_app_optionsStandardSchemeFactory();
+  private static final org.apache.thrift.scheme.SchemeFactory 
TUPLE_SCHEME_FACTORY =
+      new drop_app_optionsTupleSchemeFactory();
+
+  public boolean success_if_not_exist; // required
+  public long reserve_seconds; // optional
+
+  /**
+   * The set of fields this struct contains, along with convenience methods 
for finding and
+   * manipulating them.
+   */
+  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+    SUCCESS_IF_NOT_EXIST((short) 1, "success_if_not_exist"),
+    RESERVE_SECONDS((short) 2, "reserve_seconds");
+
+    private static final java.util.Map<java.lang.String, _Fields> byName =
+        new java.util.HashMap<java.lang.String, _Fields>();
+
+    static {
+      for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
+        byName.put(field.getFieldName(), field);
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, or null if its not 
found. */
+    public static _Fields findByThriftId(int fieldId) {
+      switch (fieldId) {
+        case 1: // SUCCESS_IF_NOT_EXIST
+          return SUCCESS_IF_NOT_EXIST;
+        case 2: // RESERVE_SECONDS
+          return RESERVE_SECONDS;
+        default:
+          return null;
+      }
+    }
+
+    /** Find the _Fields constant that matches fieldId, throwing an exception 
if it is not found. */
+    public static _Fields findByThriftIdOrThrow(int fieldId) {
+      _Fields fields = findByThriftId(fieldId);
+      if (fields == null)
+        throw new java.lang.IllegalArgumentException("Field " + fieldId + " 
doesn't exist!");
+      return fields;
+    }
+
+    /** Find the _Fields constant that matches name, or null if its not found. 
*/
+    public static _Fields findByName(java.lang.String name) {
+      return byName.get(name);
+    }
+
+    private final short _thriftId;
+    private final java.lang.String _fieldName;
+
+    _Fields(short thriftId, java.lang.String fieldName) {
+      _thriftId = thriftId;
+      _fieldName = fieldName;
+    }
+
+    public short getThriftFieldId() {
+      return _thriftId;
+    }
+
+    public java.lang.String getFieldName() {
+      return _fieldName;
+    }
+  }
+
+  // isset id assignments
+  private static final int __SUCCESS_IF_NOT_EXIST_ISSET_ID = 0;
+  private static final int __RESERVE_SECONDS_ISSET_ID = 1;
+  private byte __isset_bitfield = 0;
+  private static final _Fields optionals[] = {_Fields.RESERVE_SECONDS};
+  public static final java.util.Map<_Fields, 
org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+
+  static {
+    java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap =
+        new java.util.EnumMap<_Fields, 
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+    tmpMap.put(
+        _Fields.SUCCESS_IF_NOT_EXIST,
+        new org.apache.thrift.meta_data.FieldMetaData(
+            "success_if_not_exist",
+            org.apache.thrift.TFieldRequirementType.DEFAULT,
+            new org.apache.thrift.meta_data.FieldValueMetaData(
+                org.apache.thrift.protocol.TType.BOOL)));
+    tmpMap.put(
+        _Fields.RESERVE_SECONDS,
+        new org.apache.thrift.meta_data.FieldMetaData(
+            "reserve_seconds",
+            org.apache.thrift.TFieldRequirementType.OPTIONAL,
+            new org.apache.thrift.meta_data.FieldValueMetaData(
+                org.apache.thrift.protocol.TType.I64)));
+    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(
+        drop_app_options.class, metaDataMap);
+  }
+
+  public drop_app_options() {}
+
+  public drop_app_options(boolean success_if_not_exist) {
+    this();
+    this.success_if_not_exist = success_if_not_exist;
+    setSuccess_if_not_existIsSet(true);
+  }
+
+  /** Performs a deep copy on <i>other</i>. */
+  public drop_app_options(drop_app_options other) {
+    __isset_bitfield = other.__isset_bitfield;
+    this.success_if_not_exist = other.success_if_not_exist;
+    this.reserve_seconds = other.reserve_seconds;
+  }
+
+  public drop_app_options deepCopy() {
+    return new drop_app_options(this);
+  }
+
+  @Override
+  public void clear() {
+    setSuccess_if_not_existIsSet(false);
+    this.success_if_not_exist = false;
+    setReserve_secondsIsSet(false);
+    this.reserve_seconds = 0;
+  }
+
+  public boolean isSuccess_if_not_exist() {
+    return this.success_if_not_exist;
+  }
+
+  public drop_app_options setSuccess_if_not_exist(boolean 
success_if_not_exist) {
+    this.success_if_not_exist = success_if_not_exist;
+    setSuccess_if_not_existIsSet(true);
+    return this;
+  }
+
+  public void unsetSuccess_if_not_exist() {
+    __isset_bitfield =
+        org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, 
__SUCCESS_IF_NOT_EXIST_ISSET_ID);
+  }
+
+  /**
+   * Returns true if field success_if_not_exist is set (has been assigned a 
value) and false
+   * otherwise
+   */
+  public boolean isSetSuccess_if_not_exist() {
+    return org.apache.thrift.EncodingUtils.testBit(
+        __isset_bitfield, __SUCCESS_IF_NOT_EXIST_ISSET_ID);
+  }
+
+  public void setSuccess_if_not_existIsSet(boolean value) {
+    __isset_bitfield =
+        org.apache.thrift.EncodingUtils.setBit(
+            __isset_bitfield, __SUCCESS_IF_NOT_EXIST_ISSET_ID, value);
+  }
+
+  public long getReserve_seconds() {
+    return this.reserve_seconds;
+  }
+
+  public drop_app_options setReserve_seconds(long reserve_seconds) {
+    this.reserve_seconds = reserve_seconds;
+    setReserve_secondsIsSet(true);
+    return this;
+  }
+
+  public void unsetReserve_seconds() {
+    __isset_bitfield =
+        org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, 
__RESERVE_SECONDS_ISSET_ID);
+  }
+
+  /**
+   * Returns true if field reserve_seconds is set (has been assigned a value) 
and false otherwise
+   */
+  public boolean isSetReserve_seconds() {
+    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, 
__RESERVE_SECONDS_ISSET_ID);
+  }
+
+  public void setReserve_secondsIsSet(boolean value) {
+    __isset_bitfield =
+        org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, 
__RESERVE_SECONDS_ISSET_ID, value);
+  }
+
+  public void setFieldValue(_Fields field, java.lang.Object value) {
+    switch (field) {
+      case SUCCESS_IF_NOT_EXIST:
+        if (value == null) {
+          unsetSuccess_if_not_exist();
+        } else {
+          setSuccess_if_not_exist((java.lang.Boolean) value);
+        }
+        break;
+
+      case RESERVE_SECONDS:
+        if (value == null) {
+          unsetReserve_seconds();
+        } else {
+          setReserve_seconds((java.lang.Long) value);
+        }
+        break;
+    }
+  }
+
+  public java.lang.Object getFieldValue(_Fields field) {
+    switch (field) {
+      case SUCCESS_IF_NOT_EXIST:
+        return isSuccess_if_not_exist();
+
+      case RESERVE_SECONDS:
+        return getReserve_seconds();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  /**
+   * Returns true if field corresponding to fieldID is set (has been assigned 
a value) and false
+   * otherwise
+   */
+  public boolean isSet(_Fields field) {
+    if (field == null) {
+      throw new java.lang.IllegalArgumentException();
+    }
+
+    switch (field) {
+      case SUCCESS_IF_NOT_EXIST:
+        return isSetSuccess_if_not_exist();
+      case RESERVE_SECONDS:
+        return isSetReserve_seconds();
+    }
+    throw new java.lang.IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(java.lang.Object that) {
+    if (that == null) return false;
+    if (that instanceof drop_app_options) return 
this.equals((drop_app_options) that);
+    return false;
+  }
+
+  public boolean equals(drop_app_options that) {
+    if (that == null) return false;
+    if (this == that) return true;
+
+    boolean this_present_success_if_not_exist = true;
+    boolean that_present_success_if_not_exist = true;
+    if (this_present_success_if_not_exist || 
that_present_success_if_not_exist) {
+      if (!(this_present_success_if_not_exist && 
that_present_success_if_not_exist)) return false;
+      if (this.success_if_not_exist != that.success_if_not_exist) return false;
+    }
+
+    boolean this_present_reserve_seconds = true && this.isSetReserve_seconds();
+    boolean that_present_reserve_seconds = true && that.isSetReserve_seconds();
+    if (this_present_reserve_seconds || that_present_reserve_seconds) {
+      if (!(this_present_reserve_seconds && that_present_reserve_seconds)) 
return false;
+      if (this.reserve_seconds != that.reserve_seconds) return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    int hashCode = 1;
+
+    hashCode = hashCode * 8191 + ((success_if_not_exist) ? 131071 : 524287);
+
+    hashCode = hashCode * 8191 + ((isSetReserve_seconds()) ? 131071 : 524287);
+    if (isSetReserve_seconds())
+      hashCode = hashCode * 8191 + 
org.apache.thrift.TBaseHelper.hashCode(reserve_seconds);
+
+    return hashCode;
+  }
+
+  @Override
+  public int compareTo(drop_app_options other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+
+    lastComparison =
+        java.lang.Boolean.valueOf(isSetSuccess_if_not_exist())
+            .compareTo(other.isSetSuccess_if_not_exist());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetSuccess_if_not_exist()) {
+      lastComparison =
+          org.apache.thrift.TBaseHelper.compareTo(
+              this.success_if_not_exist, other.success_if_not_exist);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison =
+        
java.lang.Boolean.valueOf(isSetReserve_seconds()).compareTo(other.isSetReserve_seconds());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetReserve_seconds()) {
+      lastComparison =
+          org.apache.thrift.TBaseHelper.compareTo(this.reserve_seconds, 
other.reserve_seconds);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    return 0;
+  }
+
+  public _Fields fieldForId(int fieldId) {
+    return _Fields.findByThriftId(fieldId);
+  }
+
+  public void read(org.apache.thrift.protocol.TProtocol iprot) throws 
org.apache.thrift.TException {
+    scheme(iprot).read(iprot, this);
+  }
+
+  public void write(org.apache.thrift.protocol.TProtocol oprot)
+      throws org.apache.thrift.TException {
+    scheme(oprot).write(oprot, this);
+  }
+
+  @Override
+  public java.lang.String toString() {
+    java.lang.StringBuilder sb = new 
java.lang.StringBuilder("drop_app_options(");
+    boolean first = true;
+
+    sb.append("success_if_not_exist:");
+    sb.append(this.success_if_not_exist);
+    first = false;
+    if (isSetReserve_seconds()) {
+      if (!first) sb.append(", ");
+      sb.append("reserve_seconds:");
+      sb.append(this.reserve_seconds);
+      first = false;
+    }
+    sb.append(")");
+    return sb.toString();
+  }
+
+  public void validate() throws org.apache.thrift.TException {
+    // check for required fields
+    // check for sub-struct validity
+  }
+
+  private void writeObject(java.io.ObjectOutputStream out) throws 
java.io.IOException {
+    try {
+      write(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(out)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private void readObject(java.io.ObjectInputStream in)
+      throws java.io.IOException, java.lang.ClassNotFoundException {
+    try {
+      // it doesn't seem like you should have to do this, but java 
serialization is wacky, and
+      // doesn't call the default constructor.
+      __isset_bitfield = 0;
+      read(
+          new org.apache.thrift.protocol.TCompactProtocol(
+              new org.apache.thrift.transport.TIOStreamTransport(in)));
+    } catch (org.apache.thrift.TException te) {
+      throw new java.io.IOException(te);
+    }
+  }
+
+  private static class drop_app_optionsStandardSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public drop_app_optionsStandardScheme getScheme() {
+      return new drop_app_optionsStandardScheme();
+    }
+  }
+
+  private static class drop_app_optionsStandardScheme
+      extends org.apache.thrift.scheme.StandardScheme<drop_app_options> {
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot, 
drop_app_options struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TField schemeField;
+      iprot.readStructBegin();
+      while (true) {
+        schemeField = iprot.readFieldBegin();
+        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+          break;
+        }
+        switch (schemeField.id) {
+          case 1: // SUCCESS_IF_NOT_EXIST
+            if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+              struct.success_if_not_exist = iprot.readBool();
+              struct.setSuccess_if_not_existIsSet(true);
+            } else {
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+            }
+            break;
+          case 2: // RESERVE_SECONDS
+            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+              struct.reserve_seconds = iprot.readI64();
+              struct.setReserve_secondsIsSet(true);
+            } else {
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, 
schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked 
in the validate method
+      struct.validate();
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot, 
drop_app_options struct)
+        throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      oprot.writeFieldBegin(SUCCESS_IF_NOT_EXIST_FIELD_DESC);
+      oprot.writeBool(struct.success_if_not_exist);
+      oprot.writeFieldEnd();
+      if (struct.isSetReserve_seconds()) {
+        oprot.writeFieldBegin(RESERVE_SECONDS_FIELD_DESC);
+        oprot.writeI64(struct.reserve_seconds);
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+  }
+
+  private static class drop_app_optionsTupleSchemeFactory
+      implements org.apache.thrift.scheme.SchemeFactory {
+    public drop_app_optionsTupleScheme getScheme() {
+      return new drop_app_optionsTupleScheme();
+    }
+  }
+
+  private static class drop_app_optionsTupleScheme
+      extends org.apache.thrift.scheme.TupleScheme<drop_app_options> {
+
+    @Override
+    public void write(org.apache.thrift.protocol.TProtocol prot, 
drop_app_options struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol oprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet optionals = new java.util.BitSet();
+      if (struct.isSetSuccess_if_not_exist()) {
+        optionals.set(0);
+      }
+      if (struct.isSetReserve_seconds()) {
+        optionals.set(1);
+      }
+      oprot.writeBitSet(optionals, 2);
+      if (struct.isSetSuccess_if_not_exist()) {
+        oprot.writeBool(struct.success_if_not_exist);
+      }
+      if (struct.isSetReserve_seconds()) {
+        oprot.writeI64(struct.reserve_seconds);
+      }
+    }
+
+    @Override
+    public void read(org.apache.thrift.protocol.TProtocol prot, 
drop_app_options struct)
+        throws org.apache.thrift.TException {
+      org.apache.thrift.protocol.TTupleProtocol iprot =
+          (org.apache.thrift.protocol.TTupleProtocol) prot;
+      java.util.BitSet incoming = iprot.readBitSet(2);
+      if (incoming.get(0)) {
+        struct.success_if_not_exist = iprot.readBool();
+        struct.setSuccess_if_not_existIsSet(true);
+      }
+      if (incoming.get(1)) {
+        struct.reserve_seconds = iprot.readI64();
+        struct.setReserve_secondsIsSet(true);
+      }
+    }
+  }
+
+  private static <S extends org.apache.thrift.scheme.IScheme> S scheme(
+      org.apache.thrift.protocol.TProtocol proto) {
+    return 
(org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme())
+            ? STANDARD_SCHEME_FACTORY
+            : TUPLE_SCHEME_FACTORY)
+        .getScheme();
+  }
+}
diff --git 
a/java-client/src/main/java/org/apache/pegasus/rpc/async/MetaSession.java 
b/java-client/src/main/java/org/apache/pegasus/rpc/async/MetaSession.java
index c334c02f..d7cd2875 100644
--- a/java-client/src/main/java/org/apache/pegasus/rpc/async/MetaSession.java
+++ b/java-client/src/main/java/org/apache/pegasus/rpc/async/MetaSession.java
@@ -29,6 +29,7 @@ import org.apache.pegasus.base.error_code;
 import org.apache.pegasus.base.rpc_address;
 import org.apache.pegasus.operator.client_operator;
 import org.apache.pegasus.operator.create_app_operator;
+import org.apache.pegasus.operator.drop_app_operator;
 import org.apache.pegasus.operator.query_cfg_operator;
 import org.apache.pegasus.replication.partition_configuration;
 
@@ -79,6 +80,8 @@ public class MetaSession extends HostNameResolver {
       return ((query_cfg_operator) 
(metaQueryOp)).get_response().getErr().errno;
     } else if (metaQueryOp instanceof create_app_operator) {
       return ((create_app_operator) 
(metaQueryOp)).get_response().getErr().errno;
+    } else if (metaQueryOp instanceof drop_app_operator) {
+      return ((drop_app_operator) (metaQueryOp)).get_response().getErr().errno;
     } else {
       assert (false);
       return null;
diff --git 
a/java-client/src/test/java/org/apache/pegasus/client/TestAdminClient.java 
b/java-client/src/test/java/org/apache/pegasus/client/TestAdminClient.java
index 37533956..4b76b2b1 100644
--- a/java-client/src/test/java/org/apache/pegasus/client/TestAdminClient.java
+++ b/java-client/src/test/java/org/apache/pegasus/client/TestAdminClient.java
@@ -19,26 +19,36 @@
 
 package org.apache.pegasus.client;
 
+import static org.hamcrest.CoreMatchers.containsString;
+import static org.junit.Assert.assertThat;
+
 import java.util.HashMap;
 import org.apache.commons.lang3.reflect.FieldUtils;
 import org.apache.pegasus.rpc.async.MetaHandler;
 import org.apache.pegasus.rpc.async.MetaSession;
-import org.junit.*;
+import org.junit.After;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
 
 public class TestAdminClient {
   PegasusAdminClientInterface toolsClient;
   final String metaServerList = 
"127.0.0.1:34601,127.0.0.1:34602,127.0.0.1:34603";
+  final int tablePartitionCount = 8;
+  final int tableReplicaCount = 3;
+  final int tableOpTimeoutMs = 66000;
+  ClientOptions clientOptions;
 
   @Before
   public void Setup() throws PException {
-    ClientOptions clientOptions =
+    this.clientOptions =
         ClientOptions.builder()
             .metaServers(this.metaServerList)
             .asyncWorkers(6)
             .enablePerfCounter(false)
             .build();
 
-    toolsClient = PegasusAdminClientFactory.createClient(clientOptions);
+    toolsClient = PegasusAdminClientFactory.createClient(this.clientOptions);
   }
 
   @After
@@ -47,17 +57,19 @@ public class TestAdminClient {
   }
 
   private void testOneCreateApp(String appName) throws PException {
-    int partitionCount = 8;
-    int replicaCount = 3;
-    int opTimeoutMs = 66000;
-    toolsClient.createApp(appName, partitionCount, replicaCount, new 
HashMap<>(), opTimeoutMs);
+    toolsClient.createApp(
+        appName,
+        this.tablePartitionCount,
+        this.tableReplicaCount,
+        new HashMap<>(),
+        this.tableOpTimeoutMs);
 
-    boolean isAppHealthy = toolsClient.isAppHealthy(appName, replicaCount);
+    boolean isAppHealthy = toolsClient.isAppHealthy(appName, 
this.tableReplicaCount);
 
     Assert.assertTrue(isAppHealthy);
 
-    replicaCount = 5;
-    isAppHealthy = toolsClient.isAppHealthy(appName, replicaCount);
+    int fakeReplicaCount = 5;
+    isAppHealthy = toolsClient.isAppHealthy(appName, fakeReplicaCount);
     Assert.assertFalse(isAppHealthy);
   }
 
@@ -88,11 +100,38 @@ public class TestAdminClient {
     int replicaCount = 3;
 
     try {
-      toolsClient.isAppHealthy(appName, replicaCount);
+      toolsClient.isAppHealthy(appName, this.tableReplicaCount);
     } catch (PException e) {
       return;
     }
 
     Assert.fail();
   }
+
+  @Test
+  public void testDropApp() throws PException {
+    String appName = "testDropApp";
+
+    toolsClient.createApp(
+        appName,
+        this.tablePartitionCount,
+        this.tableReplicaCount,
+        new HashMap<>(),
+        this.tableOpTimeoutMs);
+    boolean isAppHealthy = toolsClient.isAppHealthy(appName, 
this.tableReplicaCount);
+    Assert.assertTrue(isAppHealthy);
+
+    toolsClient.dropApp(appName, tableOpTimeoutMs);
+
+    PegasusClientInterface pClient = 
PegasusClientFactory.createClient(this.clientOptions);
+    try {
+      pClient.openTable(appName);
+    } catch (PException e) {
+      assertThat(e.getMessage(), containsString("No such table"));
+      pClient.close();
+      return;
+    }
+    pClient.close();
+    Assert.fail("expected PException for openTable");
+  }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to