Skip to content

Cleaned up: Added mango selector to changes feed #65

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 86 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
44e6cc6
Initial docker/travis support
buckett Jan 30, 2016
bd6fb44
Add _selector support to _changes operation
Dec 18, 2017
7cdebfe
Update README.md
jurkiri Feb 19, 2018
12cad4a
Merge pull request #1 from jjrodrig/master
jurkiri Feb 19, 2018
661176a
Restrict tests by CouchDB version
Feb 19, 2018
945327f
Reformat
Feb 19, 2018
2b26147
Merge pull request #3 from buckett/travis
jjrodrig Feb 19, 2018
75c3e0d
groupId changed and Indaba info added
jurkiri Feb 19, 2018
21c3273
Add support for CouchDB 1.x/2.x testing and sonar
Feb 19, 2018
feb3ae0
Add sonarcloud support
Feb 19, 2018
5c643c4
Enable replication test
Feb 19, 2018
69f7f14
Configure target couchdb for replication tests
Feb 19, 2018
5073e6d
Configure target couchdb for replication tests
Feb 19, 2018
ec3be1a
fix db uri for replicator
Feb 19, 2018
19a805f
fix db uri for replicator
Feb 19, 2018
fd81af9
Added shard number on database creation
jurkiri Feb 20, 2018
8ffa03a
Merge branch 'master' of https://github.com/IndabaConsultores/LightCouch
jurkiri Feb 20, 2018
c2a2429
Configure single node CouchDB 2.x in travis
Feb 20, 2018
3a07369
Configure single node CouchDB 2.x in travis
Feb 20, 2018
46f808d
Configure single node CouchDB 2.x in travis
Feb 20, 2018
2f5799a
Configure single node CouchDB 2.x in travis
Feb 20, 2018
7f1dfec
Configure single node CouchDB 2.x in travis
Feb 20, 2018
ecb4546
Adjust replication test
Feb 20, 2018
e3ad60e
Enable replication tests (#4)
jjrodrig Feb 20, 2018
6bd2f9a
Add Travis CI and Sonarcloud badges
jjrodrig Feb 20, 2018
e9d6212
Merge branch 'master' of https://github.com/IndabaConsultores/LightCo…
Feb 20, 2018
69a4a0d
Clean up databases after test, remove order dependency
Feb 20, 2018
843a4fb
Create CHANGES.MD
jjrodrig Feb 20, 2018
ed7ffb5
Rename CHANGES.MD to CHANGES.md
jjrodrig Feb 20, 2018
ff0513f
sonarcloud revision
jurkiri Feb 20, 2018
41c28bc
Merge branch 'master' of https://github.com/IndabaConsultores/LightCouch
jurkiri Feb 20, 2018
5f4828a
Merge branch 'sonarcloud'
jurkiri Feb 20, 2018
fc05b0e
Merge branch 'sonarcloud'
jurkiri Feb 20, 2018
0751b0f
Merge branch 'master' of https://github.com/IndabaConsultores/LightCouch
jurkiri Feb 20, 2018
3fd6e39
Create CONTRIBUTING.md
jjrodrig Feb 20, 2018
99a50b5
Fix build method broken in previous merge
jurkiri Feb 20, 2018
f274739
Merge branch 'master' of https://github.com/IndabaConsultores/LightCouch
jurkiri Feb 20, 2018
e88d6a1
Update README.md
jjrodrig Feb 20, 2018
3668628
fix _replicator db tests - Wait until complete
Feb 20, 2018
d2fc9fc
Merge branch 'master' of https://github.com/IndabaConsultores/LightCouch
Feb 20, 2018
c2d8bd3
Retry replica cancellation in replication test
Feb 20, 2018
fa67237
Version 0.2.1 release
jurkiri Feb 21, 2018
4bed5bc
[maven-release-plugin] prepare for next development iteration
jurkiri Feb 21, 2018
f6b7a14
Update CHANGES.md
jjrodrig Feb 21, 2018
f19036a
Explicit set for LICENSE
jjrodrig Feb 21, 2018
b16b5e6
Add explicit API for local documents
Feb 22, 2018
47ded6e
Fix test for CouchDB 1.x
Feb 23, 2018
fa78841
Merge branch 'master' of https://github.com/IndabaConsultores/LightCo…
Feb 23, 2018
93fa07d
Update CHANGES.md
Feb 23, 2018
8ac392e
Fix final modifier for constant and add license header
Mar 5, 2018
ba3162f
Merge pull request #9 from IndabaConsultores/7-support-local-docs
jurkiri Mar 5, 2018
383da0f
Add seq_interval parameter to Changes API
Mar 20, 2018
0e6d919
Updated CHANGES.md
Mar 20, 2018
97f010c
Parameter seq_interval is only supported in CouchDB 2.x
Mar 20, 2018
86df689
Reformat source code
Mar 20, 2018
ce13ea0
Merge pull request #11 from IndabaConsultores/changes-seq-interval
jurkiri Mar 20, 2018
e3f0bfc
Added support for _db_updates endpoint (#12)
jurkiri Mar 20, 2018
f8cdc64
Update CHANGES.md
jjrodrig Mar 20, 2018
2f41ab0
Include stop condition check inside reading loop
Mar 20, 2018
e614259
Update CHANGES.md
jjrodrig Mar 21, 2018
3aad869
Merge pull request #13 from IndabaConsultores/6-fix-block-changes-has…
jurkiri Mar 21, 2018
41c02d4
Release v0.2.2
jurkiri Mar 21, 2018
8a17ab0
Update README.md
jjrodrig Aug 20, 2018
54b5a9d
Add CouchDB 2.2.x as test case in travis (#15)
jjrodrig Sep 11, 2018
ea5e32f
Fix #16 - Add support for _doc_ids filter in changes operation
Sep 18, 2018
e08433f
Add new release info
Sep 18, 2018
3ec8d4e
Merge pull request #17 from IndabaConsultores/16-docid-changes-filter
jurkiri Sep 18, 2018
75a144f
Update CHANGES.md
jurkiri Sep 18, 2018
0615be0
Update maven version
jjrodrig Sep 18, 2018
89344f0
Add method for checking design doc existence (#19)
jjrodrig Oct 8, 2018
59476e1
Update release date
jjrodrig Oct 8, 2018
8be5df0
Update version
jjrodrig Oct 8, 2018
93b3f56
Add testing on CouchDB 2.3 and Fix purge_seq behaviour change (#21)
jjrodrig Dec 14, 2018
d7146b7
Update CHANGES.md
jjrodrig Dec 23, 2018
f3a4599
Update README.md
jjrodrig Dec 23, 2018
7ae9386
Release 0.2.5
jjrodrig Dec 23, 2018
943a15d
Add support for /db/_purge operation implemented in CouchDB 2.3.0 (#22)
jjrodrig Feb 18, 2019
baa8c7f
Release 0.2.6
Feb 18, 2019
0ae381d
Update testing environment to CouchDB 2.3.1
jjrodrig Mar 13, 2019
48ca10b
Add ETag management support. (#23)
yzhan94 May 13, 2019
ba2c0ca
Update version
jjrodrig Aug 20, 2019
c65454f
Prepare testing support for upcoming CouchDB 3.x release
Feb 11, 2020
c4ebe85
Test using CouchDB 3.0.0
jjrodrig Feb 28, 2020
bc7c25e
Move to java 1.6
Mar 12, 2020
a3874c2
Add support for testing with CouchDB 3.0.0 (#25)
jjrodrig Apr 14, 2020
237edd8
Fix travis
jjrodrig Apr 14, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 54 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
sudo: required

language: java
addons:
sonarcloud:
organization: "indaba"
apt:
packages:
- docker-ce

services:
- docker

jobs:
include:
- stage: Build and Test on CouchDB 3.0.x
install:
- docker pull couchdb:3.0.0
- docker run -d -p 127.0.0.1:5984:5984 -e COUCHDB_USER=couchdb -e COUCHDB_PASSWORD=couchdb couchdb:3.0.0
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb.properties
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb-2.properties
- sleep 20
- "curl -X PUT http://127.0.0.1:5984/_users -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_replicator -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_global_changes -u couchdb:couchdb"
script:
- mvn org.jacoco:jacoco-maven-plugin:prepare-agent test sonar:sonar
- stage: Build and Test on CouchDB 2.3.x
install:
- docker pull couchdb:2.3.1
- docker run -d -p 127.0.0.1:5984:5984 -e COUCHDB_USER=couchdb -e COUCHDB_PASSWORD=couchdb couchdb:2.3.1
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb.properties
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb-2.properties
- sleep 20
- "curl -X PUT http://127.0.0.1:5984/_users -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_replicator -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_global_changes -u couchdb:couchdb"
- stage: Build and Test on CouchDB 2.2.x
install:
- docker pull couchdb:2.2.0
- docker run -d -p 127.0.0.1:5984:5984 -e COUCHDB_USER=couchdb -e COUCHDB_PASSWORD=couchdb couchdb:2.2.0
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb.properties
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb-2.properties
- sleep 20
- "curl -X PUT http://127.0.0.1:5984/_users -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_replicator -u couchdb:couchdb"
- "curl -X PUT http://127.0.0.1:5984/_global_changes -u couchdb:couchdb"
- stage: Build and Test on CouchDB 1.7.x
install:
- docker pull couchdb:1.7.2
- docker run -d -p 127.0.0.1:5984:5984 -e COUCHDB_USER=couchdb -e COUCHDB_PASSWORD=couchdb couchdb:1.7.2
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb.properties
- sed 's/^couchdb.username.*/couchdb.username=couchdb/;s/^couchdb.password.*/couchdb.password=couchdb/' -i src/test/resources/couchdb-2.properties
- sleep 20
22 changes: 22 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# 0.2.6 (18/02/2019)
- [NEW] Added support for /db/_purge endpoint implemented in CouchDB 2.3.0

# 0.2.5 (23/12/2018)
- [FIX] Support for string purge_seqs in CouchDB 2.3

# 0.2.4 (08/10/2018)
- [NEW] Added API for checking design doc existence

# 0.2.3 (18/09/2018)
- [NEW] Added API for specifying docIds filter to _changes operation

# 0.2.2 (21/03/2018)
- [NEW] Added explicit API for local document management.
- [NEW] Added seq_interval parameter in Changes API
- [NEW] Added _db_updates endpoint support
- [IMPROVED] Make more robust stop process in Changes hasNext

# 0.2.1 (21/02/2018)
- [NEW] Added API for specifying a mango selector _changes operation
- [IMPROVED] Test are cleaned up and executed in CouchDB 1.x an CouchDb 2.x
- [SUPPORT] Added support for travis build
27 changes: 27 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Contributing to this library

LightCouch is written in Java and uses [maven](https://maven.apache.org/) as its build tool.

## Requirements

The main requirements are:

* Java 1.6
* CouchDB

## Coding guidelines

Adopting the [Google Java Style](https://google-styleguide.googlecode.com/svn/trunk/javaguide.html)
with the following changes:

```
4.2
Our block indent is +4 characters

4.4
Our line length is 100 characters.

4.5.2
Indent continuation of +4 characters fine, but I think
IDEA defaults to 8, which is okay too.
```
4 changes: 2 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,9 @@
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
identification within third-party archives.

Copyright 2011 lightcouch.org
Copyright [yyyy] [name of copyright owner]

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
CouchDB Java API
================

[![Travis CI](https://api.travis-ci.org/IndabaConsultores/LightCouch.svg?branch=master)](https://travis-ci.org/IndabaConsultores/LightCouch)
[![Sonarcloud](https://sonarcloud.io/api/project_badges/measure?project=es.indaba:lightcouch&metric=alert_status)](https://sonarcloud.io/dashboard?id=es.indaba:lightcouch)


A Java _client_ for [CouchDB](http://couchdb.apache.org/) database.

* Homepage: <http://lightcouch.org/>
This is an active fork of LightCouch CouchDB Java API. Our intention is to mantain an active development of the library to cover the CouchDB REST API.

The releases of this fork are published via Jitpack
```xml
<dependency>
<groupId>com.github.IndabaConsultores</groupId>
<artifactId>lightCouch</artifactId>
<version>0.2.6</version>
</dependency>
```
165 changes: 89 additions & 76 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,76 +1,89 @@
<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>

<groupId>org.lightcouch</groupId>
<artifactId>lightcouch</artifactId>
<version>0.2.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>LightCouch</name>
<description>CouchDB Java API</description>
<inceptionYear>2011</inceptionYear>
<url>http://www.lightcouch.org</url>
<parent>
<groupId>org.sonatype.oss</groupId>
<artifactId>oss-parent</artifactId>
<version>7</version>
</parent>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:git://github.com/lightcouch/LightCouch.git</connection>
<developerConnection>scm:git:[email protected]:lightcouch/LightCouch.git</developerConnection>
<url>https://[email protected]/lightcouch/LightCouch.git</url>
</scm>
<developers>
<developer>
<id>ahmedyha</id>
<name>Ahmed Yehia</name>
<email>[email protected]</email>
</developer>
</developers>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<httpclient.version>4.5.3</httpclient.version>
<gson.version>2.8.2</gson.version>
<junit.version>4.8.2</junit.version>
</properties>
<dependencies>
<!-- Apache HttpComponents -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${httpclient.version}</version>
</dependency>
<!-- Gson -->
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>${gson.version}</version>
</dependency>
<!-- Testing -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
<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>

<groupId>es.indaba</groupId>
<artifactId>lightcouch</artifactId>
<version>0.2.6</version>
<packaging>jar</packaging>
<name>LightCouch</name>
<description>CouchDB Java API</description>
<parent>
<groupId>org.sonatype.oss</groupId>
<artifactId>oss-parent</artifactId>
<version>7</version>
</parent>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:https://github.com/IndabaConsultores/LightCouch.git</connection>
<url>https://github.com/IndabaConsultores/LightCouch</url>
</scm>

<developers>
<developer>
<name>Juan José Rodríguez</name>
<email>[email protected]</email>
<organization>Indaba Consultores S.L.</organization>
<organizationUrl>http://www.indaba.es</organizationUrl>
</developer>
<developer>
<name>Joseba Urkiri</name>
<email>[email protected]</email>
<organization>Indaba Consultores S.L.</organization>
<organizationUrl>http://www.indaba.es</organizationUrl>
</developer>
</developers>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<httpclient.version>4.5.3</httpclient.version>
<gson.version>2.8.2</gson.version>
<junit.version>4.8.2</junit.version>
</properties>
<dependencies>
<!-- Apache HttpComponents -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${httpclient.version}</version>
</dependency>
<!-- Gson -->
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>${gson.version}</version>
</dependency>
<!-- Testing -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.zafarkhaja</groupId>
<artifactId>java-semver</artifactId>
<version>0.9.0</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
Loading