You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ro...@apache.org on 2017/10/18 23:26:03 UTC

[sling-org-apache-sling-nosql-couchbase-client] branch master created (now a808818)

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

rombert pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git.


      at a808818  SLING-7167 Adjust READMEs

This branch includes the following new commits:

     new 89e793b  SLING-4381 couchbase client
     new d91b632  SLING-4381 couchbase resource provider
     new 0f5ce14  SLING-4381 add READMEs, make factory configuration
     new b0102e8  SLING-4381 fix logic error for buckets with password; update readme
     new 0076ad4  Update contrib modules to Parent 23
     new 275a486  set parent version to 24 and add empty relativePath where missing
     new 839203c  update to latest couchbase client
     new 08bdb15  delay couchbase connection until first access, and make sure it is tried again and again until it succeeds
     new e4881c5  SLING-4381 update to latest couchbase java client
     new 0bf599a  cosmetic: fix javadoc errors
     new 93ecd05  prepare 1.0.0 release
     new 16f09af  [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.0
     new 333b6e6  [maven-release-plugin] prepare for next development iteration
     new 7e0f35d  Update the contrib reactor to parent 25
     new d3fb4fc  Switch to parent pom 26
     new bb79895  SLING-5558 Update to Couchbase Client 2.2.4
     new ad00d6e  exclude README.md in rat report
     new dcfd09d  [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2
     new cf66fad  [maven-release-plugin] prepare for next development iteration
     new f7ace2a  [maven-release-plugin] rollback the release of org.apache.sling.nosql.couchbase-client-1.0.2
     new e62a735  do not increase export package version when project version is updated - respect version from package-info.java
     new 8cd0bf8  [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2
     new acf58a0  [maven-release-plugin] prepare for next development iteration
     new a808818  SLING-7167 Adjust READMEs

The 24 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@sling.apache.org" <co...@sling.apache.org>'].

[sling-org-apache-sling-nosql-couchbase-client] 21/24: do not increase export package version when project version is updated - respect version from package-info.java

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit e62a735e1559960367348a4b07dd4f713b833313
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:15:50 2016 +0000

    do not increase export package version when project version is updated - respect version from package-info.java
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732114 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 0c4ff92..8cfa6af 100644
--- a/pom.xml
+++ b/pom.xml
@@ -97,7 +97,7 @@
                         <!-- use _exportcontents instead of Export-Package to avoid conflict with Embed-Dependency an inline=true -->
                         <_exportcontents>
                             com.couchbase.client.java.*;version=${couchbase.client.version},
-                            org.apache.sling.nosql.couchbase.client;version=${project.version}
+                            org.apache.sling.nosql.couchbase.client
                         </_exportcontents>
                         <Import-Package>
                             com.barchart.udt.*;resolution:=optional,

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 24/24: SLING-7167 Adjust READMEs

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit a80881862969ab645d486a55e6907adad8840165
Author: Oliver Lietz <ol...@apache.org>
AuthorDate: Tue Oct 3 10:05:54 2017 +0000

    SLING-7167 Adjust READMEs
    
    add uniform header linking to Sling project
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1810913 13f79535-47bb-0310-9956-ffa450edef68
---
 README.md | 19 ++++++++++---------
 1 file changed, 10 insertions(+), 9 deletions(-)

diff --git a/README.md b/README.md
index 4c47ad2..5516ac9 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,10 @@
-Apache Sling NoSQL Couchbase Client
-===================================
-
-Provides preconfigured clients for accessing a [Couchbase](http://www.couchbase.com/) NoSQL database.
-
-* Wraps the [Couchbase Java Client 2.x](https://github.com/couchbase/couchbase-java-client) and exports it via OSGi
-* Includes private dependencies of Couchbase Java Client
-* The couchbase access parameters can be configured via OSGi configuration.
-* Multiple couchbase clients can be configured for different couchbase hosts and/or buckets
+# Apache Sling NoSQL Couchbase Client
+
+This module is part of the [Apache Sling](https://sling.apache.org) project.
+
+Provides preconfigured clients for accessing a [Couchbase](http://www.couchbase.com/) NoSQL database.
+
+* Wraps the [Couchbase Java Client 2.x](https://github.com/couchbase/couchbase-java-client) and exports it via OSGi
+* Includes private dependencies of Couchbase Java Client
+* The couchbase access parameters can be configured via OSGi configuration.
+* Multiple couchbase clients can be configured for different couchbase hosts and/or buckets

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 19/24: [maven-release-plugin] prepare for next development iteration

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit cf66fadccb38cd3809987108e78e08d71208e42e
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:08:15 2016 +0000

    [maven-release-plugin] prepare for next development iteration
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732107 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/pom.xml b/pom.xml
index d52168b..0f394f3 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,16 +28,16 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.2</version>
+    <version>1.0.3-SNAPSHOT</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 03/24: SLING-4381 add READMEs, make factory configuration

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 0f5ce141588a2546e6cf843dfb66491748d2d747
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed May 20 16:11:14 2015 +0000

    SLING-4381 add READMEs, make factory configuration
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1680622 13f79535-47bb-0310-9956-ffa450edef68
---
 README.md | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/README.md b/README.md
new file mode 100644
index 0000000..4c47ad2
--- /dev/null
+++ b/README.md
@@ -0,0 +1,9 @@
+Apache Sling NoSQL Couchbase Client
+===================================
+
+Provides preconfigured clients for accessing a [Couchbase](http://www.couchbase.com/) NoSQL database.
+
+* Wraps the [Couchbase Java Client 2.x](https://github.com/couchbase/couchbase-java-client) and exports it via OSGi
+* Includes private dependencies of Couchbase Java Client
+* The couchbase access parameters can be configured via OSGi configuration.
+* Multiple couchbase clients can be configured for different couchbase hosts and/or buckets

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 22/24: [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 8cd0bf8cc370a7c6c132011dc55001632d6df4c3
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:16:33 2016 +0000

    [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732115 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/pom.xml b/pom.xml
index 8cfa6af..90f72e9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,16 +28,16 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.1-SNAPSHOT</version>
+    <version>1.0.2</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 23/24: [maven-release-plugin] prepare for next development iteration

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit acf58a010cf018f0b067077cd2a87fff02606be2
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:16:48 2016 +0000

    [maven-release-plugin] prepare for next development iteration
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732117 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/pom.xml b/pom.xml
index 90f72e9..0281d76 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,16 +28,16 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.2</version>
+    <version>1.0.3-SNAPSHOT</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 20/24: [maven-release-plugin] rollback the release of org.apache.sling.nosql.couchbase-client-1.0.2

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit f7ace2ac1e57e643b2ac00bc4cb44510bea52683
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:09:36 2016 +0000

    [maven-release-plugin] rollback the release of org.apache.sling.nosql.couchbase-client-1.0.2
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732108 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 0f394f3..0c4ff92 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,7 +28,7 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.3-SNAPSHOT</version>
+    <version>1.0.1-SNAPSHOT</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 10/24: cosmetic: fix javadoc errors

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 0bf599aaa426369963876e37d09185dca991821b
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Thu Sep 17 21:23:52 2015 +0000

    cosmetic: fix javadoc errors
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1703693 13f79535-47bb-0310-9956-ffa450edef68
---
 src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java
index e495ffc..6b07974 100644
--- a/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java
@@ -40,7 +40,7 @@ public final class CouchbaseKey {
      * Builds a key for a couchbase document with the given prefix that does not
      * exceed the max. length for couchbase keys.
      * @param key Full key
-     * @param cacheKeyPrefix Prefix to add before the key
+     * @param keyPrefix Prefix to add before the key
      * @return Valid key for couchbase
      */
     public static String build(String key, String keyPrefix) {

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 04/24: SLING-4381 fix logic error for buckets with password; update readme

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit b0102e812333a3ed651916be3e608f057f027d37
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Thu May 21 07:12:11 2015 +0000

    SLING-4381 fix logic error for buckets with password; update readme
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1680746 13f79535-47bb-0310-9956-ffa450edef68
---
 .../sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java      | 4 ++--
 .../impl/{CouchbaseUtil.java => CouchbaseEnvironmentSingleton.java} | 6 +++---
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
index a12a61f..5103ca4 100644
--- a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
@@ -97,8 +97,8 @@ public class CouchbaseClientImpl implements CouchbaseClient {
         }
 
         try {
-            cluster = CouchbaseUtil.createCluster(couchbaseHosts);
-            bucket = CouchbaseUtil.openBucket(cluster, bucketName, bucketPassword);
+            cluster = CouchbaseEnvironmentSingleton.createCluster(couchbaseHosts);
+            bucket = CouchbaseEnvironmentSingleton.openBucket(cluster, bucketName, bucketPassword);
         }
         catch (Throwable ex) {
             enabled = false;
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseEnvironmentSingleton.java
similarity index 94%
rename from src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java
rename to src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseEnvironmentSingleton.java
index 523870c..555fac8 100644
--- a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseEnvironmentSingleton.java
@@ -27,11 +27,11 @@ import com.couchbase.client.java.env.DefaultCouchbaseEnvironment;
 /**
  * Manages couchbase environment.
  */
-final class CouchbaseUtil {
+final class CouchbaseEnvironmentSingleton {
 
     private static final CouchbaseEnvironment COUCHBASE_ENVIRONMENT = DefaultCouchbaseEnvironment.builder().build();
 
-    private CouchbaseUtil() {
+    private CouchbaseEnvironmentSingleton() {
         // static methods only
     }
 
@@ -52,7 +52,7 @@ final class CouchbaseUtil {
      * @return Couchbase bucket
      */
     public static Bucket openBucket(Cluster cluster, String bucketName, String bucketPassword) {
-        if (bucketPassword == null) {
+        if (bucketPassword != null) {
             return cluster.openBucket(bucketName, bucketPassword);
         }
         else {

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 09/24: SLING-4381 update to latest couchbase java client

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit e4881c52b347c8d3d50eff88adb581530f79482c
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Mon Sep 14 21:25:29 2015 +0000

    SLING-4381 update to latest couchbase java client
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1703064 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 3f243e8..2b41a38 100644
--- a/pom.xml
+++ b/pom.xml
@@ -43,7 +43,7 @@
 
     <properties>
         <sling.java.version>7</sling.java.version>
-        <couchbase.client.version>2.1.4</couchbase.client.version>
+        <couchbase.client.version>2.2.0</couchbase.client.version>
     </properties>
 
     <dependencies>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 11/24: prepare 1.0.0 release

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 93ecd05a4cd9602f4352b9d3adf717d5cc198f85
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Thu Sep 17 21:26:33 2015 +0000

    prepare 1.0.0 release
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1703694 13f79535-47bb-0310-9956-ffa450edef68
---
 src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java b/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java
index 537c719..dc732ee 100644
--- a/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java
@@ -19,6 +19,6 @@
 /**
  * Couchbase Client Provider
  */
-@aQute.bnd.annotation.Version("0.5.0")
+@aQute.bnd.annotation.Version("1.0.0")
 package org.apache.sling.nosql.couchbase.client;
 

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 13/24: [maven-release-plugin] prepare for next development iteration

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 333b6e65d781ba1868a8db93d62563caf33f78fc
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Thu Sep 17 21:31:52 2015 +0000

    [maven-release-plugin] prepare for next development iteration
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1703704 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/pom.xml b/pom.xml
index 6e19954..5f9bea7 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,16 +28,16 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.0</version>
+    <version>1.0.1-SNAPSHOT</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 18/24: [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit dcfd09d601fc117a67b78a8ca461a7f40dccc7a8
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:07:59 2016 +0000

    [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.2
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732105 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/pom.xml b/pom.xml
index 0c4ff92..d52168b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,16 +28,16 @@
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>1.0.1-SNAPSHOT</version>
+    <version>1.0.2</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.2</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 14/24: Update the contrib reactor to parent 25

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 7e0f35d8d7cea5405d2775f6e319e27430f202a4
Author: Robert Munteanu <ro...@apache.org>
AuthorDate: Mon Oct 5 10:04:15 2015 +0000

    Update the contrib reactor to parent 25
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1706781 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 5f9bea7..1d3e4ee 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@
     <parent>
         <groupId>org.apache.sling</groupId>
         <artifactId>sling</artifactId>
-        <version>24</version>
+        <version>25</version>
         <relativePath />
     </parent>
 

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 07/24: update to latest couchbase client

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 839203cf6a684496bd5b61aba26a0be7d41d49a0
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Fri Aug 14 16:28:16 2015 +0000

    update to latest couchbase client
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1695937 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 103c21c..3f243e8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -43,7 +43,7 @@
 
     <properties>
         <sling.java.version>7</sling.java.version>
-        <couchbase.client.version>2.1.3</couchbase.client.version>
+        <couchbase.client.version>2.1.4</couchbase.client.version>
     </properties>
 
     <dependencies>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 08/24: delay couchbase connection until first access, and make sure it is tried again and again until it succeeds

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 08bdb155901102e42388c8762d4ad3476308e125
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Fri Aug 14 16:45:43 2015 +0000

    delay couchbase connection until first access, and make sure it is tried again and again until it succeeds
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1695944 13f79535-47bb-0310-9956-ffa450edef68
---
 .../couchbase/client/impl/CouchbaseClientImpl.java | 36 ++++++++++++++--------
 1 file changed, 23 insertions(+), 13 deletions(-)

diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
index 5103ca4..ef9a779 100644
--- a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
@@ -68,7 +68,11 @@ public class CouchbaseClientImpl implements CouchbaseClient {
 
     private String clientId;
     private boolean enabled;
+    private String[] couchbaseHosts;
     private String bucketName;
+    private String bucketPassword;
+    
+    private volatile boolean initialized;
     private Cluster cluster;
     private Bucket bucket;
 
@@ -76,34 +80,26 @@ public class CouchbaseClientImpl implements CouchbaseClient {
     private void activate(Map<String, Object> config) {
         clientId = PropertiesUtil.toString(config.get(CLIENT_ID_PROPERTY), null);
         enabled = PropertiesUtil.toBoolean(config.get(ENABLED_PROPERTY), ENABLED_PROPERTY_DEFAULT);
+        couchbaseHosts = PropertiesUtil.toStringArray(config.get(COUCHBASE_HOSTS_PROPERTY));
+        bucketName = PropertiesUtil.toString(config.get(CACHE_BUCKET_NAME_PROPERTY), null);
+        bucketPassword = PropertiesUtil.toString(config.get(CACHE_BUCKET_PASSWORD_PROPERTY), null);
+
         if (!enabled) {
             log.info("Couchbase caching for client '{}' is disabled by configuration.", clientId);
             return;
         }
 
-        String[] couchbaseHosts = PropertiesUtil.toStringArray(config.get(COUCHBASE_HOSTS_PROPERTY));
         if (couchbaseHosts == null || couchbaseHosts.length == 0) {
             enabled = false;
             log.warn("No couchbase host configured, client '{}' is disabled.", clientId);
             return;
         }
 
-        bucketName = PropertiesUtil.toString(config.get(CACHE_BUCKET_NAME_PROPERTY), null);
-        String bucketPassword = PropertiesUtil.toString(config.get(CACHE_BUCKET_PASSWORD_PROPERTY), null);
         if (bucketName == null) {
             enabled = false;
             log.warn("No couchbase bucket name configured, client '{}' is disabled.", clientId);
             return;
         }
-
-        try {
-            cluster = CouchbaseEnvironmentSingleton.createCluster(couchbaseHosts);
-            bucket = CouchbaseEnvironmentSingleton.openBucket(cluster, bucketName, bucketPassword);
-        }
-        catch (Throwable ex) {
-            enabled = false;
-            log.error("Unable to connect to couchbase cluster or open couchbase bucket, client '" + clientId + "' is disabled.", ex);
-        }
     }
 
     @Deactivate
@@ -131,11 +127,25 @@ public class CouchbaseClientImpl implements CouchbaseClient {
     }
 
     public Bucket getBucket() {
+        if (!initialized) {
+            synchronized (this) {
+                if (!initialized) {
+                    try {
+                        cluster = CouchbaseEnvironmentSingleton.createCluster(couchbaseHosts);
+                        bucket = CouchbaseEnvironmentSingleton.openBucket(cluster, bucketName, bucketPassword);
+                        initialized = true;
+                    }
+                    catch (Throwable ex) {
+                        throw new RuntimeException("Unable to connect to couchbase cluster or open couchbase bucket, client '" + clientId + "'.", ex);
+                    }
+                }
+            }
+        }
         return bucket;
     }
 
     public AsyncBucket getAsyncBucket() {
-        return bucket.async();
+        return getBucket().async();
     }
 
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 12/24: [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.0

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 16f09afae67380efee86fd4593752b9c9d6c07a4
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Thu Sep 17 21:31:34 2015 +0000

    [maven-release-plugin] prepare release org.apache.sling.nosql.couchbase-client-1.0.0
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1703702 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/pom.xml b/pom.xml
index 2b41a38..6e19954 100644
--- a/pom.xml
+++ b/pom.xml
@@ -17,28 +17,27 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
 
     <modelVersion>4.0.0</modelVersion>
     <parent>
         <groupId>org.apache.sling</groupId>
         <artifactId>sling</artifactId>
         <version>24</version>
-        <relativePath/>
+        <relativePath />
     </parent>
 
     <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
-    <version>0.5.0-SNAPSHOT</version>
+    <version>1.0.0</version>
     <packaging>bundle</packaging>
   
     <name>Apache Sling NoSQL Couchbase Client</name>
     <description>Couchbase client provider using Couchbase SDK 2.</description>
 
     <scm>
-        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
-        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/tags/org.apache.sling.nosql.couchbase-client-1.0.0</url>
     </scm>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 06/24: set parent version to 24 and add empty relativePath where missing

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 275a486f1ebb01fcd79e4418da7aab104be40b56
Author: Oliver Lietz <ol...@apache.org>
AuthorDate: Tue Jul 7 07:36:29 2015 +0000

    set parent version to 24 and add empty relativePath where missing
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1689588 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index c3ae25a..103c21c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -24,7 +24,7 @@
     <parent>
         <groupId>org.apache.sling</groupId>
         <artifactId>sling</artifactId>
-        <version>23</version>
+        <version>24</version>
         <relativePath/>
     </parent>
 

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 15/24: Switch to parent pom 26

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit d3fb4fc1dd9c5d22c60803d169ac7d4e604452be
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Sun Jan 3 14:07:46 2016 +0000

    Switch to parent pom 26
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1722720 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 1d3e4ee..2c0d5c9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@
     <parent>
         <groupId>org.apache.sling</groupId>
         <artifactId>sling</artifactId>
-        <version>25</version>
+        <version>26</version>
         <relativePath />
     </parent>
 

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 01/24: SLING-4381 couchbase client

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 89e793b4c0c2add25963f59719e2ecae88a04491
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed May 20 13:48:32 2015 +0000

    SLING-4381 couchbase client
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1680570 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml                                            | 131 +++++++++++++++++++
 .../nosql/couchbase/client/CouchbaseClient.java    |  63 +++++++++
 .../sling/nosql/couchbase/client/CouchbaseKey.java |  79 ++++++++++++
 .../couchbase/client/impl/CouchbaseClientImpl.java | 141 +++++++++++++++++++++
 .../nosql/couchbase/client/impl/CouchbaseUtil.java |  63 +++++++++
 .../sling/nosql/couchbase/client/package-info.java |  24 ++++
 .../nosql/couchbase/client/CouchbaseKeyTest.java   |  44 +++++++
 7 files changed, 545 insertions(+)

diff --git a/pom.xml b/pom.xml
new file mode 100644
index 0000000..d0a4ba9
--- /dev/null
+++ b/pom.xml
@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.apache.sling</groupId>
+        <artifactId>sling</artifactId>
+        <version>22</version>
+        <relativePath/>
+    </parent>
+
+    <artifactId>org.apache.sling.nosql.couchbase-client</artifactId>
+    <version>0.5.0-SNAPSHOT</version>
+    <packaging>bundle</packaging>
+  
+    <name>Apache Sling NoSQL Couchbase Client</name>
+    <description>Couchbase client provider using Couchbase SDK 2.</description>
+
+    <scm>
+        <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/contrib/nosql/couchbase-client</developerConnection>
+        <url>http://svn.apache.org/viewvc/sling/trunk/contrib/nosql/couchbase-client</url>
+    </scm>
+
+    <properties>
+        <sling.java.version>7</sling.java.version>
+        <couchbase.client.version>2.1.3</couchbase.client.version>
+    </properties>
+
+    <dependencies>
+
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+  
+        <dependency>
+            <groupId>com.couchbase.client</groupId>
+            <artifactId>java-client</artifactId>
+            <version>${couchbase.client.version}</version>
+            <scope>compile</scope>
+        </dependency>
+  
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.commons.osgi</artifactId>
+            <version>2.2.2</version>
+            <scope>compile</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+  
+        <dependency>
+            <groupId>org.apache.commons</groupId>
+            <artifactId>commons-lang3</artifactId>
+            <version>3.3.2</version>
+            <scope>test</scope>
+        </dependency>
+
+    </dependencies>
+  
+    <build>
+        <plugins>
+
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <!-- Do not inline jars, include as jar files -->
+                        <Embed-Dependency>*;scope=compile|runtime;inline=false;groupId=com.couchbase.*</Embed-Dependency>
+                        <Embed-Transitive>true</Embed-Transitive>
+                        <!-- use _exportcontents instead of Export-Package to avoid conflict with Embed-Dependency an inline=true -->
+                        <_exportcontents>
+                            com.couchbase.client.java.*;version=${couchbase.client.version},
+                            org.apache.sling.nosql.couchbase.client;version=${project.version}
+                        </_exportcontents>
+                        <Import-Package>
+                            com.barchart.udt.*;resolution:=optional,
+                            com.google.protobuf.*;resolution:=optional,
+                            com.jcraft.jzlib.*;resolution:=optional,
+                            com.sun.*;resolution:=optional,
+                            gnu.io.*;resolution:=optional,
+                            javassist.*;resolution:=optional,
+                            org.apache.tomcat.*;resolution:=optional,
+                            org.bouncycastle.*;resolution:=optional,
+                            org.eclipse.jetty.*;resolution:=optional,
+                            org.jboss.*;resolution:=optional,
+                            rx.internal.*;resolution:=optional,
+                            sun.misc.*;resolution:=optional,
+                            sun.security.*;resolution:=optional,
+                            *
+                        </Import-Package>
+                    </instructions>
+                </configuration>
+            </plugin>
+      
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-scr-plugin</artifactId>
+            </plugin>
+
+        </plugins>
+    </build>
+
+</project>
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseClient.java b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseClient.java
new file mode 100644
index 0000000..f6751a2
--- /dev/null
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseClient.java
@@ -0,0 +1,63 @@
+/*
+ * 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.sling.nosql.couchbase.client;
+
+import aQute.bnd.annotation.ProviderType;
+
+import com.couchbase.client.java.AsyncBucket;
+import com.couchbase.client.java.Bucket;
+
+/**
+ * Provides access to a preconfigured couchbase client. 
+ * Multiple clients can be registered for different buckets; they can be filtered by the 'clientId' OSGi property.
+ */
+@ProviderType
+public interface CouchbaseClient {
+
+    /**
+     * OSGi property for filtering the configured couchbase clients.
+     */
+    String CLIENT_ID_PROPERTY = "clientId";
+
+    /**
+     * @return ID to uniquely identify the couchbase client if multiple are defined.
+     */
+    String getClientId();
+
+    /**
+     * @return true if Couchbase caching is enabled and configured properly.
+     */
+    boolean isEnabled();
+
+    /**
+     * @return the name of the couchbase bucket to use for caching
+     */
+    String getBucketName();
+
+    /**
+     * @return Default bucket as configured for the couchbase client provider.
+     */
+    Bucket getBucket();
+
+    /**
+     * @return Default asynchronous bucket as configured for the couchbase client provider.
+     */
+    AsyncBucket getAsyncBucket();
+
+}
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java
new file mode 100644
index 0000000..e495ffc
--- /dev/null
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/CouchbaseKey.java
@@ -0,0 +1,79 @@
+/*
+ * 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.sling.nosql.couchbase.client;
+
+import java.io.UnsupportedEncodingException;
+import java.security.MessageDigest;
+import java.security.NoSuchAlgorithmException;
+
+import aQute.bnd.annotation.ProviderType;
+
+/**
+ * Builds couchbase keys. Cuts them off and replaces the remaining part with a hash if too long.
+ */
+@ProviderType
+public final class CouchbaseKey {
+
+    static final int MAX_KEY_LENGTH = 250;
+
+    private CouchbaseKey() {
+        // static methods only
+    }
+
+    /**
+     * Builds a key for a couchbase document with the given prefix that does not
+     * exceed the max. length for couchbase keys.
+     * @param key Full key
+     * @param cacheKeyPrefix Prefix to add before the key
+     * @return Valid key for couchbase
+     */
+    public static String build(String key, String keyPrefix) {
+        String cacheKey = keyPrefix + key;
+
+        if (cacheKey.length() < MAX_KEY_LENGTH) {
+            return cacheKey;
+        }
+
+        int charactersToKeep = MAX_KEY_LENGTH - keyPrefix.length() - 41;
+
+        String toKeep = key.substring(0, charactersToKeep);
+        String toHash = key.substring(charactersToKeep);
+
+        String hash = calculateHash(toHash);
+
+        return keyPrefix + toKeep + "#" + hash;
+    }
+
+    private static String calculateHash(String message) {
+        try {
+            MessageDigest digest = MessageDigest.getInstance("SHA-1");
+            digest.update(message.getBytes("UTF-8"));
+            byte[] digestBytes = digest.digest();
+
+            return javax.xml.bind.DatatypeConverter.printHexBinary(digestBytes).toLowerCase();
+        }
+        catch (NoSuchAlgorithmException ex) {
+            throw new RuntimeException("Failed to create sha1 Hash from " + message, ex);
+        }
+        catch (UnsupportedEncodingException ex) {
+            throw new RuntimeException("Failed to create sha1 Hash from " + message, ex);
+        }
+    }
+
+}
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
new file mode 100644
index 0000000..a12a61f
--- /dev/null
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseClientImpl.java
@@ -0,0 +1,141 @@
+/*
+ * 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.sling.nosql.couchbase.client.impl;
+
+import java.util.Map;
+
+import org.apache.felix.scr.annotations.Activate;
+import org.apache.felix.scr.annotations.Component;
+import org.apache.felix.scr.annotations.ConfigurationPolicy;
+import org.apache.felix.scr.annotations.Deactivate;
+import org.apache.felix.scr.annotations.Property;
+import org.apache.felix.scr.annotations.Service;
+import org.apache.sling.commons.osgi.PropertiesUtil;
+import org.apache.sling.nosql.couchbase.client.CouchbaseClient;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.couchbase.client.java.AsyncBucket;
+import com.couchbase.client.java.Bucket;
+import com.couchbase.client.java.Cluster;
+
+/**
+ * Default implementation of {@link CouchbaseClient}.
+ */
+@Component(immediate = true, metatype = true,
+    name="org.apache.sling.nosql.couchbase.client.CouchbaseClient.factory.config",
+    label = "Apache Sling NoSQL Couchbase Client", 
+    description = "Provides access to a preconfigured couchbase client.", 
+    configurationFactory = true, policy = ConfigurationPolicy.REQUIRE)
+@Service(CouchbaseClient.class)
+@Property(name = "webconsole.configurationFactory.nameHint", 
+    value = "{" + CouchbaseClientImpl.CLIENT_ID_PROPERTY + "}: {" + CouchbaseClientImpl.CACHE_BUCKET_NAME_PROPERTY + "}")
+public class CouchbaseClientImpl implements CouchbaseClient {
+
+    @Property(label = "Client ID", description = "ID to uniquely identify the couchbase client if multiple are defined.")
+    static final String CLIENT_ID_PROPERTY = CouchbaseClient.CLIENT_ID_PROPERTY;
+
+    @Property(label = "Enabled", description = "Enable or disable couchbase caching.", boolValue = CouchbaseClientImpl.ENABLED_PROPERTY_DEFAULT)
+    static final String ENABLED_PROPERTY = "enabled";
+    private static final boolean ENABLED_PROPERTY_DEFAULT = true;
+
+    @Property(label = "Couchbase Hosts", description = "Couchbase cluster host list.", cardinality = Integer.MAX_VALUE)
+    static final String COUCHBASE_HOSTS_PROPERTY = "couchbaseHosts";
+
+    @Property(label = "Bucket Name", description = "Couchbase bucket name")
+    static final String CACHE_BUCKET_NAME_PROPERTY = "bucketName";
+
+    @Property(label = "Bucket Password", description = "Couchbase bucket password")
+    static final String CACHE_BUCKET_PASSWORD_PROPERTY = "bucketPassword";
+
+    private static final Logger log = LoggerFactory.getLogger(CouchbaseClientImpl.class);
+
+    private String clientId;
+    private boolean enabled;
+    private String bucketName;
+    private Cluster cluster;
+    private Bucket bucket;
+
+    @Activate
+    private void activate(Map<String, Object> config) {
+        clientId = PropertiesUtil.toString(config.get(CLIENT_ID_PROPERTY), null);
+        enabled = PropertiesUtil.toBoolean(config.get(ENABLED_PROPERTY), ENABLED_PROPERTY_DEFAULT);
+        if (!enabled) {
+            log.info("Couchbase caching for client '{}' is disabled by configuration.", clientId);
+            return;
+        }
+
+        String[] couchbaseHosts = PropertiesUtil.toStringArray(config.get(COUCHBASE_HOSTS_PROPERTY));
+        if (couchbaseHosts == null || couchbaseHosts.length == 0) {
+            enabled = false;
+            log.warn("No couchbase host configured, client '{}' is disabled.", clientId);
+            return;
+        }
+
+        bucketName = PropertiesUtil.toString(config.get(CACHE_BUCKET_NAME_PROPERTY), null);
+        String bucketPassword = PropertiesUtil.toString(config.get(CACHE_BUCKET_PASSWORD_PROPERTY), null);
+        if (bucketName == null) {
+            enabled = false;
+            log.warn("No couchbase bucket name configured, client '{}' is disabled.", clientId);
+            return;
+        }
+
+        try {
+            cluster = CouchbaseUtil.createCluster(couchbaseHosts);
+            bucket = CouchbaseUtil.openBucket(cluster, bucketName, bucketPassword);
+        }
+        catch (Throwable ex) {
+            enabled = false;
+            log.error("Unable to connect to couchbase cluster or open couchbase bucket, client '" + clientId + "' is disabled.", ex);
+        }
+    }
+
+    @Deactivate
+    private void deactivate() {
+        if (bucket != null) {
+            bucket.close();
+            bucket = null;
+        }
+        if (cluster != null) {
+            cluster.disconnect();
+            cluster = null;
+        }
+    }
+
+    public String getClientId() {
+        return clientId;
+    }
+
+    public boolean isEnabled() {
+        return enabled;
+    }
+
+    public String getBucketName() {
+        return bucketName;
+    }
+
+    public Bucket getBucket() {
+        return bucket;
+    }
+
+    public AsyncBucket getAsyncBucket() {
+        return bucket.async();
+    }
+
+}
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java
new file mode 100644
index 0000000..523870c
--- /dev/null
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/impl/CouchbaseUtil.java
@@ -0,0 +1,63 @@
+/*
+ * 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.sling.nosql.couchbase.client.impl;
+
+import com.couchbase.client.java.Bucket;
+import com.couchbase.client.java.Cluster;
+import com.couchbase.client.java.CouchbaseCluster;
+import com.couchbase.client.java.env.CouchbaseEnvironment;
+import com.couchbase.client.java.env.DefaultCouchbaseEnvironment;
+
+/**
+ * Manages couchbase environment.
+ */
+final class CouchbaseUtil {
+
+    private static final CouchbaseEnvironment COUCHBASE_ENVIRONMENT = DefaultCouchbaseEnvironment.builder().build();
+
+    private CouchbaseUtil() {
+        // static methods only
+    }
+
+    /**
+     * Create new couchbase cluster.
+     * @param hostNames Multiple hosts
+     * @return Couchbase cluster
+     */
+    public static Cluster createCluster(String... hostNames) {
+        return CouchbaseCluster.create(COUCHBASE_ENVIRONMENT, hostNames);
+    }
+
+    /**
+     * Open couchbase bucket.
+     * @param cluster Couchbase cluster
+     * @param bucketName Bucker name
+     * @param bucketPassword Bucker password (optional)
+     * @return Couchbase bucket
+     */
+    public static Bucket openBucket(Cluster cluster, String bucketName, String bucketPassword) {
+        if (bucketPassword == null) {
+            return cluster.openBucket(bucketName, bucketPassword);
+        }
+        else {
+            return cluster.openBucket(bucketName);
+        }
+    }
+
+}
diff --git a/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java b/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java
new file mode 100644
index 0000000..537c719
--- /dev/null
+++ b/src/main/java/org/apache/sling/nosql/couchbase/client/package-info.java
@@ -0,0 +1,24 @@
+/*
+ * 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.
+ */
+/**
+ * Couchbase Client Provider
+ */
+@aQute.bnd.annotation.Version("0.5.0")
+package org.apache.sling.nosql.couchbase.client;
+
diff --git a/src/test/java/org/apache/sling/nosql/couchbase/client/CouchbaseKeyTest.java b/src/test/java/org/apache/sling/nosql/couchbase/client/CouchbaseKeyTest.java
new file mode 100644
index 0000000..cd1a68b
--- /dev/null
+++ b/src/test/java/org/apache/sling/nosql/couchbase/client/CouchbaseKeyTest.java
@@ -0,0 +1,44 @@
+/*
+ * 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.sling.nosql.couchbase.client;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.apache.commons.lang3.StringUtils;
+import org.junit.Test;
+
+public class CouchbaseKeyTest {
+
+    private static final String PREFIX = "prefix:";
+
+    @Test
+    public void testShortKey() {
+        String key = CouchbaseKey.build("/short/key", PREFIX);
+        assertEquals(PREFIX + "/short/key", key);
+    }
+
+    @Test
+    public void testLongKey() {
+        String key = CouchbaseKey.build("/long/key/" + StringUtils.repeat("/aaa", 500), PREFIX);
+        assertTrue(StringUtils.startsWith(key, PREFIX + "/long/key/"));
+        assertEquals(CouchbaseKey.MAX_KEY_LENGTH, key.length());
+    }
+
+}

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 05/24: Update contrib modules to Parent 23

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit 0076ad42a353007b65fd1c3eb0861ce5523e6d0a
Author: Robert Munteanu <ro...@apache.org>
AuthorDate: Thu Jun 25 13:10:59 2015 +0000

    Update contrib modules to Parent 23
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1687503 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 70d928a..c3ae25a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -24,7 +24,7 @@
     <parent>
         <groupId>org.apache.sling</groupId>
         <artifactId>sling</artifactId>
-        <version>22</version>
+        <version>23</version>
         <relativePath/>
     </parent>
 

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 17/24: exclude README.md in rat report

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit ad00d6eec135375da50a2b73fb59d2b3b661a0ac
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 12:02:10 2016 +0000

    exclude README.md in rat report
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732095 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/pom.xml b/pom.xml
index 98251a6..0c4ff92 100644
--- a/pom.xml
+++ b/pom.xml
@@ -125,6 +125,20 @@
             </plugin>
 
         </plugins>
+        <pluginManagement>
+            <plugins>
+                <plugin>
+                    <!-- Extend RAT configuration from parent pom -->
+                    <groupId>org.apache.rat</groupId>
+                    <artifactId>apache-rat-plugin</artifactId>
+                    <configuration>
+                        <excludes combine.children="append">
+                            <exclude>README.md</exclude>
+                        </excludes>
+                    </configuration>
+                </plugin>
+            </plugins>
+        </pluginManagement>
     </build>
 
 </project>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 16/24: SLING-5558 Update to Couchbase Client 2.2.4

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit bb798953d9a466f5cef518fbc195c56c9ee3836e
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed Feb 24 10:57:23 2016 +0000

    SLING-5558 Update to Couchbase Client 2.2.4
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1732070 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 2c0d5c9..98251a6 100644
--- a/pom.xml
+++ b/pom.xml
@@ -42,7 +42,7 @@
 
     <properties>
         <sling.java.version>7</sling.java.version>
-        <couchbase.client.version>2.2.0</couchbase.client.version>
+        <couchbase.client.version>2.2.4</couchbase.client.version>
     </properties>
 
     <dependencies>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.

[sling-org-apache-sling-nosql-couchbase-client] 02/24: SLING-4381 couchbase resource provider

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-nosql-couchbase-client.git

commit d91b6322728aa65d6bf74b97b29755bda4175c1c
Author: Stefan Seifert <ss...@apache.org>
AuthorDate: Wed May 20 14:11:43 2015 +0000

    SLING-4381 couchbase resource provider
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1680578 13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pom.xml b/pom.xml
index d0a4ba9..70d928a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -51,7 +51,7 @@
         <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-api</artifactId>
-            <scope>compile</scope>
+            <scope>provided</scope>
         </dependency>
   
         <dependency>
@@ -65,7 +65,7 @@
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.commons.osgi</artifactId>
             <version>2.2.2</version>
-            <scope>compile</scope>
+            <scope>provided</scope>
         </dependency>
         
         <dependency>

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.