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/02/09 18:36:26 UTC
[27/47] curator git commit: refactoring
refactoring
Project: http://git-wip-us.apache.org/repos/asf/curator/repo
Commit: http://git-wip-us.apache.org/repos/asf/curator/commit/476d55fe
Tree: http://git-wip-us.apache.org/repos/asf/curator/tree/476d55fe
Diff: http://git-wip-us.apache.org/repos/asf/curator/diff/476d55fe
Branch: refs/heads/CURATOR-3.0
Commit: 476d55fe210621d3647355a08c0fb7a926d88a21
Parents: 1ebe821
Author: randgalt <ra...@apache.org>
Authored: Fri Jan 6 15:57:06 2017 -0500
Committer: randgalt <ra...@apache.org>
Committed: Fri Jan 6 15:57:06 2017 -0500
----------------------------------------------------------------------
.../curator/x/async/AsyncCreateBuilder.java | 114 -----------------
.../curator/x/async/AsyncCuratorFramework.java | 2 +
.../x/async/AsyncCuratorFrameworkDsl.java | 99 ---------------
.../curator/x/async/AsyncDeleteBuilder.java | 54 --------
.../curator/x/async/AsyncEnsemblable.java | 32 -----
.../curator/x/async/AsyncExistsBuilder.java | 36 ------
.../curator/x/async/AsyncGetACLBuilder.java | 37 ------
.../x/async/AsyncGetChildrenBuilder.java | 36 ------
.../curator/x/async/AsyncGetConfigBuilder.java | 35 ------
.../curator/x/async/AsyncGetDataBuilder.java | 52 --------
.../curator/x/async/AsyncMultiTransaction.java | 38 ------
.../curator/x/async/AsyncPathAndBytesable.java | 36 ------
.../apache/curator/x/async/AsyncPathable.java | 34 -----
.../curator/x/async/AsyncReconfigBuilder.java | 117 -----------------
.../x/async/AsyncRemoveWatchesBuilder.java | 125 ------------------
.../curator/x/async/AsyncSetACLBuilder.java | 48 -------
.../curator/x/async/AsyncSetDataBuilder.java | 53 --------
.../org/apache/curator/x/async/AsyncStage.java | 2 +-
.../curator/x/async/AsyncSyncBuilder.java | 27 ----
.../x/async/AsyncTransactionCheckBuilder.java | 35 ------
.../x/async/AsyncTransactionCreateBuilder.java | 66 ----------
.../x/async/AsyncTransactionDeleteBuilder.java | 35 ------
.../curator/x/async/AsyncTransactionOp.java | 54 --------
.../x/async/AsyncTransactionSetDataBuilder.java | 51 --------
.../apache/curator/x/async/CreateOption.java | 76 -----------
.../apache/curator/x/async/DeleteOption.java | 44 -------
.../apache/curator/x/async/ExistsOption.java | 35 ------
.../curator/x/async/RemoveWatcherOption.java | 45 -------
.../x/async/WatchedAsyncCuratorFramework.java | 54 --------
.../curator/x/async/api/AsyncCreateBuilder.java | 115 +++++++++++++++++
.../x/async/api/AsyncCuratorFrameworkDsl.java | 99 +++++++++++++++
.../curator/x/async/api/AsyncDeleteBuilder.java | 55 ++++++++
.../curator/x/async/api/AsyncEnsemblable.java | 32 +++++
.../curator/x/async/api/AsyncExistsBuilder.java | 37 ++++++
.../curator/x/async/api/AsyncGetACLBuilder.java | 38 ++++++
.../x/async/api/AsyncGetChildrenBuilder.java | 37 ++++++
.../x/async/api/AsyncGetConfigBuilder.java | 36 ++++++
.../x/async/api/AsyncGetDataBuilder.java | 53 ++++++++
.../x/async/api/AsyncMultiTransaction.java | 39 ++++++
.../x/async/api/AsyncPathAndBytesable.java | 36 ++++++
.../curator/x/async/api/AsyncPathable.java | 34 +++++
.../x/async/api/AsyncReconfigBuilder.java | 118 +++++++++++++++++
.../x/async/api/AsyncRemoveWatchesBuilder.java | 126 +++++++++++++++++++
.../curator/x/async/api/AsyncSetACLBuilder.java | 49 ++++++++
.../x/async/api/AsyncSetDataBuilder.java | 54 ++++++++
.../curator/x/async/api/AsyncSyncBuilder.java | 29 +++++
.../async/api/AsyncTransactionCheckBuilder.java | 35 ++++++
.../api/AsyncTransactionCreateBuilder.java | 66 ++++++++++
.../api/AsyncTransactionDeleteBuilder.java | 35 ++++++
.../curator/x/async/api/AsyncTransactionOp.java | 54 ++++++++
.../api/AsyncTransactionSetDataBuilder.java | 51 ++++++++
.../curator/x/async/api/CreateOption.java | 76 +++++++++++
.../curator/x/async/api/DeleteOption.java | 44 +++++++
.../curator/x/async/api/ExistsOption.java | 35 ++++++
.../x/async/api/RemoveWatcherOption.java | 45 +++++++
.../async/api/WatchedAsyncCuratorFramework.java | 59 +++++++++
.../x/async/details/AsyncCreateBuilderImpl.java | 6 +-
.../details/AsyncCuratorFrameworkImpl.java | 1 +
.../x/async/details/AsyncDeleteBuilderImpl.java | 6 +-
.../x/async/details/AsyncExistsBuilderImpl.java | 6 +-
.../details/AsyncGetChildrenBuilderImpl.java | 4 +-
.../details/AsyncGetConfigBuilderImpl.java | 4 +-
.../async/details/AsyncGetDataBuilderImpl.java | 4 +-
.../async/details/AsyncReconfigBuilderImpl.java | 4 +-
.../details/AsyncRemoveWatchesBuilderImpl.java | 6 +-
.../x/async/details/AsyncSetACLBuilderImpl.java | 4 +-
.../async/details/AsyncSetDataBuilderImpl.java | 4 +-
.../x/async/details/AsyncTransactionOpImpl.java | 14 +--
.../curator/x/async/TestBasicOperations.java | 4 +-
69 files changed, 1524 insertions(+), 1502 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCreateBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCreateBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCreateBuilder.java
deleted file mode 100644
index 708ae75..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCreateBuilder.java
+++ /dev/null
@@ -1,114 +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.async;
-
-import org.apache.zookeeper.CreateMode;
-import org.apache.zookeeper.data.ACL;
-import org.apache.zookeeper.data.Stat;
-import java.util.List;
-import java.util.Set;
-
-/**
- * Builder for ZNode creates
- */
-public interface AsyncCreateBuilder extends AsyncPathAndBytesable<AsyncStage<String>>
-{
- /**
- * Have the operation fill the provided stat object
- *
- * @param stat the stat to have filled in
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> storingStatIn(Stat stat);
-
- /**
- * Use the given create mode. The default is {@link org.apache.zookeeper.CreateMode#PERSISTENT}
- *
- * @param createMode mode to use
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withMode(CreateMode createMode);
-
- /**
- * Set an ACL list (default is {@link org.apache.zookeeper.ZooDefs.Ids#OPEN_ACL_UNSAFE})
- *
- * @param aclList the ACL list to use
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withACL(List<ACL> aclList);
-
- /**
- * Options to change how the ZNode is created
- *
- * @param options options
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options);
-
- /**
- * set options and ACLs
- *
- * @param options options
- * @param aclList the ACL list to use
- * @see #withOptions(java.util.Set)
- * @see #withACL(java.util.List)
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, List<ACL> aclList);
-
- /**
- * set options, mode and ACLs
- *
- * @param options options
- * @param createMode mode to use
- * @param aclList the ACL list to use
- * @see #withACL(java.util.List)
- * @see #withOptions(java.util.Set)
- * @see #withMode(org.apache.zookeeper.CreateMode)
- * @see #withACL(java.util.List)
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode, List<ACL> aclList);
-
- /**
- * set options and mode
- *
- * @param options options
- * @param createMode mode to use
- * @see #withOptions(java.util.Set)
- * @see #withMode(org.apache.zookeeper.CreateMode)
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode);
-
- /**
- * set options, mode, ACLs, and stat
- *
- * @param options options
- * @param createMode mode to use
- * @param aclList the ACL list to use
- * @param stat the stat to have filled in
- * @see #withOptions(java.util.Set)
- * @see #withMode(org.apache.zookeeper.CreateMode)
- * @see #withACL(java.util.List)
- * @see #storingStatIn(org.apache.zookeeper.data.Stat)
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode, List<ACL> aclList, Stat stat);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFramework.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFramework.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFramework.java
index c12a28b..d1c5991 100644
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFramework.java
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFramework.java
@@ -20,6 +20,8 @@ package org.apache.curator.x.async;
import org.apache.curator.framework.CuratorFramework;
import org.apache.curator.framework.api.UnhandledErrorListener;
+import org.apache.curator.x.async.api.AsyncCuratorFrameworkDsl;
+import org.apache.curator.x.async.api.WatchedAsyncCuratorFramework;
import org.apache.curator.x.async.details.AsyncCuratorFrameworkImpl;
/**
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFrameworkDsl.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFrameworkDsl.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFrameworkDsl.java
deleted file mode 100644
index 2c777d5..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncCuratorFrameworkDsl.java
+++ /dev/null
@@ -1,99 +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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-
-/**
- * Zookeeper framework-style client
- */
-public interface AsyncCuratorFrameworkDsl extends WatchedAsyncCuratorFramework
-{
- /**
- * Start a create builder
- *
- * @return builder object
- */
- AsyncCreateBuilder create();
-
- /**
- * Start a delete builder
- *
- * @return builder object
- */
- AsyncDeleteBuilder delete();
-
- /**
- * Start a set data builder
- *
- * @return builder object
- */
- AsyncSetDataBuilder setData();
-
- /**
- * Start a get ACL builder
- *
- * @return builder object
- */
- AsyncGetACLBuilder getACL();
-
- /**
- * Start a set ACL builder
- *
- * @return builder object
- */
- AsyncSetACLBuilder setACL();
-
- /**
- * Start a reconfig builder
- *
- * @return builder object
- */
- AsyncReconfigBuilder reconfig();
-
- /**
- * Start a transaction builder
- *
- * @return builder object
- */
- AsyncMultiTransaction transaction();
-
- /**
- * Allocate an operation that can be used with {@link #transaction()}.
- * NOTE: {@link CuratorOp} instances created by this builder are
- * reusable.
- *
- * @return operation builder
- */
- AsyncTransactionOp transactionOp();
-
- /**
- * Start a sync builder
- *
- * @return builder object
- */
- AsyncSyncBuilder sync();
-
- /**
- * Start a remove watches builder
- *
- * @return builder object
- */
- AsyncRemoveWatchesBuilder removeWatches();
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncDeleteBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncDeleteBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncDeleteBuilder.java
deleted file mode 100644
index c16cbe2..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncDeleteBuilder.java
+++ /dev/null
@@ -1,54 +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.async;
-
-import java.util.Set;
-
-/**
- * Builder for ZNode deletions
- */
-public interface AsyncDeleteBuilder extends AsyncPathable<AsyncStage<Void>>
-{
- /**
- * Changes the deletion options. By default, no options are used
- *
- * @param options set of deletion options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> withOptions(Set<DeleteOption> options);
-
- /**
- * Set options and version.
- *
- * @param options set of deletion options
- * @param version version to use
- * @see #withOptions(java.util.Set)
- * @see #withVersion(int)
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> withOptionsAndVersion(Set<DeleteOption> options, int version);
-
- /**
- * Changes the version number passed to the delete() method. By default, -1 is used
- *
- * @param version version to use
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> withVersion(int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncEnsemblable.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncEnsemblable.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncEnsemblable.java
deleted file mode 100644
index b096fa1..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncEnsemblable.java
+++ /dev/null
@@ -1,32 +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.async;
-
-/**
- * Terminal operation for config/reconfig builders
- */
-public interface AsyncEnsemblable<T>
-{
- /**
- * Commit the currently building operation and invoke ZooKeeper
- *
- * @return async stage
- */
- T forEnsemble();
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncExistsBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncExistsBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncExistsBuilder.java
deleted file mode 100644
index 9c14076..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncExistsBuilder.java
+++ /dev/null
@@ -1,36 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-import java.util.Set;
-
-/**
- * Builder for ZNode exists
- */
-public interface AsyncExistsBuilder extends AsyncPathable<AsyncStage<Stat>>
-{
- /**
- * Use the given options. The default is to use no options
- *
- * @param options options to use
- * @return this
- */
- AsyncPathable<AsyncStage<Stat>> withOptions(Set<ExistsOption> options);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetACLBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetACLBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetACLBuilder.java
deleted file mode 100644
index 355a498..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetACLBuilder.java
+++ /dev/null
@@ -1,37 +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.async;
-
-import org.apache.zookeeper.data.ACL;
-import org.apache.zookeeper.data.Stat;
-import java.util.List;
-
-/**
- * Builder for getAcls
- */
-public interface AsyncGetACLBuilder extends AsyncPathable<AsyncStage<List<ACL>>>
-{
- /**
- * Have the operation fill the provided stat object
- *
- * @param stat the stat to have filled in
- * @return this
- */
- AsyncPathable<AsyncStage<List<ACL>>> storingStatIn(Stat stat);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetChildrenBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetChildrenBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetChildrenBuilder.java
deleted file mode 100644
index 3cf671f..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetChildrenBuilder.java
+++ /dev/null
@@ -1,36 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-import java.util.List;
-
-/**
- * Builder for getChildren()
- */
-public interface AsyncGetChildrenBuilder extends AsyncPathable<AsyncStage<List<String>>>
-{
- /**
- * Have the operation fill the provided stat object
- *
- * @param stat the stat to have filled in
- * @return this
- */
- AsyncPathable<AsyncStage<List<String>>> storingStatIn(Stat stat);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetConfigBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetConfigBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetConfigBuilder.java
deleted file mode 100644
index 8e5ec48..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetConfigBuilder.java
+++ /dev/null
@@ -1,35 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-
-/**
- * Builder for getConfig()
- */
-public interface AsyncGetConfigBuilder extends AsyncEnsemblable<AsyncStage<byte[]>>
-{
- /**
- * Have the operation fill the provided stat object
- *
- * @param stat the stat to have filled in
- * @return this
- */
- AsyncEnsemblable<AsyncStage<byte[]>> storingStatIn(Stat stat);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetDataBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetDataBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetDataBuilder.java
deleted file mode 100644
index bae9b2b..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncGetDataBuilder.java
+++ /dev/null
@@ -1,52 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-
-/**
- * Builder to get ZNode data
- */
-public interface AsyncGetDataBuilder extends AsyncPathable<AsyncStage<byte[]>>
-{
- /**
- * Cause the data to be de-compressed using the configured compression provider
- *
- * @return this
- */
- AsyncPathable<AsyncStage<byte[]>> decompressed();
-
- /**
- * Have the operation fill the provided stat object
- *
- * @param stat the stat to have filled in
- * @return this
- */
- AsyncPathable<AsyncStage<byte[]>> storingStatIn(Stat stat);
-
- /**
- * Have the operation fill the provided stat object and have the data be de-compressed
- *
- * @param stat the stat to have filled in
- * @see #decompressed()
- * @see #storingStatIn(org.apache.zookeeper.data.Stat)
- * @return this
- */
- AsyncPathable<AsyncStage<byte[]>> decompressedStoringStatIn(Stat stat);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncMultiTransaction.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncMultiTransaction.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncMultiTransaction.java
deleted file mode 100644
index 8ea27a2..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncMultiTransaction.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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-import org.apache.curator.framework.api.transaction.CuratorTransactionResult;
-import java.util.List;
-
-/**
- * Terminal operation to support multi/transactions
- */
-public interface AsyncMultiTransaction
-{
- /**
- * Invoke ZooKeeper to commit the given operations as a single transaction. Create the
- * operation instances via {@link org.apache.curator.x.async.AsyncCuratorFramework#transactionOp()}
- *
- * @param operations operations that make up the transaction.
- * @return AsyncStage instance for managing the completion
- */
- AsyncStage<List<CuratorTransactionResult>> forOperations(List<CuratorOp> operations);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathAndBytesable.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathAndBytesable.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathAndBytesable.java
deleted file mode 100644
index cdd5d76..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathAndBytesable.java
+++ /dev/null
@@ -1,36 +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.async;
-
-/**
- * Terminal operation for various builders
- */
-public interface AsyncPathAndBytesable<T> extends AsyncPathable<T>
-{
- /**
- * Commit the currently building operation using the given path and data
- * and invoke ZooKeeper
- *
- * @param path the path
- * @param data the data
- * @return usually an async stage
- */
- T forPath(String path, byte[] data);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathable.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathable.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathable.java
deleted file mode 100644
index 8396fd6..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncPathable.java
+++ /dev/null
@@ -1,34 +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.async;
-
-/**
- * Terminal operation for various builders
- */
-public interface AsyncPathable<T>
-{
- /**
- * Commit the currently building operation using the given path
- * and invoke ZooKeeper
- *
- * @param path the path
- * @return usually an async stage
- */
- T forPath(String path);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncReconfigBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncReconfigBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncReconfigBuilder.java
deleted file mode 100644
index 4be4abc..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncReconfigBuilder.java
+++ /dev/null
@@ -1,117 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-import java.util.List;
-
-/**
- * Builder for reconfigs
- */
-public interface AsyncReconfigBuilder
-{
- /**
- * Sets one or more members that are meant to be the ensemble.
- * The expected format is: <code>server.[id]=[hostname]:[peer port]:[election port]:[type];[client port]</code>
- *
- * @param servers The new server list
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withNewMembers(List<String> servers);
-
- /**
- * Adds servers to join the ensemble and/or servers to leave the ensemble. The format for <strong>joining</strong>
- * is: <code>server.[id]=[hostname]:[peer port]:[election port]:[type];[client port]</code>. The format
- * for <strong>leaving</strong> is a list of server IDs.
- *
- * @param joining The servers joining
- * @param leaving The servers leaving
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withJoiningAndLeaving(List<String> joining, List<String> leaving);
-
- /**
- * Same as {@link #withNewMembers(java.util.List)} but allows specified the configuration version to use.
- * By default the configuration version is -1.
- *
- * @param servers The new server list
- * @param fromConfig the config version to use
- * @see #withNewMembers(java.util.List)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withNewMembers(List<String> servers, long fromConfig);
-
- /**
- * Specify joiners, leaves and config version. By default the configuration version is -1.
- *
- * @param joining The servers joining
- * @param leaving The servers leaving
- * @param fromConfig the config version to use
- * @see #withJoiningAndLeaving(java.util.List, java.util.List)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withJoiningAndLeaving(List<String> joining, List<String> leaving, long fromConfig);
-
- /**
- * Same as {@link #withNewMembers(java.util.List)} but allows a stat to hold the stat info from "/zookeeper/config"
- *
- * @param servers The servers joining.
- * @param stat stat to hold the stat value
- * @see #withNewMembers(java.util.List)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withNewMembers(List<String> servers, Stat stat);
-
- /**
- * Same as {@link #withJoiningAndLeaving(java.util.List, java.util.List)}
- * but allows a stat to hold the stat info from "/zookeeper/config"
- *
- * @param joining The servers joining
- * @param leaving The servers leaving
- * @param stat stat to hold the stat value
- * @see #withJoiningAndLeaving(java.util.List, java.util.List)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withJoiningAndLeaving(List<String> joining, List<String> leaving, Stat stat);
-
- /**
- * Same as {@link #withNewMembers(java.util.List)} with stat and config version
- *
- * @param servers The servers joining.
- * @param stat stat to hold the stat value
- * @param fromConfig the config version to use
- * @see #withNewMembers(java.util.List, long)
- * @see #withNewMembers(java.util.List, org.apache.zookeeper.data.Stat)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withNewMembers(List<String> servers, Stat stat, long fromConfig);
-
- /**
- * Same as {@link #withJoiningAndLeaving(java.util.List, java.util.List)} with stat and config version
- *
- * @param joining The servers joining
- * @param leaving The servers leaving
- * @param stat stat to hold the stat value
- * @param fromConfig the config version to use
- * @see #withJoiningAndLeaving(java.util.List, java.util.List, long)
- * @see #withJoiningAndLeaving(java.util.List, java.util.List, org.apache.zookeeper.data.Stat)
- * @return this
- */
- AsyncEnsemblable<AsyncStage<Void>> withJoiningAndLeaving(List<String> joining, List<String> leaving, Stat stat, long fromConfig);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncRemoveWatchesBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncRemoveWatchesBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncRemoveWatchesBuilder.java
deleted file mode 100644
index c73569f..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncRemoveWatchesBuilder.java
+++ /dev/null
@@ -1,125 +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.async;
-
-import org.apache.curator.framework.api.CuratorWatcher;
-import org.apache.zookeeper.Watcher;
-import java.util.Set;
-
-/**
- * Builder for watcher removal
- */
-public interface AsyncRemoveWatchesBuilder
-{
- /**
- * @param watcher the watcher to remove
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(Watcher watcher);
-
- /**
- * @param watcher the watcher to remove
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(CuratorWatcher watcher);
-
- /**
- * Remove all watchers
- *
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removingAll();
-
- /**
- * @param watcher the watcher to remove
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(Watcher watcher, Set<RemoveWatcherOption> options);
-
- /**
- * @param watcher the watcher to remove
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(CuratorWatcher watcher, Set<RemoveWatcherOption> options);
-
- /**
- * Remove all watchers
- *
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removingAll(Set<RemoveWatcherOption> options);
-
- /**
- * Remove a watcher of a given type
- *
- * @param watcher the watcher to remove
- * @param watcherType watcher type
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(Watcher watcher, Watcher.WatcherType watcherType, Set<RemoveWatcherOption> options);
-
- /**
- * Remove a watcher of a given type
- *
- * @param watcher the watcher to remove
- * @param watcherType watcher type
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(CuratorWatcher watcher, Watcher.WatcherType watcherType, Set<RemoveWatcherOption> options);
-
- /**
- * Remove all watchers of a given type
- *
- * @param watcherType watcher type
- * @param options watcher removal options
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removingAll(Watcher.WatcherType watcherType, Set<RemoveWatcherOption> options);
-
- /**
- * Remove a watcher of a given type
- *
- * @param watcher the watcher to remove
- * @param watcherType watcher type
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(Watcher watcher, Watcher.WatcherType watcherType);
-
- /**
- * Remove a watcher of a given type
- *
- * @param watcher the watcher to remove
- * @param watcherType watcher type
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removing(CuratorWatcher watcher, Watcher.WatcherType watcherType);
-
- /**
- * Remove all watchers of a given type
- *
- * @param watcherType watcher type
- * @return this
- */
- AsyncPathable<AsyncStage<Void>> removingAll(Watcher.WatcherType watcherType);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetACLBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetACLBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetACLBuilder.java
deleted file mode 100644
index c2ad6be..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetACLBuilder.java
+++ /dev/null
@@ -1,48 +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.async;
-
-import org.apache.zookeeper.data.ACL;
-import org.apache.zookeeper.data.Stat;
-import java.util.List;
-
-/**
- * Builder for setting ACLs
- */
-public interface AsyncSetACLBuilder
-{
- /**
- * Set the given ACLs
- *
- * @param aclList ACLs to set
- * @return this
- */
- AsyncPathable<AsyncStage<Stat>> withACL(List<ACL> aclList);
-
- /**
- * Set the given ACLs only if the "a" version matches. By default -1 is used
- * which matches all versions.
- *
- * @param aclList ACLs to set
- * @param version "a" version
- * @see org.apache.zookeeper.data.Stat#getAversion()
- * @return this
- */
- AsyncPathable<AsyncStage<Stat>> withACL(List<ACL> aclList, int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetDataBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetDataBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetDataBuilder.java
deleted file mode 100644
index a1f0ff5..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSetDataBuilder.java
+++ /dev/null
@@ -1,53 +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.async;
-
-import org.apache.zookeeper.data.Stat;
-
-/**
- * Builder for setting ZNode data
- */
-public interface AsyncSetDataBuilder extends AsyncPathAndBytesable<AsyncStage<Stat>>
-{
- /**
- * Cause the data to be compressed using the configured compression provider
- *
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<Stat>> compressed();
-
- /**
- * Cause the data to be compressed using the configured compression provider.
- * Only sets if the version matches. By default -1 is used
- * which matches all versions.
- *
- * @param version version
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<Stat>> compressedWithVersion(int version);
-
- /**
- * Only sets if the version matches. By default -1 is used
- * which matches all versions.
- *
- * @param version version
- * @return this
- */
- AsyncPathAndBytesable<AsyncStage<Stat>> withVersion(int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncStage.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncStage.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncStage.java
index a8d594a..52b4c38 100644
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncStage.java
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncStage.java
@@ -27,7 +27,7 @@ import java.util.concurrent.CompletionStage;
public interface AsyncStage<T> extends CompletionStage<T>
{
/**
- * If the {@link org.apache.curator.x.async.WatchedAsyncCuratorFramework} facade is
+ * If the {@link org.apache.curator.x.async.api.WatchedAsyncCuratorFramework} facade is
* used (via {@link AsyncCuratorFramework#watched()}), this returns the completion
* stage used when the watcher is triggered
*
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSyncBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSyncBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSyncBuilder.java
deleted file mode 100644
index 98da505..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncSyncBuilder.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.async;
-
-/**
- * Builder for syncs
- */
-public interface AsyncSyncBuilder extends
- AsyncPathable<AsyncStage<Void>>
-{
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCheckBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCheckBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCheckBuilder.java
deleted file mode 100644
index ece505c..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCheckBuilder.java
+++ /dev/null
@@ -1,35 +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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-
-/**
- * @see org.apache.curator.x.async.AsyncTransactionOp#check()
- */
-public interface AsyncTransactionCheckBuilder extends AsyncPathable<CuratorOp>
-{
- /**
- * Use the given version (the default is -1)
- *
- * @param version version to use
- * @return this
- */
- AsyncPathable<CuratorOp> withVersion(int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCreateBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCreateBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCreateBuilder.java
deleted file mode 100644
index b39d69e..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionCreateBuilder.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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-import org.apache.zookeeper.CreateMode;
-import org.apache.zookeeper.data.ACL;
-import java.util.List;
-
-/**
- * @see org.apache.curator.x.async.AsyncTransactionOp#create()
- */
-public interface AsyncTransactionCreateBuilder extends AsyncPathAndBytesable<CuratorOp>
-{
- /**
- * Specify a mode for the create. The default is {@link org.apache.zookeeper.CreateMode#PERSISTENT}
- *
- * @param createMode mode
- * @return this
- */
- AsyncPathable<CuratorOp> withMode(CreateMode createMode);
-
- /**
- * Set an ACL list (default is {@link org.apache.zookeeper.ZooDefs.Ids#OPEN_ACL_UNSAFE})
- *
- * @param aclList the ACL list to use
- * @return this
- */
- AsyncPathable<CuratorOp> withACL(List<ACL> aclList);
-
- /**
- * Cause the data to be compressed using the configured compression provider
- *
- * @return this
- */
- AsyncPathable<CuratorOp> compressed();
-
- /**
- * Specify mode, acl list and compression
- *
- * @param createMode mode
- * @param aclList the ACL list to use
- * @param compressed true to compress
- * @see #withMode(org.apache.zookeeper.CreateMode)
- * @see #withACL(java.util.List)
- * @see #compressed()
- * @return this
- */
- AsyncPathable<CuratorOp> withOptions(CreateMode createMode, List<ACL> aclList, boolean compressed);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionDeleteBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionDeleteBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionDeleteBuilder.java
deleted file mode 100644
index c49d42e..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionDeleteBuilder.java
+++ /dev/null
@@ -1,35 +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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-
-/**
- * @see org.apache.curator.x.async.AsyncTransactionOp#delete()
- */
-public interface AsyncTransactionDeleteBuilder extends AsyncPathable<CuratorOp>
-{
- /**
- * Changes the version number used. By default, -1 is used
- *
- * @param version version to use
- * @return this
- */
- AsyncPathable<CuratorOp> withVersion(int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionOp.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionOp.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionOp.java
deleted file mode 100644
index a659d6f..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionOp.java
+++ /dev/null
@@ -1,54 +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.async;
-
-/**
- * Builds operations that can be committed as a transaction
- * via {@link org.apache.curator.x.async.AsyncCuratorFramework#transaction()}
- */
-public interface AsyncTransactionOp
-{
- /**
- * Start a create builder in the transaction
- *
- * @return builder object
- */
- AsyncTransactionCreateBuilder create();
-
- /**
- * Start a delete builder in the transaction
- *
- * @return builder object
- */
- AsyncTransactionDeleteBuilder delete();
-
- /**
- * Start a setData builder in the transaction
- *
- * @return builder object
- */
- AsyncTransactionSetDataBuilder setData();
-
- /**
- * Start a check builder in the transaction
- *
- * @return builder object
- */
- AsyncTransactionCheckBuilder check();
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionSetDataBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionSetDataBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionSetDataBuilder.java
deleted file mode 100644
index 5fce4d5..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/AsyncTransactionSetDataBuilder.java
+++ /dev/null
@@ -1,51 +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.async;
-
-import org.apache.curator.framework.api.transaction.CuratorOp;
-
-/**
- * @see org.apache.curator.x.async.AsyncTransactionOp#setData()
- */
-public interface AsyncTransactionSetDataBuilder extends AsyncPathAndBytesable<CuratorOp>
-{
- /**
- * Changes the version number used. By default, -1 is used
- *
- * @param version version to use
- * @return this
- */
- AsyncPathAndBytesable<CuratorOp> withVersion(int version);
-
- /**
- * Cause the data to be compressed using the configured compression provider
- *
- * @return this
- */
- AsyncPathAndBytesable<CuratorOp> compressed();
-
- /**
- * Cause the data to be compressed using the configured compression provider.
- * Also changes the version number used. By default, -1 is used
- *
- * @param version version to use
- * @return this
- */
- AsyncPathAndBytesable<CuratorOp> withVersionCompressed(int version);
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/CreateOption.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/CreateOption.java b/curator-x-async/src/main/java/org/apache/curator/x/async/CreateOption.java
deleted file mode 100644
index 560c901..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/CreateOption.java
+++ /dev/null
@@ -1,76 +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.async;
-
-/**
- * Options when creating ZNodes
- */
-public enum CreateOption
-{
- /**
- * Causes any parent nodes to get created if they haven't already been
- */
- createParentsIfNeeded,
-
- /**
- * Causes any parent nodes to get created using {@link org.apache.zookeeper.CreateMode#CONTAINER} if they haven't already been.
- * IMPORTANT NOTE: container creation is a new feature in recent versions of ZooKeeper.
- * If the ZooKeeper version you're using does not support containers, the parent nodes
- * are created as ordinary PERSISTENT nodes.
- */
- createParentsAsContainers,
-
- /**
- * <p>
- * Hat-tip to https://github.com/sbridges for pointing this out
- * </p>
- *
- * <p>
- * It turns out there is an edge case that exists when creating sequential-ephemeral
- * nodes. The creation can succeed on the server, but the server can crash before
- * the created node name is returned to the client. However, the ZK session is still
- * valid so the ephemeral node is not deleted. Thus, there is no way for the client to
- * determine what node was created for them.
- * </p>
- *
- * <p>
- * Even without sequential-ephemeral, however, the create can succeed on the sever
- * but the client (for various reasons) will not know it.
- * </p>
- *
- * <p>
- * Putting the create builder into protection mode works around this.
- * The name of the node that is created is prefixed with a GUID. If node creation fails
- * the normal retry mechanism will occur. On the retry, the parent path is first searched
- * for a node that has the GUID in it. If that node is found, it is assumed to be the lost
- * node that was successfully created on the first try and is returned to the caller.
- * </p>
- */
- doProtected,
-
- /**
- * Cause the data to be compressed using the configured compression provider
- */
- compress,
-
- /**
- * If the ZNode already exists, Curator will instead call setData()
- */
- setDataIfExists
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/DeleteOption.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/DeleteOption.java b/curator-x-async/src/main/java/org/apache/curator/x/async/DeleteOption.java
deleted file mode 100644
index 1e8dfbd..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/DeleteOption.java
+++ /dev/null
@@ -1,44 +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.async;
-
-/**
- * Options to use when deleting ZNodes
- */
-public enum DeleteOption
-{
- /**
- * Prevents the reporting of {@link org.apache.zookeeper.KeeperException.NoNodeException}s.
- * If the ZNode doesn't exist the delete method will appear to succeed.
- */
- quietly,
-
- /**
- * Will also delete children if they exist
- */
- deletingChildrenIfNeeded,
-
- /**
- * Solves edge cases where an operation may succeed on the server but connection failure occurs before a
- * response can be successfully returned to the client.
- *
- * @see org.apache.curator.framework.api.GuaranteeableDeletable
- */
- guaranteed
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/ExistsOption.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/ExistsOption.java b/curator-x-async/src/main/java/org/apache/curator/x/async/ExistsOption.java
deleted file mode 100644
index 6efc8bd..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/ExistsOption.java
+++ /dev/null
@@ -1,35 +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.async;
-
-/**
- * Options to use when checking for ZNode existence
- */
-public enum ExistsOption
-{
- /**
- * see {@link org.apache.curator.x.async.CreateOption#createParentsIfNeeded}
- */
- createParentsIfNeeded,
-
- /**
- * see {@link org.apache.curator.x.async.CreateOption#createParentsAsContainers}
- */
- createParentsAsContainers
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/RemoveWatcherOption.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/RemoveWatcherOption.java b/curator-x-async/src/main/java/org/apache/curator/x/async/RemoveWatcherOption.java
deleted file mode 100644
index f1c01a4..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/RemoveWatcherOption.java
+++ /dev/null
@@ -1,45 +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.async;
-
-/**
- * Options to use when removing watchers
- */
-public enum RemoveWatcherOption
-{
- /**
- * Solves edge cases where an operation may succeed on the server but connection failure occurs before a
- * response can be successfully returned to the client.
- *
- * @see org.apache.curator.framework.api.GuaranteeableDeletable
- */
- guaranteed,
-
- /**
- * Specify if the client should just remove client side watches if a connection to ZK
- * is not available. Note that the standard Curator retry loop will not be used in t
- */
- local,
-
- /**
- * Prevents the reporting of {@link org.apache.zookeeper.KeeperException.NoNodeException}s.
- * If the watcher doesn't exist the remove method will appear to succeed.
- */
- quietly
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/WatchedAsyncCuratorFramework.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/WatchedAsyncCuratorFramework.java b/curator-x-async/src/main/java/org/apache/curator/x/async/WatchedAsyncCuratorFramework.java
deleted file mode 100644
index 92ab2bb..0000000
--- a/curator-x-async/src/main/java/org/apache/curator/x/async/WatchedAsyncCuratorFramework.java
+++ /dev/null
@@ -1,54 +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.async;
-
-/**
- * operations that support watching
- */
-public interface WatchedAsyncCuratorFramework
-{
- /**
- * Start an exists builder. The builder will return a Stat object as if org.apache.zookeeper.ZooKeeper.exists() were called. Thus, a null
- * means that it does not exist and an actual Stat object means it does exist.
- *
- * @return builder object
- */
- AsyncExistsBuilder checkExists();
-
- /**
- * Start a get data builder
- *
- * @return builder object
- */
- AsyncGetDataBuilder getData();
-
- /**
- * Start a get children builder
- *
- * @return builder object
- */
- AsyncGetChildrenBuilder getChildren();
-
- /**
- * Start a getConfig builder
- *
- * @return builder object
- */
- AsyncGetConfigBuilder getConfig();
-}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCreateBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCreateBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCreateBuilder.java
new file mode 100644
index 0000000..6f077bb
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCreateBuilder.java
@@ -0,0 +1,115 @@
+/**
+ * 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.async.api;
+
+import org.apache.curator.x.async.AsyncStage;
+import org.apache.zookeeper.CreateMode;
+import org.apache.zookeeper.data.ACL;
+import org.apache.zookeeper.data.Stat;
+import java.util.List;
+import java.util.Set;
+
+/**
+ * Builder for ZNode creates
+ */
+public interface AsyncCreateBuilder extends AsyncPathAndBytesable<AsyncStage<String>>
+{
+ /**
+ * Have the operation fill the provided stat object
+ *
+ * @param stat the stat to have filled in
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> storingStatIn(Stat stat);
+
+ /**
+ * Use the given create mode. The default is {@link org.apache.zookeeper.CreateMode#PERSISTENT}
+ *
+ * @param createMode mode to use
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withMode(CreateMode createMode);
+
+ /**
+ * Set an ACL list (default is {@link org.apache.zookeeper.ZooDefs.Ids#OPEN_ACL_UNSAFE})
+ *
+ * @param aclList the ACL list to use
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withACL(List<ACL> aclList);
+
+ /**
+ * Options to change how the ZNode is created
+ *
+ * @param options options
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options);
+
+ /**
+ * set options and ACLs
+ *
+ * @param options options
+ * @param aclList the ACL list to use
+ * @see #withOptions(java.util.Set)
+ * @see #withACL(java.util.List)
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, List<ACL> aclList);
+
+ /**
+ * set options, mode and ACLs
+ *
+ * @param options options
+ * @param createMode mode to use
+ * @param aclList the ACL list to use
+ * @see #withACL(java.util.List)
+ * @see #withOptions(java.util.Set)
+ * @see #withMode(org.apache.zookeeper.CreateMode)
+ * @see #withACL(java.util.List)
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode, List<ACL> aclList);
+
+ /**
+ * set options and mode
+ *
+ * @param options options
+ * @param createMode mode to use
+ * @see #withOptions(java.util.Set)
+ * @see #withMode(org.apache.zookeeper.CreateMode)
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode);
+
+ /**
+ * set options, mode, ACLs, and stat
+ *
+ * @param options options
+ * @param createMode mode to use
+ * @param aclList the ACL list to use
+ * @param stat the stat to have filled in
+ * @see #withOptions(java.util.Set)
+ * @see #withMode(org.apache.zookeeper.CreateMode)
+ * @see #withACL(java.util.List)
+ * @see #storingStatIn(org.apache.zookeeper.data.Stat)
+ * @return this
+ */
+ AsyncPathAndBytesable<AsyncStage<String>> withOptions(Set<CreateOption> options, CreateMode createMode, List<ACL> aclList, Stat stat);
+}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCuratorFrameworkDsl.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCuratorFrameworkDsl.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCuratorFrameworkDsl.java
new file mode 100644
index 0000000..813e660
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncCuratorFrameworkDsl.java
@@ -0,0 +1,99 @@
+/**
+ * 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.async.api;
+
+import org.apache.curator.framework.api.transaction.CuratorOp;
+
+/**
+ * Zookeeper framework-style client
+ */
+public interface AsyncCuratorFrameworkDsl extends WatchedAsyncCuratorFramework
+{
+ /**
+ * Start a create builder
+ *
+ * @return builder object
+ */
+ AsyncCreateBuilder create();
+
+ /**
+ * Start a delete builder
+ *
+ * @return builder object
+ */
+ AsyncDeleteBuilder delete();
+
+ /**
+ * Start a set data builder
+ *
+ * @return builder object
+ */
+ AsyncSetDataBuilder setData();
+
+ /**
+ * Start a get ACL builder
+ *
+ * @return builder object
+ */
+ AsyncGetACLBuilder getACL();
+
+ /**
+ * Start a set ACL builder
+ *
+ * @return builder object
+ */
+ AsyncSetACLBuilder setACL();
+
+ /**
+ * Start a reconfig builder
+ *
+ * @return builder object
+ */
+ AsyncReconfigBuilder reconfig();
+
+ /**
+ * Start a transaction builder
+ *
+ * @return builder object
+ */
+ AsyncMultiTransaction transaction();
+
+ /**
+ * Allocate an operation that can be used with {@link #transaction()}.
+ * NOTE: {@link CuratorOp} instances created by this builder are
+ * reusable.
+ *
+ * @return operation builder
+ */
+ AsyncTransactionOp transactionOp();
+
+ /**
+ * Start a sync builder
+ *
+ * @return builder object
+ */
+ AsyncSyncBuilder sync();
+
+ /**
+ * Start a remove watches builder
+ *
+ * @return builder object
+ */
+ AsyncRemoveWatchesBuilder removeWatches();
+}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncDeleteBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncDeleteBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncDeleteBuilder.java
new file mode 100644
index 0000000..0258167
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncDeleteBuilder.java
@@ -0,0 +1,55 @@
+/**
+ * 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.async.api;
+
+import org.apache.curator.x.async.AsyncStage;
+import java.util.Set;
+
+/**
+ * Builder for ZNode deletions
+ */
+public interface AsyncDeleteBuilder extends AsyncPathable<AsyncStage<Void>>
+{
+ /**
+ * Changes the deletion options. By default, no options are used
+ *
+ * @param options set of deletion options
+ * @return this
+ */
+ AsyncPathable<AsyncStage<Void>> withOptions(Set<DeleteOption> options);
+
+ /**
+ * Set options and version.
+ *
+ * @param options set of deletion options
+ * @param version version to use
+ * @see #withOptions(java.util.Set)
+ * @see #withVersion(int)
+ * @return this
+ */
+ AsyncPathable<AsyncStage<Void>> withOptionsAndVersion(Set<DeleteOption> options, int version);
+
+ /**
+ * Changes the version number passed to the delete() method. By default, -1 is used
+ *
+ * @param version version to use
+ * @return this
+ */
+ AsyncPathable<AsyncStage<Void>> withVersion(int version);
+}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncEnsemblable.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncEnsemblable.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncEnsemblable.java
new file mode 100644
index 0000000..a4b0d33
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncEnsemblable.java
@@ -0,0 +1,32 @@
+/**
+ * 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.async.api;
+
+/**
+ * Terminal operation for config/reconfig builders
+ */
+public interface AsyncEnsemblable<T>
+{
+ /**
+ * Commit the currently building operation and invoke ZooKeeper
+ *
+ * @return async stage
+ */
+ T forEnsemble();
+}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncExistsBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncExistsBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncExistsBuilder.java
new file mode 100644
index 0000000..6174c7a
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncExistsBuilder.java
@@ -0,0 +1,37 @@
+/**
+ * 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.async.api;
+
+import org.apache.curator.x.async.AsyncStage;
+import org.apache.zookeeper.data.Stat;
+import java.util.Set;
+
+/**
+ * Builder for ZNode exists
+ */
+public interface AsyncExistsBuilder extends AsyncPathable<AsyncStage<Stat>>
+{
+ /**
+ * Use the given options. The default is to use no options
+ *
+ * @param options options to use
+ * @return this
+ */
+ AsyncPathable<AsyncStage<Stat>> withOptions(Set<ExistsOption> options);
+}
http://git-wip-us.apache.org/repos/asf/curator/blob/476d55fe/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncGetACLBuilder.java
----------------------------------------------------------------------
diff --git a/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncGetACLBuilder.java b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncGetACLBuilder.java
new file mode 100644
index 0000000..be93eaf
--- /dev/null
+++ b/curator-x-async/src/main/java/org/apache/curator/x/async/api/AsyncGetACLBuilder.java
@@ -0,0 +1,38 @@
+/**
+ * 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.async.api;
+
+import org.apache.curator.x.async.AsyncStage;
+import org.apache.zookeeper.data.ACL;
+import org.apache.zookeeper.data.Stat;
+import java.util.List;
+
+/**
+ * Builder for getAcls
+ */
+public interface AsyncGetACLBuilder extends AsyncPathable<AsyncStage<List<ACL>>>
+{
+ /**
+ * Have the operation fill the provided stat object
+ *
+ * @param stat the stat to have filled in
+ * @return this
+ */
+ AsyncPathable<AsyncStage<List<ACL>>> storingStatIn(Stat stat);
+}