You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@curator.apache.org by ra...@apache.org on 2017/07/21 11:30:25 UTC

[15/16] curator git commit: Squashed commit of the following:

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/DiscoveryServiceLowLevel.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/DiscoveryServiceLowLevel.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/DiscoveryServiceLowLevel.java
deleted file mode 100644
index 42c90b9..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/DiscoveryServiceLowLevel.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.discovery;
-
-import com.facebook.swift.service.ThriftMethod;
-import com.facebook.swift.service.ThriftService;
-import com.google.common.base.Function;
-import com.google.common.collect.Collections2;
-import com.google.common.collect.Lists;
-import org.apache.curator.utils.ThreadUtils;
-import org.apache.curator.x.discovery.ServiceDiscovery;
-import org.apache.curator.x.discovery.ServiceInstance;
-import org.apache.curator.x.rpc.connections.ConnectionManager;
-import org.apache.curator.x.rpc.connections.CuratorEntry;
-import org.apache.curator.x.rpc.idl.exceptions.RpcException;
-import org.apache.curator.x.rpc.idl.structs.CuratorProjection;
-import java.util.Collection;
-
-@ThriftService
-public class DiscoveryServiceLowLevel
-{
-    private final ConnectionManager connectionManager;
-
-    public DiscoveryServiceLowLevel(ConnectionManager connectionManager)
-    {
-        this.connectionManager = connectionManager;
-    }
-
-    @ThriftMethod
-    public void registerInstance(CuratorProjection projection, DiscoveryProjection discoveryProjection, DiscoveryInstance instance) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            @SuppressWarnings("unchecked")
-            ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-            serviceDiscovery.registerService(instance.toReal());
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public void updateInstance(CuratorProjection projection, DiscoveryProjection discoveryProjection, DiscoveryInstance instance) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            @SuppressWarnings("unchecked")
-            ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-            serviceDiscovery.updateService(instance.toReal());
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public void unregisterInstance(CuratorProjection projection, DiscoveryProjection discoveryProjection, DiscoveryInstance instance) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            @SuppressWarnings("unchecked")
-            ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-            serviceDiscovery.unregisterService(instance.toReal());
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public Collection<String> queryForNames(CuratorProjection projection, DiscoveryProjection discoveryProjection) throws RpcException
-    {
-        CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-        @SuppressWarnings("unchecked")
-        ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-        try
-        {
-            return serviceDiscovery.queryForNames();
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public DiscoveryInstance queryForInstance(CuratorProjection projection, DiscoveryProjection discoveryProjection, String name, String id) throws RpcException
-    {
-        CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-        @SuppressWarnings("unchecked")
-        ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-        try
-        {
-            return new DiscoveryInstance(serviceDiscovery.queryForInstance(name, id));
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public Collection<DiscoveryInstance> queryForInstances(CuratorProjection projection, DiscoveryProjection discoveryProjection, String name) throws RpcException
-    {
-        CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-        @SuppressWarnings("unchecked")
-        ServiceDiscovery<byte[]> serviceDiscovery = CuratorEntry.mustGetThing(entry, discoveryProjection.id, ServiceDiscovery.class);
-        try
-        {
-            Collection<ServiceInstance<byte[]>> instances = serviceDiscovery.queryForInstances(name);
-            Collection<DiscoveryInstance> transformed = Collections2.transform
-            (
-                instances,
-                new Function<ServiceInstance<byte[]>, DiscoveryInstance>()
-                {
-                    @Override
-                    public DiscoveryInstance apply(ServiceInstance<byte[]> instance)
-                    {
-                        return new DiscoveryInstance(instance);
-                    }
-                }
-            );
-            return Lists.newArrayList(transformed);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/ProviderStrategyType.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/ProviderStrategyType.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/ProviderStrategyType.java
deleted file mode 100644
index 139e0be..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/discovery/ProviderStrategyType.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.discovery;
-
-public enum ProviderStrategyType
-{
-    RANDOM,
-    STICKY_RANDOM,
-    STICKY_ROUND_ROBIN,
-    ROUND_ROBIN
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ExceptionType.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ExceptionType.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ExceptionType.java
deleted file mode 100644
index adf1206..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ExceptionType.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.exceptions;
-
-public enum ExceptionType
-{
-    GENERAL,
-    ZOOKEEPER,
-    NODE
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/NodeExceptionType.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/NodeExceptionType.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/NodeExceptionType.java
deleted file mode 100644
index f62756e..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/NodeExceptionType.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.exceptions;
-
-public enum NodeExceptionType
-{
-    NONODE,
-    BADVERSION,
-    NODEEXISTS,
-    NOTEMPTY
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/RpcException.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/RpcException.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/RpcException.java
deleted file mode 100644
index 9032c1c..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/RpcException.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.exceptions;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-import com.facebook.swift.service.ThriftException;
-import org.apache.zookeeper.KeeperException;
-import java.io.PrintWriter;
-import java.io.StringWriter;
-
-@ThriftException(id = 1, type = RpcException.class, name = "CuratorException")
-@ThriftStruct("CuratorException")
-public class RpcException extends Exception
-{
-    @ThriftField(1)
-    public ExceptionType type;
-
-    @ThriftField(2)
-    public ZooKeeperExceptionType zooKeeperException;
-
-    @ThriftField(3)
-    public NodeExceptionType nodeException;
-
-    @ThriftField(4)
-    public String message;
-
-    public RpcException()
-    {
-    }
-
-    public RpcException(Exception e)
-    {
-        this.message = e.getLocalizedMessage();
-        if ( this.message == null )
-        {
-            StringWriter str = new StringWriter();
-            e.printStackTrace(new PrintWriter(str));
-            this.message = str.toString();
-        }
-
-        if ( KeeperException.class.isAssignableFrom(e.getClass()) )
-        {
-            KeeperException keeperException = (KeeperException)e;
-            switch ( keeperException.code() )
-            {
-                default:
-                {
-                    type = ExceptionType.ZOOKEEPER;
-                    zooKeeperException = ZooKeeperExceptionType.valueOf(keeperException.code().name());
-                    nodeException = null;
-                    break;
-                }
-
-                case NONODE:
-                case NODEEXISTS:
-                case NOTEMPTY:
-                case BADVERSION:
-                {
-                    type = ExceptionType.NODE;
-                    zooKeeperException = null;
-                    nodeException = NodeExceptionType.valueOf(keeperException.code().name());
-                    break;
-                }
-            }
-        }
-        else
-        {
-            type = ExceptionType.GENERAL;
-        }
-    }
-
-    public RpcException(ExceptionType type, ZooKeeperExceptionType zooKeeperException, NodeExceptionType nodeException, String message)
-    {
-        this.type = type;
-        this.zooKeeperException = zooKeeperException;
-        this.nodeException = nodeException;
-        this.message = message;
-    }
-
-
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ZooKeeperExceptionType.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ZooKeeperExceptionType.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ZooKeeperExceptionType.java
deleted file mode 100644
index 0ce0c1f..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/exceptions/ZooKeeperExceptionType.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.exceptions;
-
-public enum ZooKeeperExceptionType
-{
-    SYSTEMERROR,
-    RUNTIMEINCONSISTENCY,
-    DATAINCONSISTENCY,
-    CONNECTIONLOSS,
-    MARSHALLINGERROR,
-    UNIMPLEMENTED,
-    OPERATIONTIMEOUT,
-    BADARGUMENTS,
-    APIERROR,
-    NOAUTH,
-    NOCHILDRENFOREPHEMERALS,
-    INVALIDACL,
-    AUTHFAILED,
-    SESSIONEXPIRED,
-    INVALIDCALLBACK,
-    SESSIONMOVED,
-    NOTREADONLY
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/CuratorProjectionService.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/CuratorProjectionService.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/CuratorProjectionService.java
deleted file mode 100644
index 794b467..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/CuratorProjectionService.java
+++ /dev/null
@@ -1,765 +0,0 @@
-
-/**
- * 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.curator.x.rpc.idl.services;
-
-import com.facebook.swift.service.ThriftMethod;
-import com.facebook.swift.service.ThriftService;
-import com.google.common.base.Function;
-import com.google.common.collect.Collections2;
-import com.google.common.collect.Lists;
-import org.apache.curator.framework.CuratorFramework;
-import org.apache.curator.framework.api.*;
-import org.apache.curator.framework.recipes.cache.ChildData;
-import org.apache.curator.framework.recipes.cache.NodeCache;
-import org.apache.curator.framework.recipes.cache.NodeCacheListener;
-import org.apache.curator.framework.recipes.cache.PathChildrenCache;
-import org.apache.curator.framework.recipes.cache.PathChildrenCacheEvent;
-import org.apache.curator.framework.recipes.cache.PathChildrenCacheListener;
-import org.apache.curator.framework.recipes.leader.LeaderLatch;
-import org.apache.curator.framework.recipes.leader.LeaderLatchListener;
-import org.apache.curator.framework.recipes.leader.Participant;
-import org.apache.curator.framework.recipes.locks.InterProcessSemaphoreMutex;
-import org.apache.curator.framework.recipes.locks.InterProcessSemaphoreV2;
-import org.apache.curator.framework.recipes.locks.Lease;
-import org.apache.curator.framework.recipes.nodes.PersistentEphemeralNode;
-import org.apache.curator.framework.state.ConnectionState;
-import org.apache.curator.framework.state.ConnectionStateListener;
-import org.apache.curator.utils.ThreadUtils;
-import org.apache.curator.x.rpc.connections.Closer;
-import org.apache.curator.x.rpc.connections.ConnectionManager;
-import org.apache.curator.x.rpc.connections.CuratorEntry;
-import org.apache.curator.x.rpc.details.RpcBackgroundCallback;
-import org.apache.curator.x.rpc.details.RpcWatcher;
-import org.apache.curator.x.rpc.idl.exceptions.ExceptionType;
-import org.apache.curator.x.rpc.idl.exceptions.RpcException;
-import org.apache.curator.x.rpc.idl.structs.*;
-import org.apache.zookeeper.CreateMode;
-import org.apache.zookeeper.data.Stat;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import java.io.IOException;
-import java.util.Collection;
-import java.util.List;
-import java.util.concurrent.TimeUnit;
-
-@ThriftService("CuratorService")
-public class CuratorProjectionService
-{
-    private final Logger log = LoggerFactory.getLogger(getClass());
-    private final ConnectionManager connectionManager;
-
-    public CuratorProjectionService(ConnectionManager connectionManager)
-    {
-        this.connectionManager = connectionManager;
-    }
-
-    @ThriftMethod
-    public CuratorProjection newCuratorProjection(String connectionName) throws RpcException
-    {
-        CuratorFramework client = connectionManager.newConnection(connectionName);
-        if ( client == null )
-        {
-            throw new RpcException(ExceptionType.GENERAL, null, null, "No connection configuration was found with the name: " + connectionName);
-        }
-
-        String id = CuratorEntry.newId();
-        client.start();
-        connectionManager.add(id, client);
-        final CuratorProjection projection = new CuratorProjection(id);
-
-        ConnectionStateListener listener = new ConnectionStateListener()
-        {
-            @Override
-            public void stateChanged(CuratorFramework client, ConnectionState newState)
-            {
-                addEvent(projection, new RpcCuratorEvent(newState));
-            }
-        };
-        client.getConnectionStateListenable().addListener(listener);
-
-        return projection;
-    }
-
-    @ThriftMethod
-    public void closeCuratorProjection(CuratorProjection projection)
-    {
-        CuratorEntry entry = connectionManager.remove(projection.id);
-        if ( entry != null )
-        {
-            entry.close();
-        }
-    }
-
-    @ThriftMethod(oneway = true)
-    public void pingCuratorProjection(CuratorProjection projection)
-    {
-        connectionManager.get(projection.id);
-    }
-
-    @ThriftMethod
-    public OptionalPath createNode(CuratorProjection projection, CreateSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.create();
-            if ( spec.creatingParentsIfNeeded )
-            {
-                builder = castBuilder(builder, CreateBuilder.class).creatingParentsIfNeeded();
-            }
-            if ( spec.creatingParentContainersIfNeeded )
-            {
-                builder = castBuilder(builder, CreateBuilder.class).creatingParentContainersIfNeeded();
-            }
-            if ( spec.compressed )
-            {
-                builder = castBuilder(builder, Compressible.class).compressed();
-            }
-            if ( spec.withProtection )
-            {
-                builder = castBuilder(builder, CreateBuilder.class).withProtection();
-            }
-            if ( spec.mode != null )
-            {
-                builder = castBuilder(builder, CreateModable.class).withMode(CreateMode.valueOf(spec.mode.name()));
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                builder = castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback, spec.asyncContext);
-            }
-
-            Object path = castBuilder(builder, PathAndBytesable.class).forPath(spec.path, spec.data);
-            return new OptionalPath((path != null) ? String.valueOf(path) : null);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public void deleteNode(CuratorProjection projection, DeleteSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.delete();
-            if ( spec.guaranteed )
-            {
-                builder = castBuilder(builder, DeleteBuilder.class).guaranteed();
-            }
-            if ( spec.version != null )
-            {
-                builder = castBuilder(builder, Versionable.class).withVersion(spec.version.version);
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                builder = castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback, spec.asyncContext);
-            }
-
-            castBuilder(builder, Pathable.class).forPath(spec.path);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public OptionalData getData(CuratorProjection projection, GetDataSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.getData();
-            if ( spec.watched )
-            {
-                builder = castBuilder(builder, Watchable.class).usingWatcher(new RpcWatcher(this, projection));
-            }
-
-            if ( spec.decompressed )
-            {
-                builder = castBuilder(builder, Decompressible.class).decompressed();
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                builder = castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback);
-            }
-
-            Stat stat = new Stat();
-            builder = castBuilder(builder, Statable.class).storingStatIn(stat);
-
-            byte[] bytes = (byte[])castBuilder(builder, Pathable.class).forPath(spec.path);
-            return new OptionalData(bytes);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public OptionalRpcStat setData(CuratorProjection projection, SetDataSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.setData();
-            if ( spec.watched )
-            {
-                builder = castBuilder(builder, Watchable.class).usingWatcher(new RpcWatcher(this, projection));
-            }
-            if ( spec.version != null )
-            {
-                builder = castBuilder(builder, Versionable.class).withVersion(spec.version.version);
-            }
-
-            if ( spec.compressed )
-            {
-                builder = castBuilder(builder, Compressible.class).compressed();
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                builder = castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback);
-            }
-
-            Stat stat = (Stat)castBuilder(builder, PathAndBytesable.class).forPath(spec.path, spec.data);
-            return new OptionalRpcStat(RpcCuratorEvent.toRpcStat(stat));
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public OptionalRpcStat exists(CuratorProjection projection, ExistsSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.checkExists();
-            if ( spec.watched )
-            {
-                builder = castBuilder(builder, Watchable.class).usingWatcher(new RpcWatcher(this, projection));
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback);
-            }
-
-            Stat stat = (Stat)castBuilder(builder, Pathable.class).forPath(spec.path);
-            return new OptionalRpcStat((stat != null) ? RpcCuratorEvent.toRpcStat(stat) : null);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public OptionalChildrenList getChildren(CuratorProjection projection, GetChildrenSpec spec) throws RpcException
-    {
-        try
-        {
-            CuratorFramework client = CuratorEntry.mustGetEntry(connectionManager, projection).getClient();
-
-            Object builder = client.getChildren();
-            if ( spec.watched )
-            {
-                builder = castBuilder(builder, Watchable.class).usingWatcher(new RpcWatcher(this, projection));
-            }
-
-            if ( spec.asyncContext != null )
-            {
-                BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-                builder = castBuilder(builder, Backgroundable.class).inBackground(backgroundCallback);
-            }
-
-            @SuppressWarnings("unchecked")
-            List<String> children = (List<String>)castBuilder(builder, Pathable.class).forPath(spec.path);
-            return new OptionalChildrenList(children);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public void sync(CuratorProjection projection, String path, String asyncContext) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            BackgroundCallback backgroundCallback = new RpcBackgroundCallback(this, projection);
-            entry.getClient().sync().inBackground(backgroundCallback, asyncContext).forPath(path);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public boolean closeGenericProjection(CuratorProjection projection, String id) throws RpcException
-    {
-        try
-        {
-            if ( id.equals(projection.id) )
-            {
-                closeCuratorProjection(projection);
-                return true;
-            }
-            else
-            {
-                CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-                return entry.closeThing(id);
-            }
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public OptionalLockProjection acquireLock(CuratorProjection projection, final String path, int maxWaitMs) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            final InterProcessSemaphoreMutex lock = new InterProcessSemaphoreMutex(entry.getClient(), path);
-            if ( !lock.acquire(maxWaitMs, TimeUnit.MILLISECONDS) )
-            {
-                return new OptionalLockProjection();
-            }
-
-            Closer closer = new Closer()
-            {
-                @Override
-                public void close()
-                {
-                    if ( lock.isAcquiredInThisProcess() )
-                    {
-                        try
-                        {
-                            lock.release();
-                        }
-                        catch ( Exception e )
-                        {
-                            ThreadUtils.checkInterrupted(e);
-                            log.error("Could not release left-over lock for path: " + path, e);
-                        }
-                    }
-                }
-            };
-            String id = entry.addThing(lock, closer);
-            return new OptionalLockProjection(new LockProjection(id));
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public LeaderResult startLeaderSelector(final CuratorProjection projection, final String path, final String participantId, int waitForLeadershipMs) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            final LeaderLatch leaderLatch = new LeaderLatch(entry.getClient(), path, participantId);
-            leaderLatch.start();
-
-            Closer closer = new Closer()
-            {
-                @Override
-                public void close()
-                {
-                    try
-                    {
-                        leaderLatch.close();
-                    }
-                    catch ( IOException e )
-                    {
-                        ThreadUtils.checkInterrupted(e);
-                        log.error("Could not close left-over leader latch for path: " + path, e);
-                    }
-                }
-            };
-            String id = entry.addThing(leaderLatch, closer);
-
-            LeaderLatchListener listener = new LeaderLatchListener()
-            {
-                @Override
-                public void isLeader()
-                {
-                    addEvent(projection, new RpcCuratorEvent(new LeaderEvent(path, participantId, true)));
-                }
-
-                @Override
-                public void notLeader()
-                {
-                    addEvent(projection, new RpcCuratorEvent(new LeaderEvent(path, participantId, false)));
-                }
-            };
-            leaderLatch.addListener(listener);
-
-            if ( waitForLeadershipMs > 0 )
-            {
-                leaderLatch.await(waitForLeadershipMs, TimeUnit.MILLISECONDS);
-            }
-
-            return new LeaderResult(new LeaderProjection(id), leaderLatch.hasLeadership());
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public Collection<RpcParticipant> getLeaderParticipants(CuratorProjection projection, LeaderProjection leaderProjection) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            LeaderLatch leaderLatch = CuratorEntry.mustGetThing(entry, leaderProjection.id, LeaderLatch.class);
-            Collection<Participant> participants = leaderLatch.getParticipants();
-            Collection<RpcParticipant> transformed = Collections2.transform
-            (
-                participants,
-                new Function<Participant, RpcParticipant>()
-                {
-                    @Override
-                    public RpcParticipant apply(Participant participant)
-                    {
-                        return new RpcParticipant(participant.getId(), participant.isLeader());
-                    }
-                }
-            );
-            return Lists.newArrayList(transformed);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public boolean isLeader(CuratorProjection projection, LeaderProjection leaderProjection) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            LeaderLatch leaderLatch = CuratorEntry.mustGetThing(entry, leaderProjection.id, LeaderLatch.class);
-            return leaderLatch.hasLeadership();
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public PathChildrenCacheProjection startPathChildrenCache(final CuratorProjection projection, final String path, boolean cacheData, boolean dataIsCompressed, PathChildrenCacheStartMode startMode) throws RpcException
-    {
-        try
-        {
-            final CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            final PathChildrenCache cache = new PathChildrenCache(entry.getClient(), path, cacheData, dataIsCompressed, ThreadUtils.newThreadFactory("PathChildrenCacheResource"));
-            cache.start(PathChildrenCache.StartMode.valueOf(startMode.name()));
-
-            Closer closer = new Closer()
-            {
-                @Override
-                public void close()
-                {
-                    try
-                    {
-                        cache.close();
-                    }
-                    catch ( IOException e )
-                    {
-                        ThreadUtils.checkInterrupted(e);
-                        log.error("Could not close left-over PathChildrenCache for path: " + path, e);
-                    }
-                }
-            };
-            String id = entry.addThing(cache, closer);
-
-            PathChildrenCacheListener listener = new PathChildrenCacheListener()
-            {
-                @Override
-                public void childEvent(CuratorFramework client, PathChildrenCacheEvent event) throws RpcException
-                {
-                    entry.addEvent(new RpcCuratorEvent(new RpcPathChildrenCacheEvent(path, event)));
-                }
-            };
-            cache.getListenable().addListener(listener);
-
-            return new PathChildrenCacheProjection(id);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public List<RpcChildData> getPathChildrenCacheData(CuratorProjection projection, PathChildrenCacheProjection cacheProjection) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            PathChildrenCache pathChildrenCache = CuratorEntry.mustGetThing(entry, cacheProjection.id, PathChildrenCache.class);
-            return Lists.transform
-            (
-                pathChildrenCache.getCurrentData(),
-                new Function<ChildData, RpcChildData>()
-                {
-                    @Override
-                    public RpcChildData apply(ChildData childData)
-                    {
-                        return new RpcChildData(childData);
-                    }
-                }
-            );
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public RpcChildData getPathChildrenCacheDataForPath(CuratorProjection projection, PathChildrenCacheProjection cacheProjection, String path) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            PathChildrenCache pathChildrenCache = CuratorEntry.mustGetThing(entry, cacheProjection.id, PathChildrenCache.class);
-            return new RpcChildData(pathChildrenCache.getCurrentData(path));
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public NodeCacheProjection startNodeCache(CuratorProjection projection, final String path, boolean dataIsCompressed, boolean buildInitial) throws RpcException
-    {
-        try
-        {
-            final CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            final NodeCache cache = new NodeCache(entry.getClient(), path, dataIsCompressed);
-            cache.start(buildInitial);
-
-            Closer closer = new Closer()
-            {
-                @Override
-                public void close()
-                {
-                    try
-                    {
-                        cache.close();
-                    }
-                    catch ( IOException e )
-                    {
-                        ThreadUtils.checkInterrupted(e);
-                        log.error("Could not close left-over NodeCache for path: " + path, e);
-                    }
-                }
-            };
-            String id = entry.addThing(cache, closer);
-
-            NodeCacheListener listener = new NodeCacheListener()
-            {
-                @Override
-                public void nodeChanged()
-                {
-                    entry.addEvent(new RpcCuratorEvent(RpcCuratorEventType.NODE_CACHE, path));
-                }
-            };
-            cache.getListenable().addListener(listener);
-
-            return new NodeCacheProjection(id);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public RpcChildData getNodeCacheData(CuratorProjection projection, NodeCacheProjection cacheProjection) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            NodeCache nodeCache = CuratorEntry.mustGetThing(entry, cacheProjection.id, NodeCache.class);
-            return new RpcChildData(nodeCache.getCurrentData());
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public PersistentEphemeralNodeProjection startPersistentEphemeralNode(CuratorProjection projection, final String path, byte[] data, RpcPersistentEphemeralNodeMode mode) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            final PersistentEphemeralNode node = new PersistentEphemeralNode(entry.getClient(), PersistentEphemeralNode.Mode.valueOf(mode.name()), path, data);
-            node.start();
-
-            Closer closer = new Closer()
-            {
-                @Override
-                public void close()
-                {
-                    try
-                    {
-                        node.close();
-                    }
-                    catch ( Exception e )
-                    {
-                        ThreadUtils.checkInterrupted(e);
-                        log.error("Could not release left-over persistent ephemeral node for path: " + path, e);
-                    }
-                }
-            };
-            String id = entry.addThing(node, closer);
-            return new PersistentEphemeralNodeProjection(id);
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    @ThriftMethod
-    public List<LeaseProjection> acquireSemaphore(CuratorProjection projection, final String path, int acquireQty, int maxWaitMs, int maxLeases) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-
-            final InterProcessSemaphoreV2 semaphore = new InterProcessSemaphoreV2(entry.getClient(), path, maxLeases);
-            final Collection<Lease> leases = semaphore.acquire(acquireQty, maxWaitMs, TimeUnit.MILLISECONDS);
-            if ( leases == null )
-            {
-                return Lists.newArrayList();
-            }
-
-            List<LeaseProjection> leaseProjections = Lists.newArrayList();
-            for ( final Lease lease : leases )
-            {
-                Closer closer = new Closer()
-                {
-                    @Override
-                    public void close()
-                    {
-                        try
-                        {
-                            semaphore.returnLease(lease);
-                        }
-                        catch ( Exception e )
-                        {
-                            ThreadUtils.checkInterrupted(e);
-                            log.error("Could not release semaphore leases for path: " + path, e);
-                        }
-                    }
-                };
-                leaseProjections.add(new LeaseProjection(entry.addThing(lease, closer)));
-            }
-            return leaseProjections;
-        }
-        catch ( Exception e )
-        {
-            ThreadUtils.checkInterrupted(e);
-            throw new RpcException(e);
-        }
-    }
-
-    public void addEvent(CuratorProjection projection, RpcCuratorEvent event)
-    {
-        CuratorEntry entry = connectionManager.get(projection.id);
-        if ( entry != null )
-        {
-            entry.addEvent(event);
-        }
-    }
-
-    private static <T> T castBuilder(Object createBuilder, Class<T> clazz) throws Exception
-    {
-        if ( clazz.isAssignableFrom(createBuilder.getClass()) )
-        {
-            return clazz.cast(createBuilder);
-        }
-        throw new Exception("That operation is not available");
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/EventService.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/EventService.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/EventService.java
deleted file mode 100644
index 74fb320..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/services/EventService.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.services;
-
-import com.facebook.swift.service.ThriftMethod;
-import com.facebook.swift.service.ThriftService;
-import org.apache.curator.x.rpc.connections.CuratorEntry;
-import org.apache.curator.x.rpc.connections.ConnectionManager;
-import org.apache.curator.x.rpc.idl.exceptions.RpcException;
-import org.apache.curator.x.rpc.idl.structs.CuratorProjection;
-import org.apache.curator.x.rpc.idl.structs.RpcCuratorEvent;
-
-@ThriftService("EventService")
-public class EventService
-{
-    private final ConnectionManager connectionManager;
-    private final long pingTimeMs;
-
-    public EventService(ConnectionManager connectionManager, long pingTimeMs)
-    {
-        this.connectionManager = connectionManager;
-        this.pingTimeMs = pingTimeMs;
-    }
-
-    @ThriftMethod
-    public RpcCuratorEvent getNextEvent(CuratorProjection projection) throws RpcException
-    {
-        try
-        {
-            CuratorEntry entry = CuratorEntry.mustGetEntry(connectionManager, projection);
-            RpcCuratorEvent event = entry.pollForEvent(pingTimeMs);
-            return (event != null) ? event : new RpcCuratorEvent();
-        }
-        catch ( InterruptedException e )
-        {
-            throw new RpcException(e);
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CreateSpec.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CreateSpec.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CreateSpec.java
deleted file mode 100644
index a15fe92..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CreateSpec.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class CreateSpec
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public byte[] data;
-
-    @ThriftField(3)
-    public RpcCreateMode mode;
-
-    @ThriftField(4)
-    public String asyncContext;
-
-    @ThriftField(5)
-    public boolean compressed;
-
-    @ThriftField(6)
-    public boolean creatingParentsIfNeeded;
-
-    @ThriftField(7)
-    public boolean withProtection;
-
-    @ThriftField(8)
-    public boolean creatingParentContainersIfNeeded;
-
-    public CreateSpec()
-    {
-    }
-
-    public CreateSpec(String path, byte[] data, RpcCreateMode mode, String asyncContext, boolean compressed, boolean creatingParentsIfNeeded, boolean withProtection, boolean creatingParentContainersIfNeeded)
-    {
-        this.path = path;
-        this.data = data;
-        this.mode = mode;
-        this.asyncContext = asyncContext;
-        this.compressed = compressed;
-        this.creatingParentsIfNeeded = creatingParentsIfNeeded;
-        this.withProtection = withProtection;
-        this.creatingParentContainersIfNeeded = creatingParentContainersIfNeeded;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CuratorProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CuratorProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CuratorProjection.java
deleted file mode 100644
index 82ea2a3..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/CuratorProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class CuratorProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public CuratorProjection()
-    {
-    }
-
-    public CuratorProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/DeleteSpec.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/DeleteSpec.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/DeleteSpec.java
deleted file mode 100644
index 18f8dd2..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/DeleteSpec.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class DeleteSpec
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public boolean guaranteed;
-
-    @ThriftField(3)
-    public String asyncContext;
-
-    @ThriftField(4)
-    public Version version;
-
-    public DeleteSpec()
-    {
-    }
-
-    public DeleteSpec(String path, boolean guaranteed, String asyncContext, Version version)
-    {
-        this.path = path;
-        this.guaranteed = guaranteed;
-        this.asyncContext = asyncContext;
-        this.version = version;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/ExistsSpec.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/ExistsSpec.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/ExistsSpec.java
deleted file mode 100644
index f271f7e..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/ExistsSpec.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class ExistsSpec
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public boolean watched;
-
-    @ThriftField(3)
-    public String asyncContext;
-
-    public ExistsSpec()
-    {
-    }
-
-    public ExistsSpec(String path, boolean watched, String asyncContext)
-    {
-        this.path = path;
-        this.watched = watched;
-        this.asyncContext = asyncContext;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetChildrenSpec.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetChildrenSpec.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetChildrenSpec.java
deleted file mode 100644
index 37dea04..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetChildrenSpec.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class GetChildrenSpec
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public boolean watched;
-
-    @ThriftField(3)
-    public String asyncContext;
-
-    public GetChildrenSpec()
-    {
-    }
-
-    public GetChildrenSpec(String path, boolean watched, String asyncContext)
-    {
-        this.path = path;
-        this.watched = watched;
-        this.asyncContext = asyncContext;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetDataSpec.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetDataSpec.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetDataSpec.java
deleted file mode 100644
index 9b741d0..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/GetDataSpec.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class GetDataSpec
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public boolean watched;
-
-    @ThriftField(3)
-    public String asyncContext;
-
-    @ThriftField(4)
-    public boolean decompressed;
-
-    public GetDataSpec()
-    {
-    }
-
-    public GetDataSpec(String path, boolean watched, String asyncContext, boolean decompressed)
-    {
-        this.path = path;
-        this.watched = watched;
-        this.asyncContext = asyncContext;
-        this.decompressed = decompressed;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderEvent.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderEvent.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderEvent.java
deleted file mode 100644
index ebeabab..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderEvent.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class LeaderEvent
-{
-    @ThriftField(1)
-    public String path;
-
-    @ThriftField(2)
-    public String participantId;
-
-    @ThriftField(3)
-    public boolean isLeader;
-
-    public LeaderEvent()
-    {
-    }
-
-    public LeaderEvent(String path, String participantId, boolean isLeader)
-    {
-        this.path = path;
-        this.participantId = participantId;
-        this.isLeader = isLeader;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderProjection.java
deleted file mode 100644
index d9b3fac..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class LeaderProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public LeaderProjection()
-    {
-    }
-
-    public LeaderProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderResult.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderResult.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderResult.java
deleted file mode 100644
index 429294b..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaderResult.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class LeaderResult
-{
-    @ThriftField(1)
-    public LeaderProjection projection;
-
-    @ThriftField(2)
-    public boolean isLeader;
-
-    public LeaderResult()
-    {
-    }
-
-    public LeaderResult(LeaderProjection projection, boolean isLeader)
-    {
-        this.projection = projection;
-        this.isLeader = isLeader;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaseProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaseProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaseProjection.java
deleted file mode 100644
index 1ab1f18..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LeaseProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class LeaseProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public LeaseProjection()
-    {
-    }
-
-    public LeaseProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LockProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LockProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LockProjection.java
deleted file mode 100644
index 1f88d5e..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/LockProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class LockProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public LockProjection()
-    {
-    }
-
-    public LockProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/NodeCacheProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/NodeCacheProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/NodeCacheProjection.java
deleted file mode 100644
index 3cf3be0..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/NodeCacheProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class NodeCacheProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public NodeCacheProjection()
-    {
-    }
-
-    public NodeCacheProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalChildrenList.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalChildrenList.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalChildrenList.java
deleted file mode 100644
index 44a96f2..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalChildrenList.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-import java.util.List;
-
-@ThriftStruct
-public class OptionalChildrenList
-{
-    @ThriftField(1)
-    public List<String> children;
-
-    public OptionalChildrenList()
-    {
-    }
-
-    public OptionalChildrenList(List<String> children)
-    {
-        this.children = children;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalData.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalData.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalData.java
deleted file mode 100644
index e46c577..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalData.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class OptionalData
-{
-    @ThriftField(1)
-    public byte[] data;
-
-    public OptionalData()
-    {
-    }
-
-    public OptionalData(byte[] data)
-    {
-        this.data = data;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalLockProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalLockProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalLockProjection.java
deleted file mode 100644
index cd85494..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalLockProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class OptionalLockProjection
-{
-    @ThriftField(1)
-    public LockProjection lockProjection;
-
-    public OptionalLockProjection()
-    {
-    }
-
-    public OptionalLockProjection(LockProjection lockProjection)
-    {
-        this.lockProjection = lockProjection;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalPath.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalPath.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalPath.java
deleted file mode 100644
index f2d5f16..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalPath.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class OptionalPath
-{
-    @ThriftField(1)
-    public String path;
-
-    public OptionalPath()
-    {
-    }
-
-    public OptionalPath(String path)
-    {
-        this.path = path;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalRpcStat.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalRpcStat.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalRpcStat.java
deleted file mode 100644
index df0c234..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/OptionalRpcStat.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct("OptionalStat")
-public class OptionalRpcStat
-{
-    @ThriftField(1)
-    public RpcStat stat;
-
-    public OptionalRpcStat()
-    {
-    }
-
-    public OptionalRpcStat(RpcStat stat)
-    {
-        this.stat = stat;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheProjection.java
deleted file mode 100644
index 9dd4f02..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class PathChildrenCacheProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public PathChildrenCacheProjection()
-    {
-    }
-
-    public PathChildrenCacheProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheStartMode.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheStartMode.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheStartMode.java
deleted file mode 100644
index 4989183..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PathChildrenCacheStartMode.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-public enum PathChildrenCacheStartMode
-{
-    NORMAL,
-    BUILD_INITIAL_CACHE,
-    POST_INITIALIZED_EVENT
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PersistentEphemeralNodeProjection.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PersistentEphemeralNodeProjection.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PersistentEphemeralNodeProjection.java
deleted file mode 100644
index 40fefff..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/PersistentEphemeralNodeProjection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct
-public class PersistentEphemeralNodeProjection
-{
-    @ThriftField(1)
-    public String id;
-
-    public PersistentEphemeralNodeProjection()
-    {
-    }
-
-    public PersistentEphemeralNodeProjection(String id)
-    {
-        this.id = id;
-    }
-}

http://git-wip-us.apache.org/repos/asf/curator/blob/95b70d2b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/RpcAcl.java
----------------------------------------------------------------------
diff --git a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/RpcAcl.java b/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/RpcAcl.java
deleted file mode 100644
index c4cb9ac..0000000
--- a/curator-x-rpc/src/main/java/org/apache/curator/x/rpc/idl/structs/RpcAcl.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/**
- * 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.curator.x.rpc.idl.structs;
-
-import com.facebook.swift.codec.ThriftField;
-import com.facebook.swift.codec.ThriftStruct;
-
-@ThriftStruct("Acl")
-public class RpcAcl
-{
-    @ThriftField(1)
-    public int perms;
-
-    @ThriftField(2)
-    public RpcId id;
-
-    public RpcAcl()
-    {
-    }
-
-    public RpcAcl(int perms, RpcId id)
-    {
-        this.perms = perms;
-        this.id = id;
-    }
-}