You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by si...@apache.org on 2018/02/28 02:52:19 UTC

[incubator-pulsar] branch master updated: Make buildtools dependency in test scope and a few updates in PulsarClientImpl (#1304)

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

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


The following commit(s) were added to refs/heads/master by this push:
     new 6689c4d  Make buildtools dependency in test scope and a few updates in PulsarClientImpl (#1304)
6689c4d is described below

commit 6689c4da8e3ad8d91b142246704b18ef85141bb6
Author: Sijie Guo <gu...@gmail.com>
AuthorDate: Tue Feb 27 18:52:17 2018 -0800

    Make buildtools dependency in test scope and a few updates in PulsarClientImpl (#1304)
---
 pom.xml                                                              | 1 +
 .../main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java    | 5 +++--
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/pom.xml b/pom.xml
index 23104a9..f1e7d3c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -606,6 +606,7 @@ flexible messaging model and an intuitive client API.</description>
       <groupId>org.apache.pulsar</groupId>
       <artifactId>buildtools</artifactId>
       <version>${project.version}</version>
+      <scope>test</scope>
     </dependency>
 
     <dependency>
diff --git a/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java b/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java
index a4b50ed..c07ec8b 100644
--- a/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java
+++ b/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java
@@ -221,7 +221,7 @@ public class PulsarClientImpl implements PulsarClient {
         }
 
         if (state.get() != State.Open) {
-            return FutureUtil.failedFuture(new PulsarClientException.AlreadyClosedException("Client already closed"));
+            return FutureUtil.failedFuture(new PulsarClientException.AlreadyClosedException("Client already closed : state = " + state.get()));
         }
 
         String topic = conf.getTopicName();
@@ -590,7 +590,8 @@ public class PulsarClientImpl implements PulsarClient {
                 .thenCompose(pair -> cnxPool.getConnection(pair.getLeft(), pair.getRight()));
     }
 
-    protected Timer timer() {
+    /** visiable for pulsar-functions **/
+    public Timer timer() {
         return timer;
     }
 

-- 
To stop receiving notification emails like this one, please contact
sijie@apache.org.